BIASDISTSPHERICAL

The BIASDISTSPHERICAL field operator works in a similar way to the BIAS field operator. It allows you to bias the score of results at query time according to the proximity of the specified field to a particular location, specified using a latitude and longitude value.

Specify BIASDISTSPHERICAL in the format:

FieldText=BIASDISTSPHERICAL{lat,long,range,percentage}:LATFIELD:LONGFIELD

where:

lat is the latitude. Specify latitude positions south of the equator as negative.
long is the longitude. Specify longitude positions west of the Greenwich Meridian as negative.
range is the distance in kilometers from the specified coordinates. If the fields contain the coordinates of a location that is within this distance of the specified coordinates, the results weight increases or decreases according to the specified percentage.
percentage is a percentage in the range –100 to 100. If the value of the field is within the specified range, the score of the result increases or decreases according to how close the value is to the specified optimum.
LATFIELD is the document field that contains the latitude.
LONGFIELD is the document field that contains the longitude.

You must specify two fields in the order latitude:longitude. The fields must be of NumericType.

For example:

FieldText=BIASDISTSPHERICAL{52.2,0.1,100,7}:LAT:LONG

In this example, all documents within 100 kilometers of the point (lat,long)=(52.2,0.1) are given a relevance boost. Content gives the maximum boost of 7 percent to documents at the specified point. The boost decreases linearly down to zero boost at 100 kilometers.


_HP_HTML5_bannerTitle.htm