powered by
Create an orthogonal basis of K functions in [0, 1], with nGrid points.
CreateBasis( K, pts = seq(0, 1, length.out = 50), type = c("cos", "sin", "fourier", "legendre01", "poly") )
A K by nGrid matrix, each column containing an basis function.
A positive integer specifying the number of eigenfunctions to generate.
A vector specifying the time points to evaluate the basis functions.
A string for the type of orthogonal basis.
basis <- CreateBasis(3, type='fourier') head(basis)
Run the code above in your browser using DataLab