Using locality information from external sources, distance comparison
can be calculated when postcodes or similar fields are available in
data sets. This field comparator uses a geocode look-up table (where
for each entry longitude and latitude are stored) to calculate the
distance in kilometers between two values. The argument
geocode_table must be set to a reference to a geocode look-up
table as defined and loaded using methods from the
lookup.py module (see Chapter 14 for
An additional argument is
max_distance (a positive number in
kilometers) which gives the maximum distance that is tolerated. If the
calculated distance between two fields is equal to or less than the
max_distance, a partial agreement weight is
calculated using the following formula.
If the distance is larger than
max_distance, the disagreement
weight is returned.
In its current version no frequency dependent weight calculation is
possible, thus the arguments
can not be used with this field comparator function.