Hello!
I have faced a problem in nlme-environment. My intention is to fit a
penalized spline model in mixed model framework. I want make a
comparison in smooth curves between two groups but for some reason I
get NaN in output..
Hereis the R-code I have used.
#Z.overall is for truncated lines part
knots <- seq(1.5,6.5,by=1)
Z <- outer(weekday,knots,"-")
Z.overall <- Z*(Z>0)
fit1 <- lme(weight~group*weekday, random=list(group=pdIdent(~Z.overall-1)))
summary(fit1)
Linear mixed-effects model fit by REML
Data: NULL
AIC BIC logLik
4379.838 4411.895 -2183.919
Random effects:
Formula: ~Z.overall - 1 | group
Structure: Multiple of an Identity
Z.overall1 Z.overall2 Z.overall3 Z.overall4 Z.overall5
Z.overall6 Residual
StdDev: 0.1310617 0.1310617 0.1310617 0.1310617 0.1310617
0.1310617 0.9833188
Fixed effects: normMAweight2 ~ group * weekday
Value Std.Error DF t-value p-value
(Intercept) 0.23589909 0.4431604 1545 0.5323109 0.5946
group 0.14167744 0.2629714 0 0.5387562 NaN
weekday -0.08601980 0.2770228 1545 -0.3105152 0.7562
group:weekday -0.02575775 0.1686222 1545 -0.1527542 0.8786
Correlation:
(Intr) group weekdy
group -0.957
weekday -0.911 0.883
group:weekday 0.861 -0.915 -0.953
Standardized Within-Group Residuals:
Min Q1 Med Q3 Max
-3.87210364 -0.64218983 -0.03839294 0.60534552 4.30615258
Number of Observations: 1549
Number of Groups: 2
Warning message:
In pt(q, df, lower.tail, log.p) : NaNs produced
Kindly Regards,
Anna-Leena Orsama
______________________________________________
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.