xyextract: Reprojecting and extracting Raster values

View source: R/xyextract.R

xyextractR Documentation

Reprojecting and extracting Raster values

Description

The function reprojects longitudes and latitudes into map coordinates and extract raster values

Usage

xyextract(map, longitude, latitude)

Arguments

map

a raster object.

longitude

The longitude of the measurement site i.e. geographical coordinates in decimal degrees for the weather station. It should be negative for West and positive for East.

latitude

geographical coordinates in decimal degrees. It should be negative for southern hemisphere

Value

data

Author(s)

George Owusu

Examples

## Not run: 
lonlat=read.table(system.file("extdata","sys","xyvalues.txt",package="sebkc"),header=TRUE)
longitude=lonlat$longitude
latitude=lonlat$latitude
folder=system.file("extdata","stack",package="sebkc")
data=landsat578(data=folder, welev=362)
Ts=data$Ts
Tsdata=xyextract(Ts,longitude,latitude)


## End(Not run)

gowusu/sebkc documentation built on July 28, 2023, 11:44 a.m.