Displaying 20 results from an estimated 10000 matches similar to: "understanding I() in lmer formula"
2017 Jun 15
0
understanding I() in lmer formula
> Is there a difference between I(x*y) and I(y*x) ?
> I have a call to lmer that results in this complaint:
> Error in is.alpha2.subordinate * ~z.min.co.res :
A reproducible example would help ...
In the absence of that, check the classes of the two variables in I() and, if you run the product on the command line, either inside I() or not, what's the class of the result?
If that
2010 Sep 10
2
lme vs. lmer, how do they differ?
windows Vista
R 2.10.1
What is the difference (or differences) between lme and lmer? Both appear to perform mixed effects regression analyses.
Thanks
John
John David Sorkin M.D., Ph.D.
Chief, Biostatistics and Informatics
University of Maryland School of Medicine Division of Gerontology
Baltimore VA Medical Center
10 North Greene Street
GRECC (BT/18/GR)
Baltimore, MD 21201-1524
(Phone)
2009 Dec 01
1
LMER: How to specify Random Effects
I saw different specifications for Random Effects and I'm confused about
the use of "/" and the use of "(0+...|)" .
Let say we have a nested structure where some countries have some
several plants in different states and we measure the reaction to a drug.
The list of Countries = USA, France, Italy
The States for USA = Michigan, Florida, California
The States for France
2006 Jan 05
1
Understanding and translating lme() into lmer() model
I am newbie in R, trying to understand and compare syntax in nlme and
lme4. lme() model from the nlme package I am interested in is:
lme.m1.1 = lme(Y~A+B+C,random=~1|D/E,data=data,method="ML")
(for simplicity reason, I am giving generic names of factors)
If I understand well, there are three fixed factors: A, B and C, and two
random factors: D and E. In addition to that, E is nested in
2008 Nov 19
3
formula in lmer including both nested and crossed effects
Dear all,
I was wondering if someone could help me with the specification of a
formula including both nested and crossed effects in the same model in
lmer. I have one predictor variable, x, and three grouping factors,
a,b and c. Factor b is nested in a but is partially crossed with c.
Also, I'm interested in an interaction between the crossed effects b
and c. I specified a formula in lmer as
2012 Oct 23
1
Minimizing Computational Time
Dear R-users,
May I seek some suggestions from you. I have a long programme written in R
with several 'for' loops inside. I just want to get them out by any elegant
way (if there is!) to reduce the computational time of the main programme.
For instance, is there any smart way for the following programme that will
lessen time?
2012 Jul 03
2
Help with lmer formula
Hey all -
I am a newbie on mixed-effects models. I want to estimate the following
model:
Y_it = alpha_0t + alpha_1t*X_it + e_it
alpha_0t = gamma_00 + u_0t
alpha_1t = gamma_10 + gamma_11*W_it + u_1j
Where Y is my outcome, X is my level-1 predictor, and W is my level 2
predictor.
I am not sure if I am doing it right. Is this the correct specification of
the formula?
model = lmer(Y ~ X + X:Y + (
2013 Mar 11
2
vertical lines in R plot
Dear All,
May I seek your suggestion on a simple issue. I want to draw vertical lines
at some positions in the following R plot. To be more specific, I wish to
draw vertical lines at d=c(5.0,5.5,6) and they should go till
p=c(0.12,0.60,0.20) . I haven't found any way out, though made several
attempts. Please run the following commands first if you are interested in!
2005 Mar 02
1
Warning: number of items to replace is not a multiple of replacement length
I feel like a complete dolt, as I know this question has been asked by
others on a fairly regular basis, but I'm going in circles trying to get
the following to work:
id.prob<-function (tt)
{
library(mvtnorm)
#============================
Makeham<-function(tt)
{
a2=0.030386513
a3=0.006688287
b3=0.039047537
t<-tt-20
h.t<-a2+a3*exp(b3*t)
S.t<-exp(-a2*t+a3/b3*(1-exp(b3*t)))
2009 Jul 10
2
IF STATEMENTS
Hello,
I am working on using if statements. What is the error message telling
me here and how do I correct for it?
I have tried various combinations of quotes.
Thank you.
Sincerely,
Mary A. Marion
#Find critical values
crit<-function(n,alpha,type)
{
if (type==twoSided)
{
alpha2=alpha/2
tL<-qt(alpha2,n-1)
tU<-qt(1-alpha2,n-1)
}
if (type==Lower)
{
tL<- -9999
2009 Jul 01
2
Difficulty in calculating MLE through NLM
Hi R-friends,
Attached is the SAS XPORT file that I have imported into R using following code
library(foreign)
mydata<-read.xport("C:\\ctf.xpt")
print(mydata)
I am trying to maximize logL in order to find Maximum Likelihood Estimate (MLE) of 5 parameters (alpha1, beta1, alpha2, beta2, p) using NLM function in R as follows.
# Defining Log likelihood - In the function it is noted as
2012 Dec 19
1
confirming a formula for use with lmer
Hello,
I recently began using R and the lme4 package to carry out linear mixed
effects analyses.
I am interested in the effects of variables 'prime','time', and 'mood'
on 'reaction_time' while taking into account the random effect
'subjects.' I've read through documentation on lme4 and came up with the
following formula for use with lmer:
2008 Jan 04
2
R2WinBUGS sending variables as factors
Hello R and BUGS users,
I am writing a heirarchical model in R to send to BUGS via R2WinBUGS and
I am finding it difficult to get the model to run. I seem to be having
two problems.
1) I can't seem to send variables classed as factors (Month), is there a
way do this?
2) Checking the Log in WinBUGS I can see that the model is Syntactically
correct, but Bugs is not able to recognise the the
2011 Sep 16
2
v2.1.alpha2 released
http://dovecot.org/releases/2.1/alpha/dovecot-2.1.alpha2.tar.gz
http://dovecot.org/releases/2.1/alpha/dovecot-2.1.alpha2.tar.gz.sig
This is actually looking rather stable. I'm still calling it "alpha" in
case I think of doing some more API changes, but I think the next one
will be called "beta1", hopefully soon followed by "rc1".
- Statistics gathering
2011 Sep 16
2
v2.1.alpha2 released
http://dovecot.org/releases/2.1/alpha/dovecot-2.1.alpha2.tar.gz
http://dovecot.org/releases/2.1/alpha/dovecot-2.1.alpha2.tar.gz.sig
This is actually looking rather stable. I'm still calling it "alpha" in
case I think of doing some more API changes, but I think the next one
will be called "beta1", hopefully soon followed by "rc1".
- Statistics gathering
2005 Feb 27
2
Help with constrained optimization
Dear all,
I need an advice in the following problem.
I have to maximize two functions of the form f1(x)=f(y1,x,alpha1,beta1) and f2(x)=(y2,x,alpha2,beta2), the maximization is with respect to alpha1, alpha2, beta1, beta2. I can maximize each function separately using nlm.
The problem is that I have to add the constraint of the form g(alpha1)=g(alpha2).
The total number of parameters is
2005 Sep 14
2
SSL/TLS stopped working in 1.0 alpha2
I have both 1.0 alpha1 and alpha2 installed on my test mail server.
SSL/TLS does not work on alpha2. I'm using the same config file for
both. No errrors in dovecot.log either. Is there a way to increase
debugging info without recompiling?
2011 Aug 11
1
R crashes when communicating with JAGS
There is a thread on this topic already:
http://finzi.psych.upenn.edu/Rhelp10/2010-August/250934.html
I'm rather mystified by a similar problem and wondering whether I've
overlooked something obvious. I'm running with latest versions of R and
all packages, and latest version of JAGS running under Windows 7.
Here's the problem. I have some source code. It's given below -
2005 Jul 14
2
Variance components from lm?
I often use simple nested random-effect models for interlaboratory data.
The variance components are important things to know.
Is there an R function or package that gets variance components from lm
objects? Or can someone point me to a method of doing so?
2008 Oct 05
4
v1.2.alpha2 released
http://dovecot.org/releases/1.2/alpha/dovecot-1.2.alpha2.tar.gz
http://dovecot.org/releases/1.2/alpha/dovecot-1.2.alpha2.tar.gz.sig
Mainly the same fixes as in v1.1.3 -> v1.1.4 plus some more
v1.2-specific fixes.
Not many people have been testing v1.2 releases. Wonder if there's
something I could do to improve that. I guess v1.2 is kind of missing
those killer features that would get a