oracle.Bspl: Fit simple nonparametric regression model with cubic...

Description Usage Arguments Value Examples

View source: R/spaddinf.R

Description

Fit simple nonparametric regression model with cubic B-splines

Usage

1
oracle.Bspl(Y, X, d, plot = FALSE, x = NULL, alpha = 0.05)

Arguments

Y

a response vector (centered)

X

vector of covariate observations

d

the number functions in the cubic B-spline basis

x

a vector of values at which evaluations of the fitted function should be returned/plotted

a

logical indicating whether a plot of the fitted function should be generated

Value

a list containing the fitted function and a vector containing the values of the fitted function at the design points

Examples

1
2
3
4
5
6
7
data <- data_gen(n = 200, q = 50, r = .9)

oracle.Bspl.out <- oracle.Bspl(Y = data$Y.oracle[,1],
                               X = data$X[,1],
                               d = 10,
                               plot = TRUE,
                               x = NULL)

gregorkb/spaddinf documentation built on July 23, 2021, 4:02 a.m.