List:
Thank you for the replies to my post yesterday. Gabor and Phil also gave
useful replies on how to improve the function by relying on mapply
rather than the explicit for loop. In general, I try and use the family
of apply functions rather than the looping constructs such as for, while
etc as
, 2006 8:56 AM
To: Doran, Harold
Cc: r-help@stat.math.ethz.ch; Phil Spector
Subject: Re: Timing benefits of mapply() vs. for loop was:
[R] Wrap a loop inside a function
Note that if you use mapply in the way I suggested, which is
not the same as in your post, then its just as fast. (Also
Look for progress() in the svMisc package
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Florent Bresson
Sent: Wednesday, July 19, 2006 10:13 AM
To: r-help@stat.math.ethz.ch
Subject: [R] Progress in a loop
Hi, I have to use a loop to perform a
I need to wrap a loop inside a function and am having a small bit of
difficulty getting the results I need. Below is a replicable example.
# define functions
pcm - function(theta,d,score){
exp(rowSums(outer(theta,d[1:score],'-')))/
apply(exp(apply(outer(theta,d, '-'), 1, cumsum)), 2,
Very true, the resounding echo was large.
Thanks, Doug.
-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf
Of Douglas Bates
Sent: Wednesday, July 19, 2006 4:20 PM
To: Doran, Harold
Cc: r-help@stat.math.ethz.ch
Subject: Re: [R] Wrap a loop inside
Can you provide an example of what you have done with lme so we might be able
to evaluate the issue?
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of ESCHEN Rene
Sent: Wednesday, July 19, 2006 7:37 AM
To: r-help@stat.math.ethz.ch
Subject: [R]
There is a paper by Rogosa and Saner which shows some equivalences in
what you are doing under certain conditions. They show similarities
between bootstrapping with linear models and how the estimates might be
similar to those obtained from a mixed model.
Rogosa, D. R., and Saner, H. M. (1995).
You need the VarCorr function. I think you mean that lmer is in the
Matrix package.
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of prabhu bhaga
Sent: Tuesday, July 11, 2006 11:19 AM
To: r-help@stat.math.ethz.ch
Subject: [R] storing the estimates
In the old version of lme, one could construct a grouped data object and
this would alleviate the need to specify the random portion of the
model. So, Spencer's call is equivalent to
fm1 - lme(distance ~ age, random= ~age| Subject, data = Orthodont)
This condition does not hold under lmer,
Brian
Additional covariates would be included in the fixed portion of the model. For
example
test.1 - lmer(y ~ b1 + b2 + b3 +age+sex+...+ (1 | group), org.data)
From: [EMAIL PROTECTED] on behalf of Brian Perron
Sent: Wed 6/28/2006 12:25 PM
To:
Use the functions in library(grDevices) for jpeg, bmp, or png formats.
Or, you can use postscript() for an eps file. Of course, I personally
think tex files make for much better looking presentations if you can be
persuaded.
Harold
-Original Message-
From: [EMAIL PROTECTED]
I think you want
ifelse(x=='N',0,1)
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Davis,
Jacob B.
Sent: Friday, June 16, 2006 4:46 PM
To: r-help@stat.math.ethz.ch
Subject: [R] Vector Manipulation
I have a vector that has 1,974 elements
I have data in a long format where each row is a student and each
student occupies multiple rows with multiple observations. I need to
subset these data based on a condition which I am having difficulty
defining.
The dataset I am working with is large, but here is a simple data
structure to
' , direction='long')
long - long[order(long$id) , ]
long - long[c(-2,-13),]
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Doran, Harold
Sent: Tuesday, June 06, 2006 5:08 PM
To: r-help@stat.math.ethz.ch
Subject: [R] Subset data in long format
I have
Comments below:
mod1-lmer(sp~cla+(1|cla:plotti), data=bacaro,
family=poisson(link=log))
summary(mod1) #sunto del modello
Generalized linear mixed model fit using PQL
Formula: sp ~ cla + (1 | cla:plotti)
Data: bacaro
Family: poisson(log link)
AIC BIC
Pryseley:
You asked this question last week and received answers to that question
along with other suggestions from Doug Bates and myself. Is there some
reason the post by Andrew Robinson is not working?
Harold
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On
.
From: Pryseley Assam [mailto:[EMAIL PROTECTED]
Sent: Thursday, June 01, 2006 9:38 AM
To: Doran, Harold
Cc: r-help@stat.math.ethz.ch
Subject: RE: [R] Help: lme
Good day,
Yeah i tried most of the suggestions
?tapply
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of r user
Sent: Tuesday, May 30, 2006 12:27 PM
To: rhelp
Subject: [R] average by group...
I have a dataframe with 700,000 rows and 2 vectors
(columns): group and score.
I wish to
PROTECTED] On
Behalf Of Peter Dalgaard
Sent: Tuesday, May 30, 2006 1:09 PM
To: Doran, Harold
Cc: r user; rhelp
Subject: Re: [R] average by group...
Doran, Harold [EMAIL PROTECTED] writes:
?tapply
Nope.
?ave
-Original Message-
From: [EMAIL PROTECTED]
[mailto
As noted below, it is hard to diagnose the specific issue. But, as a
recommendation, I would suggest using lmer and then investigating the
parameters of the model using the MCMCsamp() function. You can then do all
diagnostics using the various functions in the coda package as MCMCsamp()
for
correlations in the data by incorporating random effects.
HTH,
Harold
-Original Message-
From: Andrew Gelman [mailto:[EMAIL PROTECTED]
Sent: Mon 5/22/2006 11:12 AM
To: Doran, Harold
Cc: r-help@stat.math.ethz.ch; [EMAIL PROTECTED]
Subject:Re: [R] Can lmer() fit
be missing
something.
-Original Message-
From: Andrew Gelman [mailto:[EMAIL PROTECTED]
Sent: Sun 5/21/2006 7:35 PM
To: Doran, Harold
Cc: r-help@stat.math.ethz.ch; [EMAIL PROTECTED]
Subject:Re: [R] Can lmer() fit a multilevel model embedded in a
regression?
Harold,
I
I have a data frame of ~200 columns and ~20,000 rows where each column
consists of binary responses (0,1) and a 9 for missing data. I am
interested in finding the columns for which there are fewer than 100
individuals with responses of 0.
I can use an apply function to generate a table for each
Prof Gelman:
I believe the answer is yes. It sounds as though persons are partially crossed
within food items?
Assuming a logit link, the syntax might follow along the lines of
fm1 - lmer(DV ~ foods + sex + age + (1|food_item), data, family =
binomial(link='logit'), method = Laplace,
here here. I had the wonderful benefit of sitting in a coffee shop in San
Francisco with Doug listening to an excellent explanation. I only wish we could
replicate that as an FAQ!
Thanks for this, Doug.
-Original Message-
From: [EMAIL PROTECTED] on behalf of Marc Schwartz
Sent:
[mailto:[EMAIL PROTECTED]
Sent: Wednesday, May 17, 2006 1:50 AM
To: Doran, Harold; r-help@stat.math.ethz.ch
Subject: AW: [R] Interrater and intrarater variability
(intraclass correlationcoefficients)
Dear Harold,
Thanks! I searched for Hoyt's Anova in R - but without
success. Do you
It sounds as thought you are interested in Hoyt's Anova which is a form
of generalizability theory. This is usually estimated using by getting
the variance components from ANOVA.
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Karl Knoblick
Sent:
The issue is not unresolved within lmer, but with the statistical model itself.
SAS gives you alternatives for the ddf such as Kenward-Roger. But, as I have
noted on the list before, this makes the assumption that the ratio of the
variances follow an F distribution and that the only remaining
reasonable rates of convergence for many integrals that I
thought should be reasonably well behaved.
However, as I mentioned above, my work in this area
suggested I might more wisely invest my time in spline integration.
Best Wishes,
spencer graves
Doran, Harold wrote
Kevin
They do not exist. This question has come up often. Try the following to
see a thread
RSiteSearch('lmer p-values')
Harold
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Hai Lin
Sent: Friday, May 05, 2006 12:46 PM
To:
You can use object.size()
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of r user
Sent: Thursday, May 04, 2006 2:56 PM
To: rhelp
Subject: [R] Determining the memory used by a dataset or vector?
Is there a function that reports the amount of
I've written a series of functions that evaluates an integral from -inf to a or
b to +inf using equally spaced quadrature points along a normal distribution
from -10 to +10 moving in increments of .01. These functions are working and
give very good approximations, but I think they are
Ezra
I don't know what the elements of your matrix are, but if there are a
large proportion of 0s you can work with sparse matrices in the Matrix
package.
Harold
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Erez
Sent: Tuesday, April 25, 2006 8:39
I have what I'm sure will turn out to be straightforward. I want to
store the results of a loop for some operations from a patterned vector.
For example, the following doesn't give what I would hope for
ss - c(2,3,9)
results - numeric(length(ss))
for (i in seq(along=ss)){
results[i] - i + 1
I have an array from an mcmc simulation and I'd like to try and use the
monitor function in R2WinBUGS. The R2WinBUGS package is in the search
path and when I try help(monitor) the help page appears for the
function. But, when I try and use it the following happens:
monitor(sims)
Error: couldn't
You didn't do anything wrong, lmer doesn't give them. And, for good reason.
I've been a bit indoctrinated by D. Bates, so let me share what I've learned.
With simple analysis of variance models with simple error structures, it is
known that the ratio of the variances follow and F distribution.
: Thursday, April 20, 2006 2:23 PM
To: Doran, Harold
Cc: Amelie LESCROEL; r-help@stat.math.ethz.ch
Subject: Re: [R] Missing p-values using lmer()
Hi, Harold:
Am I correct that the tool currently preferred for estimating
p-values for lmer is mcmcsamp?
Amélie: My favorite tool for exploring
I am writing a small function to approximate an integral that cannot be
evaluated in closed form. I am partially successful at this point and am
experiencing one small, albeit important problem. Here is part of my
function below.
This is a psychometric problem for dichotomously scored test
do not know of a built in function that would do this. Any
suggestions?
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Doran, Harold
Sent: Wednesday, April 19, 2006 11:51 AM
To: r-help@stat.math.ethz.ch
Subject: [R] Function to approximate complex integral
Yup, thanks, all . I tried outer but didn't sum the elements before I
posted. Thanks
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Marc Schwartz
(via MN)
Sent: Wednesday, April 19, 2006 3:46 PM
To: Doran, Harold
Cc: r-help@stat.math.ethz.ch
Subject: Re
!), will we be able to
specify the cov structure of the random effects similarly to what was done in
lme(), i.e. using pdMat objects and so forth?
Thanks!
joran
On Apr 13, 2006, at 3:34 PM, Doran, Harold wrote:
I think you want the random effects to be independent. If so then you
need
lmer
resid(model)
-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Bill Shipley
Sent: Thursday, April 13, 2006 10:55 AM
To: R help list
Subject: [R] obtaining residuals from lmer
Hello. I cannot find out how to extract the residuals from a mixed model using
I have a data frame where I need to subset certain rows before I compute
the mean of another variable. However, the value that I need to subset
by is found in multiple columns. For example, in the data below the
value R160 is found in the first and second columns (itd_1 and
itd_45). These
I think you want the random effects to be independent. If so then you need
lmer(response ~ time +(time|id) + (time-1|id), data)
Harold
-Original Message-
From: [EMAIL PROTECTED] on behalf of Matthias Kormaksson
Sent: Thu 4/13/2006 4:04 PM
To: r-help@stat.math.ethz.ch
Cc:
You can do this yourself with ginv()
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Cal Stats
Sent: Monday, April 03, 2006 7:40 PM
To: r-help@stat.math.ethz.ch
Subject: [R] lm - Generalized Inverse
Hi,
is there a lm which will implement the
Paul:
I may have found the issue (which is similar to your conclusion). I
checked using egsingle in the mlmRev package as these individuals are
strictly nested in this case:
library(mlmRev)
library(nlme)
fm1 - lme(math ~ year, random=~1|schoolid/childid, egsingle)
fm2 - lmer(math ~ year
Alan:
I think you need to multiply the values in the bVar slot by th residual
variance to get the correct estimates.
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Alan Bergland
Sent: Tuesday, March 21, 2006 6:31 AM
To: r-help@stat.math.ethz.ch
John:
Linear models can have different covariance structures to accommodate
certain dependencies in the data. The functions for data analysis in the
lme4 package are flexible and can be structured as such. For example,
when random intercepts only are included, this is akin to compound
symmetry,
Well, not if you are interested in lmer() syntax. The book is good with
the conceptual issues in modeling the data, but does not include any
reference to fitting models with lmer.
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Gregor Gorjanc
Sent:
Here is a snip of code I used in a program that was looping for a really
long time, maybe this can be helpful. You will need the svMisc package.
print(i)
progress(i)
Sys.sleep(.05)
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Jeffrey Racine
Sent:
Is something like this what your looking for:
x - matrix(c(rnorm(100)),ncol=10)
sub - sample(5, replace=TRUE) # For sampling with replacement
x[sub,]
Harold
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of mark salsburg
Sent: Wednesday, March 15,
I didn't follow this thread entirely, but I did make a LaTeX recommendation and
I know that wasn't what you were asking for. But, if I may, let me respond to
the ideas you present below in an attempt to be somewhat persuasive.
IMHO, this are horrible inefficiencies of SPSS and other packages,
Well, I don't know if it can be used with Word or not, but you might
consider Sweave for use with LaTeX. Maybe if you use the sink() command
this might work, but I haven't tried it.
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Tom Backer
Johnsen
Sent:
Paul:
It is a little difficult to understand what you are trying to translate
since you do not show what the model would look like using lme. If you
show lme, then it is easy to translate into lmer syntax.
A few thoughts, first, use lmer in the Matrix package and not in lme4.
Second, see the
Type license() for this info
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of
[EMAIL PROTECTED]
Sent: Tuesday, February 07, 2006 8:50 AM
To: r-help@stat.math.ethz.ch
Subject: [R] R- License
Hello. We are trying to install R on our network, and I wanted to
Dear List:
I'm trying to use the boot function to estimate some standard errors. I
actually programmed a bootstrap using some homebrew code and it worked
fine. But, I am trying to use the more efficient boot function. I have
placed some sample data for replication of my problem at the bottom of
Stratford [mailto:[EMAIL PROTECTED]
Sent: Tue 1/24/2006 8:57 PM
To: Doran, Harold; r-help@stat.math.ethz.ch
Cc:
Subject:RE: [R] nested ANCOVA: still confused
R-users and Harold.
First, thanks for the advice; I'm almost there.
The code I'm using now is
library(nlme)
bb - read.csv
Try
paste('test',1,sep='')
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of r user
Sent: Wednesday, January 25, 2006 1:58 PM
To: rhelp
Subject: [R] paste - eliminate spaces?
I am trying to combine the value of a variable and text.
e.g.
I want test1,
Dear Jeff:
I see the issues in your code and have provided what I think will solve
your problem. It is often much easier to get help on this list when you
provide a small bit of data that can be replicated and you state what
the error messages are that you are receiving. OK, with that said, here
Yes, there are now multiple functions. One is the lmer() function in the
matrix package. Another is in the nlme package and is the lme()
function. Lmer is the newer version and the syntax has changed just
slightly. To see samples of the lmer function type the following at
your R command prompt
Yen Lin:
I'd like to try and offer a little help, but I'm still unclear on your
data structure and problem. You say, they are all categorical variables.
But, does this apply also to your dependent variable? If so, lme is the
wrong function to use.
You also say you want to decompose tha variation
Peter:
Almost correct. You need to add the variance component for the highest
level of nesting, so your model would be
lmer.m1.1 = lmer(Y~A+B+C+(1|D:E) + (1|E), data=data,method=ML)
But, yes, the : is used to note implicit nesting in lmer similar to the
syntax used for / in lme. The syntax
Jason
the lmer() function in the Matrix package is what you will need.
-Original Message-
From: [EMAIL PROTECTED] on behalf of Jason Marshal
Sent: Tue 1/3/2006 8:10 AM
To: r-help@stat.math.ethz.ch
Cc:
Subject:[R] Including random effects in logistic regression.
Uli:
The graphic in the paper, sometimes called a catepillar plot, must be
created with some programming as there is (as far as I know) not a
built-in function for such plots. As for the contents of bVar you say
the dimensions are 2,2,28 and there are two random effects and 28
schools. So, from
There are certain functions which can easily extracts the various
components, however. For instance, you can grab the fixed effects using
fixef(), the variance components using VarCorr, and the standard errors
of the fixed effects using vcov()
-Original Message-
From: [EMAIL PROTECTED]
See ?mvrnorm
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Lisa Wang
Sent: Thursday, December 15, 2005 10:34 AM
To: R-Help
Subject: [R] How to simulate correlated data
Hello there,
I would like to simulate X --Normal (20, 5)
If you suspect a local maxima, have you tried different starting to
values to see if the likelihood is maximized in the same place?
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Ivar Herfindal
Sent: Wednesday, December 14, 2005 5:34 AM
To:
Dear List:
A while back I found a web site called the Rosetta Stone for Computer
Algebra Systems showing how to do similar operations in different
symbolic programs. This has been very helpful for moving between
Mathematica, Yacas and Maxima.
I wonder if anyone maintains something akin to this
Dear list:
A datafile was sent to me that is very large (92890 x 1620) and is *very*
sparse. Instead of leaving the entries with missing data blank, each cell with
missing data contains a dot (.)
The data are binary in almost all columns, with only a few columns containing
whole numbers,
?)
Clearly, enough memory is allocated to handle this file. But, I also
wonder why R then locks and I need to do a forced shut down.
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Doran, Harold
Sent: Tuesday, December 13, 2005 5:33 AM
To: r-help
Beyond asking why, and not letting R do work for you, let me just note
that inverting the full matrix is often computationally wasteful. You
can take the Cholesky decomposition M = L'L where M is your matrix and
then only work with L. Other than that, there are two packages for
dealing with sparse
Good point. Probably not for any subsequent use in R. But, I work in an
org that uses SAS, HLM, SPSS, among others. As a part of our control
processes at times we replicate analyses in different software programs.
For instance, we will replicate lmer functions using HLM. But, HLM
requires a matrix
Dear List:
When I click on the link to download a reference manual for a package on
cran, I get an error message that the file is damaged and could not be
repaired. I randomly chose various packages and the same error message
appears.
Are the links actually broken? I have also restarted my
, Harold
Cc: r-help@stat.math.ethz.ch
Subject: Re: [R] Broken links on CRAN
Doran, Harold [EMAIL PROTECTED] writes:
Dear List:
When I click on the link to download a reference manual for a package
on cran, I get an error message that the file is damaged and could not
be repaired. I randomly
Hi Duncan
I tried various ones, but try ash.pdf. I was not able to work with this
file. But, when I go to another mirror, I can open this file no problem.
Harold
-Original Message-
From: Duncan Murdoch [mailto:[EMAIL PROTECTED]
Sent: Monday, December 05, 2005 3:00 PM
To: Doran, Harold
Stephan:
It is my understanding that the corClass functions are not able to be
used with lmer() at this time.
Harold
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Stephan Moratti
Sent: Friday, December 02, 2005 6:58 AM
To: r-help@stat.math.ethz.ch
Dear List:
I have created some code to simulate data from a complex sample where
5000 students are nested in 50 schools. My code returns a dataframe with
a variable representing student achievement at a single time point. My
actual code for creating this is below.
What I would like to do is
Giuseppe
GIven the information below it is difficult to provide help. But, you might use
the lmer() function in the Matrix package in a fashion such as
lmer(A ~ B +(1|ID), data)
where ID is a grouping variable. There are plently of papers on lme and lmer in
the R news as well as a book by
Dear List:
We are generating data such that students are clustered in schools for
some item response data for a simulation study. One component of our
simulation is to generate measurement error from a logistic distribution
with a mean of 0 and standard deviation of 1.7 to match the logistic
I do not believe another IRT package exists. However, I have recently used the
rasch() function in ltm for a study I am doing and have found it very useful.
I'm curious (as I'm sure the ltm developer is) as to what are you doing that
ltm cannot handle.
Harold
-Original Message-
James,
By assumption, sigma and tau are assumed uncorrelated, which I believe
Deepayan noted below. Sigma is also random error so it is uncorrelated
with your fixed effects. What are the covariance terms you are seeking?
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL
related to a fixed
effect, then your model is misspecified and there are omitted
characteristics that need to be accounted for.
-Original Message-
From: Wassell, James T., Ph.D. [mailto:[EMAIL PROTECTED]
Sent: Thursday, November 17, 2005 11:52 AM
To: Doran, Harold; r-help@stat.math.ethz.ch
I don't have an answer, but also want to point out that whenever I try
and download the pdf documentation associated with a package, my Acrobat
opens but tells me the file is corrupted. I did this for a random
selection of packages and the same problem seems to reoccur. I'm not
sure if this is
Sorry to be blunt, but to make the statement that it is unacceptable without
providing any reason why the model may fail to converge seems a little
presumptious. Your statement really bothers me, especially knowing how hard the
developer works on keeping this function at a premier level. Ask
Dear Jacques
I think your question is a little confusing, but let me take a stab at
what I think you're getting at. It seems you are trying to find the
statistical significance of a variance component in your lme model, and
not the significance of a fixed effect. If this is what you are looking
I think what you're looking for is in anova()
fm1 - lmer(dv ~ IV ...)
anova(fm1)
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Jacques VESLOT
Sent: Thursday, October 27, 2005 2:22 AM
To: R-help@stat.math.ethz.ch
Subject: [R] F tests for random
Doran, Harold [EMAIL PROTECTED] responded:
There is an issue with implicit nesting in lmer. In your lme() model
you nest block/irrigation/density/fertilizer. In lmer you need to do
something like (I dind't include all of your variables, but I think
the makes the point)
lmer(yield~irrigation
syntax
Em Seg 24 Out 2005 18:08, Doran, Harold escreveu:
Ronaldo
See the article on lmer pasted below for syntax. It is the only
current source documenting the code. In lmer(), the nesting structure
for the ranmdom effects is handled in a slightly different way. If
your observations
Ronaldo
See the article on lmer pasted below for syntax. It is the only current source
documenting the code. In lmer(), the nesting structure for the ranmdom effects
is handled in a slightly different way. If your observations are nested as you
note, then you can use
lmer(y~x1 + x2 +(1|x1) +
Use file.choose() instead
source(file.choose())
This will open a dialogue box and might be easier for you to find your
file.
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Clark Allan
Sent: Friday, October 14, 2005 7:06 AM
To:
Ctrl L
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Leonardo L Miceli
Sent: Friday, September 30, 2005 8:36 AM
To: r-help@stat.math.ethz.ch
Subject: [R] Clear Console
Hi,
What is the function to clear the console?
tks
[[alternative HTML
Mike
I do not believe this is availabe in either lme or lmer in R, only S-Plus.
-Original Message-
From: [EMAIL PROTECTED] on behalf of Mike Cheung
Sent: Thu 9/29/2005 4:32 AM
To: r-help@stat.math.ethz.ch
Cc:
Subject:[R] how to fix the level-1 variances in lme()?
You cannot. Also, it's not that the distribution of the random effects
is not symmetric, but that it *may* not be symmetric, and this is an
assumption that should be checked.
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Roel de Jong
Sent: Thursday,
See ?pdf or ?postscript
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Mike Jones
Sent: Thursday, September 29, 2005 3:22 PM
To: r-help@stat.math.ethz.ch
Subject: [R] Saving Graphics
Hello all,
I'm having difficulty automatically saving graphs.
Is
I think you might have confused lme code with lmer code. Why do you have
c/d in the random portion?
I think what you want is
lmer(a ~ b + (1 | c)+(1|d))
Which gives the following using your data
Linear mixed-effects model fit by REML
Formula: a ~ b + (1 | c) + (1 | d)
AIC BIC
: Re: [R] Possible bug in lmer nested analysis with factors
On 16 Sep 2005, at 17:12, Doran, Harold wrote:
I think you might have confused lme code with lmer code. Why do you
have c/d in the random portion?
Apologies. I obviously have done something of the sort. I assumed that
the 'random
There is a Springer publication All of Statistics: a concise course in
statistical inference by Larry Wasserman that might be what you are
looking for. The book also has an emphasis on R and his web site has
code and data sets for analysis of the examples used throughout.
-Harold
-Original
Only the random portion will differ as in:
lmer(lognrms ~ Group*Rotation*muscle*side*support*arms + (1|Subject) +
(1|Stratum) + (1|rep), Data)
-Original Message-
From: [EMAIL PROTECTED] on behalf of Ross Darnell
Sent: Mon 9/12/2005 9:28 PM
To: r-help@stat.math.ethz.ch
Cc:
Dear list:
I'm hoping to tap in to the statistical expertise in the group,
especially those familiar with simulation techniques. I'm finalizing a
study where I obtain standard errors from two sources. The first source
is a monte carlo simulation and the other source is an analytical model
I have
If you are indeed using lme and not lmer then the needed function is
VarCorr(). However, 2 recommendations. First, this is a busy list and
better emails subject headers get better attention. Second, I would
recommend using lmer as it is much faster. However, VarCorr seems to be
incompatible with
101 - 200 of 289 matches
Mail list logo