CreateBasis: Create an orthogonal basis of K functions in [0, 1], with...

View source: R/CreateBasis.R

CreateBasisR Documentation

Create an orthogonal basis of K functions in [0, 1], with nGrid points.

Description

Create an orthogonal basis of K functions in [0, 1], with nGrid points.

Usage

CreateBasis(
  K,
  pts = seq(0, 1, length.out = 50),
  type = c("cos", "sin", "fourier", "legendre01", "poly")
)

Arguments

K

A positive integer specifying the number of eigenfunctions to generate.

pts

A vector specifying the time points to evaluate the basis functions.

type

A string for the type of orthogonal basis.

Value

A K by nGrid matrix, each column containing an basis function.

Examples

basis <- CreateBasis(3, type='fourier')
head(basis)


fdapace documentation built on July 3, 2024, 5:08 p.m.