search for: thislme

Displaying 4 results from an estimated 4 matches for "thislme".

Did you mean: thislm
2012 Dec 06
1
scope, lme, ns, nlme, splines
...junk$y<-junk$x + rnorm(nrow(junk)) junk$idvar<- factor(sample(LETTERS[1:10], size=nrow(junk), replace=TRUE)) library("nlme") library(splines) fitfunction<-function(splineDF=1) { thislm<-lm( y ~ ns(x, df=splineDF), data= junk) thislm cat("finished thislm\n") thislme<-lme( fixed= y ~ ns(x, df=splineDF) , random= ~ 1 | idvar , data= junk) thislme } fitfunction() KLUDGEfit<-function(splineDF=2) { thislm<-lm( y ~ ns(x, df=splineDF), data= junk) thislm cat("finished thislm\n") mystring<-paste( "thislme<-lme( fixed...
2004 Nov 30
4
adding regression curve to xyplot
Dear R-listers, It seems that predict() behaves differently within panel.xyplot. Am I doing something stupid? Thanks, Carlisle First, without xyplot(): > lmtest <- lm(t~s,data=subset(P100,whichLon100==1 & whichLat100==1)) > lmtest Call: lm(formula = s ~ t, data = subset(P100, whichLon100 == 1 & whichLat100 == 1)) Coefficients: (Intercept) t 33.3307
2009 Nov 11
1
loop through variable names
Often I perform the same task on a series of variables in a dataframe, by looping through a character vector that holds the names and using paste(), eval(), and parse() inside the loop. For instance: thesevars<-names(environmental) environmental$ToyOutcome<-rnorm(nrow(environmental)) tableOfResults<-data.frame(var=thesevars) tableOfResults$Beta<- NA
2007 Jan 26
1
bootstrap bca confidence intervals for large number of statistics in one model; library("boot")
Sometimes one might like to obtain pointwise bootstrap bias-corrected, accelerated (BCA) confidence intervals for a large number of statistics computed from a single dataset. For instance, one might like to get (so as to plot graphically) bootstrap confidence bands for the fitted values in a regression model. (Example: Chiu S et al., Early Acceleration of Head Circumference in Children with