Displaying 20 results from an estimated 7000 matches similar to: "Multiple lmer runs using 2 'for' loops"
2009 Jul 15
2
Differing Variable Length Inconsistencies in Random Effects/Regression Models
Dear All,
I am quite new to R and am having a problem trying to run a linear model
with random effects/ a regression- with particular regard to my variable
lengths being different and the models refusing to compute any further.
The codes I have been using are as follows:
vc<-read.table("P:\\R\\Testvcomp10.txt",header=T)
>> attach(vc)
>
> family<-factor(family)
>
2009 Sep 18
0
Error: length(f1) == length(f2) is not TRUE (fwd)
---------- Forwarded Message ----------
Date: 18 September 2009 19:24 +0100
From: A Singh <bzwas at bristol.ac.uk>
To: William Dunlap <wdunlap at tibco.com>
Subject: RE: [R] Error: length(f1) == length(f2) is not TRUE
Yup, they are all factors- and its still doesn't work.
Getting to the stage where I can use 'summary()' is the problem- the error
stalls the process before a
2009 Sep 18
3
Error: length(f1) == length(f2) is not TRUE
Dear R users,
I am trying to fit an lmer model with only random effects which is giving
me the following error:
Error : length(f1) == length(f2) is not TRUE
In addition: Warning messages:
1: In P1L55:family :
numerical expression has 390 elements: only the first used
2: In P1L55:family :
numerical expression has 390 elements: only the first used
I am trying to extract variance components
2009 Sep 11
0
How to block data across multiple columns?
Dear all,
Does anyone have any suggestions on how to block multiple columns of data
one at a time in the midst of an analysis, having specified the blocking
variable?
I am running a random effects model using lmer, and my data set has
multiple columns.
Individuals in the study are grouped into 60 families- which is the
blocking factor.
The random effects are markers (labeled Pxlyy below)
2009 Nov 19
0
Printing labeled summary to text file ?
Dear List,
I am trying to run a mixed model which, on the R console, prints output as
follows:
[1] "Marker"
[1] "perm no."
[1] NA
Linear mixed model fit by REML
Formula: peg.no.prm ~ 1 + (1 | family/f)
Data: modeldf
AIC BIC logLik deviance REMLdev
3119 3134 -1555 3112 3111
Random effects:
Groups Name Variance Std.Dev.
f:family (Intercept) 0.0
2009 Nov 19
1
Splitting massive output into multiple text files
Dear List,
I thought it would be much easier to put a second query into a second mail.
I need to print 426*10000 blocks of variance components data, where 426 is
the number of columns of data that have 10000 permutations of variance
generated for each of them.
I have tried printing out a smaller number of permutations for a smaller
number of markers and that has worked.
However, since a
2009 Dec 08
1
Printing 'k' levels of factors 'n' times each, but 'n' is unequal for all levels ?
Dear List,
I need to print out each of 'k' levels of a factor 'n' times each, where
'n' is the number of elements belonging to each factor.
I know that this can normally be done using the gl() command,
but in my case, each level 'k' has an unequal number of elements.
Example with code is as below:
vc<-read.table("P:\\Transit\\CORRECT
2009 Jul 16
0
Cryptic error with Roxygen
Dear all,
I'm using Roxygen for the first time and I'm getting a rather cryptic
error message. I must be doing something wrong but I have no clue what
is it. Any suggestions?
Regards,
Thierry
roxygenize("AFLP", roxygen.dir = "AFLP", copy.package = FALSE,
unlink.target = FALSE)
Writing AFLP.outlier to AFLP/man/AFLP.outlier.Rd
Writing AFLP.outlier to
2009 Nov 16
3
lapply() not converting columns to factors (no error message)
Dear List,
I'm having a curious problem with lapply(). I've used it before to convert
a subset of columns in my dataframe, to factors, and its worked. But now,
on re-running the identical code as before it just doesn't convert the
columns into factors at all.
As far as I can see I've done nothing different, and its strange that it
shouldn't do the action.
Has anybody
2009 Sep 21
4
Working around 256 byte variable names? + trouble opening large file
Dear R users,
I am trying to read in a file with 105 columns, and when trying to attach
it, get an error as follows:
> vc1<-read.table("P:\\R\\Everything-I.txt", header=T, sep=" ", dec=".",
na.strings=NA, strip.white=T)
> attach(vc1)
Error in attach(vc1) : variable names are limited to 256 bytes
Is there a way to get around this, and make R accept the
2009 Sep 23
1
More naive questions: HLM6 comparisons? what is a "stack imbalance" in lmer? does lmer center variables?
1. One general question for general discussion:
Is HLM6 faster than lmer? If so, why? What should I watch for to spot
the differences?
I'm always advocating R to students, but some faculty members are
skeptical. A colleague compared the commercial HLM6 software to lmer.
HLM6 seems to fit the model in 1 second, but lmer takes 60 seconds.
My first thought was that LM6 uses PQL by default,
2008 Aug 09
0
peg-markdown (C) and rpeg-markdown (ruby gem)
Markdowners:
I've released version 0.4.1 of peg-markdown, a C implementation of
markdown. peg-markdown uses Ian Piumarta's peg/leg parser generator to
generate a parser from a parsing expression grammar (PEG). You can
inspect the grammar for markdown at
http://github.com/jgm/peg-markdown/tree/HEAD/markdown_parser.leg
peg-markdown now provides both a C library and a standalone
2008 Jul 19
0
fixed effect significance with lmer() vs. t-test
I am looking at data of the following structure:
n <- 100
dataset <- data.frame(gender=NULL,subject=NULL,outcome=NULL)
for (i in 1:n){
gender <- c(rep("m",5),rep("f",5))
subject <- letters[1:10]
outcome <- c(rbinom(5,1,0.6),rbinom(5,1,0.4))
dataset <- rbind(dataset,cbind(gender,subject,outcome))}
I am interested in the significance of
2008 Sep 24
0
weights option in lmer
Hi all, I
am trying to run a linear mixed effect models in lmer() from the lme4
package using the weights option.
I am using the
R version 2.7.2 (2008-08-25) and lmer version in lme4_0.999375-26, which I think it is the latest version!
I am getting and error message when I add the
option "weights" in the lmer function. This is the error message I
get "Error en
2007 Aug 21
0
pvals.fnc unhappy about lmer objects
Dear folks (or Dear Professor Bates),
I'm quite confused as to the current status of some of the available
functions applicable to lmer objects. Following the examples in Baayen,
Davidson, Bates (2006), my plan is to run mcmcsamp on a random effect
model created by lmer in package lme4, then use the (perhaps outdated)
pvals to estimate p-value. But then I couldn't find pvals anywhere.
2006 Mar 29
1
Lmer BLUPS: was(lmer multilevel)
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 +(1|schoolid:childid) + (1|schoolid), egsingle)
Checking the summary of both models, the output is
2010 Mar 22
0
using lmer weights argument to represent heteroskedasticity
Hi-
I want to fit a model with crossed random effects and heteroskedastic
level-1 errors where inferences about fixed effects are of primary
interest. The dimension of the random effects is making the model
computationally prohibitive using lme() where I could model the
heteroskedasticity with the "weights" argument. I am aware that the weights
argument to lmer() cannot be used to
2008 Sep 19
0
Error message in lmer
Dear list
I try to run a bootstrap with lmer.
I often, but not always, get the error message:
Error in objective(.par, ...) :
Leading minor of order 6 in downdated X'X is not positive definite
(with the number (here 6) varying)
In R-archives I came across some threads that treated this problem,
nevertheless they refer to lmer when using it with family = "binomial", so
the
2006 Jan 10
1
extracting coefficients from lmer
Dear R-Helpers,
I want to compare the results of outputs from glmmPQL and lmer analyses.
I could do this if I could extract the coefficients and standard errors
from the summaries of the lmer models. This is easy to do for the glmmPQL
summaries, using
> glmm.fit <- try(glmmPQL(score ~ x*type, random = ~ 1 | subject, data = df,
family = binomial), TRUE)
> summary(glmmPQL.fit)$tTable
2006 Oct 23
1
Lmer, heteroscedasticity and permutation, need help please
Hi everybody,
I'm trying to analyse a set of data with a non-normal response, 2 fixed
effects and 1 nested random effect with strong heteroscedasticity in the
model.
I planned to use the function lmer : lmer(resp~var1*var2 + (1|rand)) and
then use permutations based on the t-statistic given by lmer to get
p-values.
1/ Is it a correct way to obtain p-values for my variables ? (see below)