LookupCZ {kgc}R Documentation

LookupCZ

Description

This function will return the climate zone for the co-ordinates provided.

Usage

LookupCZ(data, res = "course", rc = FALSE)

Arguments

data

The co-ordinates for the location you are trying to predict the climate zone of (format is three column dataframe, first column site IDs, second column longitude values, third column latitude values).

res

Specify the resolution as a string - 'course' for lower resolution (default, 0.5 degrees), 'fine' for higher resolution (100s).

rc

Specify whether to generate the rounded coordinate columns in the input dataframe, default is FALSE.

Value

The climate zone for the co-ordinates provided.

Examples

data <- data.frame(Site = c("GC","UFS","NEG"),
  Longitude = c(-15.42,10.98,34.78),
  Latitude = c(27.82,47.42,30.86))
data <- data.frame(data,
  rndCoord.lon = RoundCoordinates(data$Longitude),
  rndCoord.lat = RoundCoordinates(data$Latitude))
data <- data.frame(data,ClimateZ=LookupCZ(data))

[Package kgc version 1.0.0.2 Index]