Dear list members,

I am trying to fit a natural cubic spline to my dataset using the ns
function in the splines package.
Specifically, I do:

library(splines)
lm(y ~ ns(x, df=3), data =data)

How do I extract the values of the interior knots of the fitted spline ?

Thanks,

Rajat

-------------------------------------------------------------------------
Rajat Tayal
Ph.D Research Scholar
Indira Gandhi Institute of Development Research,
Gen A.K.Vaidya Marg, Goregaon (East)
Mumbai

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to