check_data: Check Data

Description Usage Arguments Examples

Description

Check Data

Usage

1
check_data(df = NULL, lat = NULL, long = NULL)

Arguments

df

input data.frame

lat

column name of the latitude data

long

column name of the longitude data Checks line list data for valid locations

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
## Not run: 
# This one below is obviously a trivial example
# The iris dataset contains no spatial information but we can
pretend that these two columns are lat/long
check_data(iris, 'Petal.Length', 'Petal.Width')
# Now let's add an incorrect longitude
iris$Petal.Width <- -1800
check_data(iris, 'Petal.Length', 'Petal.Width')
# This should return FALSE

## End(Not run)

Hackout2/mapData documentation built on May 6, 2019, 9:48 p.m.