lines,Splinets-method {Splinets}R Documentation

Adding graphs of splines to a plot

Description

A standard method of adding splines to an existing plot.

Usage

## S4 method for signature 'Splinets'
lines(x, sID = NULL, ...)

Arguments

x

Splinets object;

sID

vector, specifying indices of splines in the splinet object to be plotted;

...

other standard graphical parameters;

References

Liu, X., Nassar, H., Podg\mbox{\'o}rski, K. "Dyadic diagonalization of positive definite band matrices and efficient B-spline orthogonalization." Journal of Computational and Applied Mathematics (2022) <https://doi.org/10.1016/j.cam.2022.114444>.

Podg\mbox{\'o}rski, K. (2021) "Splinets – splines through the Taylor expansion, their support sets and orthogonal bases." <arXiv:2102.00733>.

Nassar, H., Podg\mbox{\'o}rski, K. (2023) "Splinets 1.5.0 – Periodic Splinets." <arXiv:2302.07552>

See Also

plot,Splinets-method for graphical visualization of splines; evspline for evaluation of a Splinet-object;

Examples

#-----------------------------------------------------#
#------Adding spline lines to an existing graph-------#
#-----------------------------------------------------#
n=17; k=4; xi=sort(runif(n+2)); xi[1]=0; xi[n+2]=1 
set.seed(5)
S=matrix(rnorm((n+2)*(k+1)),ncol=(k+1))
spl=construct(xi,k,S) 
plot(spl,main="Mean Spline",lty=2,lwd=2)

RS=rspline(spl,5)
plot(RS,main="Random splines around the mean spline" )
lines(spl,col='red',lwd=4,lty=2)


[Package Splinets version 1.5.0 Index]