rm.dupl: Find point pairs with equal spatial coordinates from STFDF...

Description Usage Arguments Value Author(s) See Also Examples

View source: R/rm.dupl.R

Description

This function finds point pairs with equal spatial coordinates from STFDF object and remove locations with less observations.

Usage

1
rm.dupl(obj, zcol = 1, zero.tol = 0)

Arguments

obj

STFDF object

zcol

variable column name, or column number, from obj@data

zero.tol

distance values less than or equal to this threshold value are considered as duplicates; units are those of the coordinates for projected data or unknown projection, or km if coordinates are defined to be longitute/latitude

Value

STFDF object with removed duplicate locations. Stations with less observation is removed, if number of observation is the same for two stations the first is removed.

Author(s)

Milan Kilibarda kili@grf.bg.ac.rs

See Also

tgeom2STFDF pred.strk

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
# load observation - data frame
data(dtempc) 
# load stations - data frame
data(stations)

str(dtempc)
str(stations)
# create STFDF
temp <- meteo2STFDF(dtempc,stations) # create STFDF from 2 data frames

nrow(temp@sp) # number of stations before removing dupl.

temp2 <-rm.dupl(temp)
nrow(temp2@sp) # number of stations after

meteo documentation built on May 2, 2019, 3:29 p.m.

Related to rm.dupl in meteo...