get.avg.bathy: returns the average value of circles with specified...

Description Usage Arguments Author(s) See Also Examples

View source: R/get.avg.bathy.r

Description

returns the average value of circles with specified coordinates and a defined radius

Usage

1
2
get.avg.bathy(x, radius, unit="km", raster, bathy, v_area="medw4")
get.avg(x, radius, unit="km", raster)

Arguments

x

a vector or matrix providing the coordinates of the circle

radius

the radius (if unit != "km", the radius is assumed to be of the same scale as the plotting window)

unit

unit of the radius (by default "km"). if unit != "km", the radius is assumed to be of the same scale as the plotting window.

raster

raster object, from which the average should be calculated.

bathy

raster object with bathymetry data, from which the average should be calculated.

v_area

character string identifying the region for which the bathymetry data should downloaded from the NOAA server.

Author(s)

Robert K. Bauer

See Also

SpatialCircle

Examples

1
2
3
4
5
6
7
8
9
## Example 1: load & plot bathymetry of the Baltic Sea, defined by longitudes and latidtues
lon <- c(9, 31)
lat <- c(53.5, 66)
# bathy <- get.bathy(lon=lon, lat=lat, main="Baltic Sea", cbpos='r')
plotmap(lon=lon, lat=lat)
spc <- SpatialCircle(x= 20,y = 57.5,r=1)
plot(spc,add=TRUE)
# get.avg.bathy(c(20,57.5), radius = 1, bathy = bathy)
# get.avg(c(20,57.5), radius = 1, unit="km",raster = bathy)

oceanmap documentation built on March 23, 2020, 5:06 p.m.