- locations
- data.frame with x and y coordinates columns, or sf-class, SpatVector-class or SpatRaster-class object; Locations (FROM) for which n nearest observations are found and distances are calculated. 
  
- locations.x.y
- numeric or character vector; Positions or names of the x and y columns in - locationsif data.frame. Default is c(1,2).
 
  
- observations
- data.frame with x, y and observation columns, or sf-class or SpatVector-class object with an observation column; Observations (TO). 
  
- observations.x.y
- numeric or character vector; Positions or names of the x and y columns in - observationsif data.frame. Default is c(1,2).
 
  
- obs.col
- numeric or character; Column name or number showing position of the observation column in the - observations. Default is 3.
 
  
- n.obs
- numeric; Number of nearest observations to be found. Note that it cannot be larger than number of obsevrations. Default is 10. 
  
- rm.dupl
- boolean; Remove spatial duplicates - will the spatial duplicates (nearest observations where Euclidean distance is 0) be removed from the result. Default is TRUE. 
  
- avg
- boolean; Averages in circles - will averages in circles with different radiuses be calculated. Default is FALSE. 
  
- increment
- numeric; Increment of radiuses for calculation of averages in circles with different radiuses. Units depends on CRS. 
  
- range
- numeric; Maximum radius for calculation of averages in circles with different radiuses. Units depends on CRS. 
  
- quadrant
- boolean; Nearest observations in quadrants - will nearest observation in quadrants be calculated. Default is FALSE. 
  
- idw
- boolean; IDW prediction as predictor - will IDW predictions from - n.obsnearest observations be calculated. Default is FALSE.
 
  
- idw.p
- numeric; Exponent parameter for IDW weights. Default is 2.