fvcom_random: Generate random points within the element or node space.

View source: R/nc.R

fvcom_randomR Documentation

Generate random points within the element or node space.

Description

A random point may fall outside of the envelope of elements/nodes since we use a simple bounding box for each dimension. Be sure to check your points, if that is important, with st_contains.

Usage

fvcom_random(
  x,
  n = 1,
  what = c("longlat", "xy")[1],
  form = c("tibble", "sf")[1],
  ...
)

Arguments

x

FVCOM ncdf4 object

n

the number of points to generate

what

either 'lonlat' or 'xy'

form

character either 'tibble' or 'sf'

...

arguments for fvcom_time

Value

tibble of

  • x x coordinate, possibly lon

  • y y coordinate, possibly lat

  • z z coordinate as sigma value

  • time time ast POSIXct

or an sf POINT object where xy are the geometry


BigelowLab/fvcom documentation built on Nov. 8, 2024, 2:24 p.m.