similar to: a question about the command "followup.plot" of epicale package

Displaying 20 results from an estimated 5000 matches similar to: "a question about the command "followup.plot" of epicale package"

2008 Jul 18
2
column wise paste of data.frames
Hi everybody! I'm sure that I overlook something and feel quite stupid to ask, but I have not found an easy solution to the following problem: Take e.g. the Orthodont data from the nlme package: > head(Orthodont) Grouped Data: distance ~ age | Subject distance age Subject Sex 1 26.0 8 M01 Male 2 25.0 10 M01 Male 3 29.0 12 M01 Male 4 31.0 14 M01 Male
2010 Jun 22
2
xyplot: adding pooled regression lines to a paneled type="r" plot
Consider the following plot that shows separate regression lines ~ age for each subject in the Pothoff-Roy Orthodont data, with separate panels by Sex: library(nlme) #plot(Orthodont) xyplot(distance ~ age|Sex, data=Orthodont, type='r', groups=Subject, col=gray(.50), main="Individual linear regressions ~ age") I'd like to also show in each panel the pooled OLS
2009 Mar 16
1
Please help! How do I change the class of a numeric variable in a grouped data object to a factor?
Hi all I’m in desperate need of help. I’m working with a grouped data object, called Orthodont in the nlme package in R, and am trying to fit various models (learning methods for my thesis), but one of the variables in the object is numeric, (age) and I need it to be a factor. I’ve tried: as.factor(Orthodont$age) as.factor(as.character(Orthodont$age)) and various other things, but when I then
2008 May 09
1
Using lme() inside a function
Dear R-help I'm working on a large dataset which I have divided into 20 subsets based on similar features. Each subset consists of observations from different locations and I wish to use the location as a random effect. For each group I want to select regressors by a stepwise procedure and include a random effect on the intercept. I use stepAIC() and lme(). (The lmer()-function doesn't
2011 Feb 28
3
Measuring correlations in repeated measures data
R-helpers: I would like to measure the correlation coefficient between the repeated measures of a single variable that is measured over time and is unbalanced. As an example, consider the Orthodont dataset from package nlme, where the model is: fit <- lmer(distance ~ age + (1 | Subject), data=Orthodont) I would like to measure the correlation b/t the variable "distance" at
1999 Jul 01
1
lme
I am using rw0641. In my continuing quest to understand repeated measures analysis, I again return to lme. I exported the Potthoff and Roy data Orthodont.dat from S-PLUS 4.5 to avoid capture errors and ran the examples in the R help. I imported the data.frame with data <- read.table("Orthodont.dat",header=T) attach(data) and created the objects Orthodont.fit1 <-
2008 May 09
2
How can one make stepAIC and lme
Dear R-help I'm working on a large dataset which I have divided into 20 subsets based on similar features. Each subset consists of observations from different locations and I wish to use the location as a random effect. For each group I want to select regressors by a stepwise procedure and include a random effect on the intercept. I use stepAIC() and lme(). (The lmer()-function doesn't
2010 Jul 15
4
Sweave: infelicities with lattice graphics
In a paper I'm writing using Sweave, I make use of lattice graphics, but don't want to explicitly show (or explain) in the article text the print() wrapper I need in code chunks for the graphs to appear. I can solve this by including each chunk twice, with different options, as in <<ortho-xyplot1-code, keep.source=TRUE, eval=FALSE>>= library(nlme) library(lattice)
2004 Aug 27
2
degrees of freedom (lme4 and nlme)
Hi, I'm having some problems regarding the packages lme4 and nlme, more specifically in the denominator degrees of freedom. I used data Orthodont for the two packages. The commands used are below. require(nlme) data(Orthodont) fm1<-lme(distance~age+ Sex, data=Orthodont,random=~1|Subject, method="REML") anova(fm1) numDF DenDF F-value p-value (Intercept) 1
2005 Jul 12
1
nlme plot
Hello, I am running this script from Pinheiro & Bates book in R Version 2.1.1 (WinXP). But, I can't plot Figure 2.3. What's wrong? TIA. Rod. --------------------------------------------------------- >library(nlme) > names( Orthodont ) [1] "distance" "age" "Subject" "Sex" > levels( Orthodont$Sex ) [1] "Male"
2002 Dec 17
1
lme invocation
Hi Folks, I'm trying to understand the model specification formalities for 'lme', and the documentation is leaving me a bit confused. Specifically, using the example dataset 'Orthodont' in the 'nlme' package, first I use the invocation given in the example shown by "?lme": > fm1 <- lme(distance ~ age, data = Orthodont) # random is ~ age Despite the
2006 Jul 03
1
panel ordering in nlme and augPred plots
Hi, I'm new at this, I'm very confused, and I think I'm missing something important here. In our pet example we have this: > fm <- lme(Orthodont) > plot(Orthodont) > plot(augPred(fm, level = 0:1)) which gives us a trellis plot with the females above the males, starting with "F03", "F04", "F11", "F06", etc. I thought the point of
2005 Jan 03
1
different DF in package nlme and lme4
Hi all I tried to reproduce an example with lme and used the Orthodont dataset. library(nlme) fm2a.1 <- lme(distance ~ age + Sex, data = Orthodont, random = ~ 1 | Subject) anova(fm2a.1) > numDF denDF F-value p-value > (Intercept) 1 80 4123.156 <.0001 > age 1 80 114.838 <.0001 > Sex 1 25 9.292 0.0054 or alternatively
2006 May 27
1
Recommended package nlme: bug in predict.lme when an independent variable is a polynomial (PR#8905)
Full_Name: Renaud Lancelot Version: Version 2.3.0 (2006-04-24) OS: MS Windows XP Pro SP2 Submission from: (NULL) (82.239.219.108) I think there is a bug in predict.lme, when a polynomial generated by poly() is used as an explanatory variable, and a new data.frame is used for predictions. I guess this is related to * not * using, for predictions, the coefs used in constructing the orthogonal
1999 Jun 02
1
lme problem ?
Dear friends. I tried the session below with 10 MB in both vsize and nsize but didn't get the example work. Is this a problem in LME or in me or both or somewhere else or undefined ? R : Copyright 1999, The R Development Core Team Version 0.64.0 Patched (May 3, 1999) R is free software and comes with ABSOLUTELY NO WARRANTY. You are welcome to redistribute it under certain conditions. Type
2007 Nov 09
1
Confidence Intervals for Random Effect BLUP's
I want to compute confidence intervals for the random effect estimates for each subject. From checking on postings, this is what I cobbled together using Orthodont data.frame as an example. There was some discussion of how to properly access lmer slots and bVar, but I'm not sure I understood. Is the approach shown below correct? Rick B. # Orthodont is from nlme (can't have both nlme and
2013 Sep 30
1
predictions in nlme without fixed covariantes
Dear all, predict.lme() throws an error when the fixed part consists of only an intercept and using newdata. See the reproducible example below. I've tracked the error down to asOneFormula() which returns in this case NULL instead of a formula. Changing NULL instead of ~1 in that function (see below) solves the problem in the case of an intercept only model (m1). It does not solve the problem
2005 Sep 29
1
plot.augPred sorted and labelled according second factor
Hi using this code example: library(nlme) fm1 <- lme(Orthodont, random = ~1) plot(augPred(fm1)) is there any way to have the plots in each cell labelled and ordered according to Orthodont$Sex? I.e. in addition to the bar with the label for Orthodont$Subject there is another bar labelling the Sex of the subject? thanks a lot christoph --
2011 Dec 13
8
How to compute 95%CI for OR from logistic regression?
Hi all: My data has 3 variables: age(3levels : <30y=1 30-50y=2, >50y=3) gender(Male=0, Female=1) CD4 cell count(raw lab measurement) y(1:death 0:alive) I perform logistic regression to find out the factors that influence y. result<-glm(y ~ factor(age) + factor(gender) + CD4,family = binomial) >From the result,I can get OR(Odds Ratio) of gender via exp(Estimate of Female,
2003 Mar 04
2
How to extract R{i} from lme object?
Hi, lme() users, Can some one tell me how to do this. I model Orthodont with the same G for random variables, but different R{i}'s for boys and girls, so that I can get sigma1_square_hat for boys and sigma2_square_hat for girls. The model is Y{i}=X{i}beta + Z{i}b + e{i} b ~ iid N(0,G) and e{i} ~ iid N(0,R{i}) i=1,2 orth.lme <- lme(distance ~ Sex * age, data=Orthodont, random=~age|Subject,