Displaying 20 results from an estimated 4000 matches similar to: "Plotting confidence intervals for lme"
2005 Jul 13
1
Name for factor's levels with contr.sum
Good morning,
I used in R contr.sum for the contrast in a lme model:
> options(contrasts=c("contr.sum","contr.poly"))
> Septo5.lme<-lme(Septo~Variete+DateSemi,Data4.Iso,random=~1|LieuDit)
> intervals(Septo5.lme)$fixed
lower est. upper
(Intercept) 17.0644033 23.106110 29.147816
Variete1 9.5819873 17.335324 25.088661
Variete2 -3.3794907 6.816101 17.011692
Variete3
2005 Jul 27
1
Question on glm for Poisson distribution.
Good afternoon,
I REALLY try to answer to my question as an autonomous student searching in
the huge pile of papers on my desk and on the Internet but I can't find out
the solution.
Would you mind giving me some help? Please.
#########################################
I'm trying to use glm with factors:
> Pyr.1.glm<-glm(Pyrale~Trait,DataRav,family=poisson)
If I have correctly
2005 Jun 30
2
Linear Models with mean as Intercept.
Dear advanced statisticians,
*******Objectif********
I try to set up linear models with mean as intercept:
Answer: y
Variable: x, as factor of two modalities: x(1), x(2).
I would like to have a model as:
y = mean(y)+A(i)+residuals,
with i in (1,2) and A(1) coefficient for x(1) and A(2) coefficient for x(2).
*******Trials in R*******
## Firstly:
I write in R:
>Model<-lm(y~x,Data)
2006 Apr 20
3
The contrary of command %in%
Dear r-list,
I've got a data base:
> HData[1:10,]
NumTree Site Species Date Age DBH H IdentTree
1 1 Queige Spruce 2002 184 49 33.5 Queige 1
2 2 Queige Fir 2002 NA 5 4.6 Queige 2
3 3 Queige Fir 2002 25 8 6.6 Queige 3
4 4 Queige Spruce 2002 198 47 32.5 Queige 4
5 5 Queige Fir 2002 200 59 35.3 Queige 5
6 6 Queige
2005 Jul 22
0
Significant difference of coefficients in glm with factors?
Hi and sorry to distur,
########### Setting #################
I'm trying to use glm with factors:
> Pyr.1.glm<-glm(Pyrale~Trait,DataRav,family=poisson)
> summary(Pyr.1.glm)
Call:
glm(formula = Pyrale ~ Trait, family = poisson, data = DataRav)
Deviance Residuals:
Min 1Q Median 3Q Max
-1.7117 -0.8944 -0.6237 0.6390 1.5224
Coefficients:
Estimate Std. Error z value Pr(>|z|)
2005 Dec 16
1
Vector of matrix
Dear statisticians,
I would like to save results for a "for loop" in a vector previously created.
My result would be of class "matrix".
I tried the following script:
Script:
#Creation of a previous vector
n.Tree<-2
VectorX<-rep(1,n.Tree)
#loop
for (i in 1:2) {
Ti<-MatOccurTree[Tree[i],1] #number of observation for Tree i
Xi<-matrix(data=1,nrow=Ti,ncol=2)
2007 Mar 09
1
Problem with ci.lmer() in package:gmodels
Dear Friends,
Please note that in the following CI lower > CI higher:
> require(lmer)
> require(gmodels)
> fm2 <- lmer(Reaction ~ Days + (1|Subject) + (0+Days|Subject),
sleepstudy)
> ci(fm2)
Estimate CI lower CI upper Std. Error p-value
(Intercept) 251.66693 266.06895 238.630280 7.056447 0
Days 10.52773 13.63372 7.389946 1.646900
2008 Mar 08
1
Installing odesolve package of R under Ubuntu (Debian) Linux
Bonjour,
Je cherche à installer le package odesolve du logiciel de statistique R sous
Ubuntu Linux.
C'est un package qui contient des fonctions appelant du code en Fortran.
A l'installation sous R via le shell, j'obtiens l'erreur suivante:
Hi,
I tried to install odesolve package of R under Ubuntu Linux.
But I got the following error:
ghislain@ghislain-laptop:~$ sudo R
[sudo]
2003 Jan 30
1
as.formula(string) and augPred in lme
Using formulas constructed from strings only
partially works for me in lme:
library(nlme)
data(Orthodont)
fm2<-lme(as.formula("distance~age"),data=Orthodont,random=~1|Subject)
summary(fm2) # works
augPred(fm2) # fails
#Error in inherits(object, "formula") :
#Argument "object" is missing, with no default
I assume that my use of as.formula is wrong, but
2006 Oct 08
2
latex and anova.lme problem
Dear R-helpers,
When I try
> anova(txtE2.lme, txtE2.lme1)
Model df AIC BIC logLik Test L.Ratio p-value
txtE2.lme 1 10 8590 8638 -4285
txtE2.lme1 2 7 8591 8624 -4288 1 vs 2 6.79 0.0789
> latex(anova(txtE2.lme, txtE2.lme1))
Error: object "n.group" not found
I don't even see n.group as one of the arguments of latex()
I checked to see
>
2004 Dec 31
1
lme: Confusion about Variances
Dear R users!
I used lme to fit a mixed model with random intercept and spatial Gaussian
correlation i.e. I fitted a model of the following form:
Y = X*beta + error
and
error = U + W(t) + Z
where U is the random intercept (normally distributed), W(t) the stationary
Gaussian process and Z also a normally distributed (the residual) rv. Each of
these three random variables have a variance which
2004 Apr 22
1
lme correlation structure error
Hi there fellow R-users,
I am trying to follow an example of modelling a serial correlation structure
in the textbook "Mixed Effects Model in S and Splus".
However, I am getting some very odd results. Here is what I am trying to
run:
library(nlme)
data(Ovary)
fm1<-lme(follicles~sin(2*pi*Time)+cos(2*pi*Time),data=Ovary,random=pdDiag(~s
in(2*pi*Time)))
### The example is fine up
2006 Jul 24
3
standardized random effects with ranef.lme()
Using ranef() (package nlme, version 3.1-75) with an 'lme' object I can
obtain random effects for intercept and slope of a certain level (say:
1) - this corresponds to (say level 1) "residuals" in MLWin. Maybe I'm
mistaken here, but the results are identical.
However, if I try to get the standardized random effects adding the
paramter "standard=T" to the
2004 Oct 01
4
gnls or nlme : how to obtain confidence intervals of fitted values
Hi
I use gnls to fit non linear models of the form y = alpha * x**beta
(alpha and beta being linear functions of a 2nd regressor z i.e.
alpha=a1+a2*z and beta=b1+b2*z) with variance function
varPower(fitted(.)) which sounds correct for the data set I use.
My purpose is to use the fitted models for predictions with other sets
of regressors x, z than those used in fitting. I therefore need to
2006 Aug 09
1
Joint confidence intervals for GLS models?
Dear All,
I would like to be able to estimate confidence intervals for a linear
combination of coefficients for a GLS model. I am familiar with John
Foxton's helpful paper on Time Series Regression and Generalised Least
Squares (GLS) and have learnt a bit about the gls function.
I have downloaded the gmodels package so I can use the estimable
function. The estimable function is very
2008 Feb 26
2
AIC and anova, lme
Dear listers,
Here we have a strange result we can hardly cope with. We want to
compare a null mixed model with a mixed model with one independent
variable.
> lmmedt1<-lme(mediane~1, random=~1|site, na.action=na.omit, data=bdd2)
> lmmedt9<-lme(mediane~log(0.0001+transat), random=~1|site,
na.action=na.omit, data=bdd2)
Using the Akaike Criterion and selMod of the package pgirmess
2006 Apr 25
1
summary.lme: argument "adjustSigma"
Dear R-list
I have a question concerning the argument "adjustSigma" in the
function "lme" of the package "nlme".
The help page says:
"the residual standard error is multiplied by sqrt(nobs/(nobs -
npar)), converting it to a REML-like estimate."
Having a look into the code I found:
stdFixed <- sqrt(diag(as.matrix(object$varFix)))
if (object$method
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
2010 Jan 15
1
'nlme' library - lme function results
Dear R-helpers
I am running a simple mixed effects model using lme(). The call looks
like this:
fit <- lme(Analyte~Sample, data=Data, random=~1 | Run)
I am particularly interested in the estimated random effects. When I
print the 'fit' object, it looks something like example below:
(...)
Random effects:
Formula: ~1 | Run
(Intercept) Residual
StdDev: 3.483794 3.637523
2009 Aug 14
1
post hoc test after lme
Hi!
I am quiet new with R and I have some problems to perform a posthoc test
with an lme model.
My model is the following:
>lme1<-lme(eexp~meal+time, random=~1|id,na.action=na.omit)
and then i try to get a post hoc test:
>summary(glht(lme1,linfct=mcp(meal="Tukey)))
but I get a warning message: Erreur dans as.vector(x, mode) : argument
'mode' incorrect
Thank you for your