Defines a multidimensional functional data set. Constructor function of the npf.data-class.

npf.data(y, min, max, lag, ylabel, ynames, dimnames)

# S3 method for npf.data
coords(x, ...)

Arguments

y

numeric matrix or array; the last dimension corresponds to curves and the first ones to discretization points.

min

vector; minimum values of the discretization points (coordinates).

max

vector; maximum values of the discretization points (optional).

lag

vector; lag in each dimension (optional).

ylabel

character; name used to label the data.

ynames

character vector; names used to label the curves.

dimnames

character vector; names used to label the dimensions.

x

funcional data (npf.data-class object).

...

further arguments passed to or from other methods.

Value

Returns an object of class

npf.data

(extending npsp::data.grid), a list with the arguments y, ylabel and ynames as components, and two additional components:

  • ny number of curves (sample size).

  • grid a npsp::grid.par-class object that defines the discretization points.

Details

Only one of the arguments max or lag must be specified.

See also

Examples

fd.ozone <- npf.data(ozone, dimnames = "day")
plot(fd.ozone)