search for: subj1

Displaying 9 results from an estimated 9 matches for "subj1".

Did you mean: subj
2013 Jun 07
1
Function nlme::lme in Ubuntu (but not Win or OS X): "Non-positive definite approximate variance-covariance"
...im)), data=mydat1) When I check the approximate variance-covariance matrix, I get: > fm0$apVar [1] "Non-positive definite approximate variance-covariance" *However*, if I do the same on a Windows or a Mac OS X machine, I get: > fm0$apVar reStruct.subj1 reStruct.subj2 reStruct.subj3 reStruct.subj1 reStruct.subj1 1.952757e-01 3.130089e-01 5.766955e-01 -0.1034862377 reStruct.subj2 3.130089e-01 5.703211e-01 9.864047e-01 -0.1937902915 reStruct.subj3 5.766955e-01 9.864047e-01 1.861434e+00 -0.3303689957 reStruct.subj1 -1.034862e-01...
2007 May 17
2
How to select specific rows from a data frame based on values
...iables have values that range between -4 to +4, and I want to subset this data frame so that in the resulting new dataframe, values of _all_ of these variables should range between -3 and +3. Let's say I have the following dataframe (it's a toy example with 4 individuals and 5 variables): subj1 <- cbind(-4, -3, -1, -5, -7) subj2 <- cbind(-2, -1, -1, -2, +2) subj3 <- cbind(+2, +1, +2, +1, +2) subj4 <- cbind(-4, -1, -2, +2, +1, +1) mydf <- as.data.frame(rbind(subj1, subj2, subj3, subj4)) >From mydf, I want to generate a new dataframe (let's call it mydf1) which will...
2011 Dec 23
1
Long jobs completing without output
...Regards, Brendan Halpin - code --------------------------------------------------------------- library(arm) library(foreign) mlm <- read.dta("../workingdata.dta") attach(mlm) gender <- as.factor(stu_gend) yr <- year - 1998 failure <- (lmer(fail ~ 1 + cao + subj1 + subj2 + subj3 + gender + yr + ageentry + as.factor(yrs5) + modsize + meancao + depfemr + (1|deptno) + (1|modinst) + (1|ulid) , na.action = na.exclude, family = binomial (link="logit"))) display(failure, digits=5, detail=TRUE) ---------------------------...
2004 Jan 15
1
nlme vs aov with Error() for an ANCOVA
...ndependent variables I have: -age.group (binaray:young(0)/old(1)) -and task-difficulty measured by means of the reaction-time 'rt'. For 'rt' I have repeated measurements, since each subject did 12 different tasks. -> so it can be seen as an ANCOVA subject age.group bold rt subj1 0 0.08 0.234 subj1 0 0.05 0.124 .. subj1 0 0.07 0.743 subj2 0 0.06 0.234 subj2 0 0.02 0.183 .. subj2 0 0.05 0.532 subjn 1 0.09 0.234 subjn 1 0.06 0.155 ....
2011 Nov 24
0
length of 'dimnames' [2] not equal to array extent
...;m trying to use the user-created multinomRob to make some models for my data. While documentation for that function is fine and I think I'm using it correctly, I'm getting the following error when I try to use my lists of variables. data <- read.csv("data.csv", header=FALSE) subj1 <- data.frame(radius=data$V3[9:11], x1=data$V4[9:11], x2=data$V5[9:11], x3=data$V6[9:11]) > subj1 radius x1 x2 x3 1 436.61 1.00000 0.000000 0.000000 2 735.27 1.00000 0.000000 0.000000 3 901.73 0.96081 0.053223 -0.055439 co1 <- multinomRob(model=list(radius ~ x1 + x2 +...
2007 Apr 13
2
replicates in repeated ANOVA
...2)), + prepost = factor(rep(c(rep("pre",3),rep("post",3)),6)), + subj = factor(rep(paste("subj",1:6,sep=""),c(6,6,6,6,6,6))), + Group = factor(c(rep("Treat",18),rep("Control",18)))) > rt.df rt rep prepost subj Group 1 287 rep1 pre subj1 Treat 2 283 rep2 pre subj1 Treat 3 261 rep3 pre subj1 Treat 4 298 rep1 post subj1 Treat 5 302 rep2 post subj1 Treat 6 280 rep3 post subj1 Treat 7 211 rep1 pre subj2 Treat 8 272 rep2 pre subj2 Treat 9 222 rep3 pre subj2 Treat 10 285 rep1 post subj2 Treat 11 253 rep2 post subj2 Treat 12 25...
2006 Oct 08
1
Simulate p-value in lme4
...il2$subject) epil3 <- aggregate(epil2, list(epil2$subject, epil2$period > 0), function(x) if(is.numeric(x)) sum(x) else x[1]) ************simulation (SG)************ o <- with(epil3, order(subject, y)) epil3. <- epil3[o,] norep <- with(epil3., subject[-1]!=subject[-dim(epil3)[1]]) subj1 <- which(c(T, norep)) subj.pred <- epil3.[subj1, c("subject", "pred")] subj. <- as.character(subj.pred$subject) pred. <- subj.pred$pred names(pred.) <- subj. iter <- 10 chisq.sim <- rep(NA, iter) set.seed(1) for(i in 1:iter){ s.i <- sample(subj.) # R...
2011 Nov 18
1
[R-sig-ME] account for temporal correlation
...ion of temp*trt >>> and to do so I'm using the following model: >>> >> library(nlme) >> model <- lme(var~temp*trt,random=~1|subj,mydata) >>> >>> however, since i have repeated measurement of the same subject, >>> i.e. I measured var in subj1 at time1,2,3.. >>> I must consider the non independence of the residuals. >>> moreover, temp is also a function of time, but i'm not sure how >>> to include this in my model. >>> >>> I'm following the approach in Zuur et al 2009, so I checked for...
2006 Aug 17
1
Simulate p-value in lme4
Dear list, This is more of a stats question than an R question per se. First, I realize there has been a lot of discussion about the problems with estimating P-values from F-ratios for mixed-effects models in lme4. Using mcmcsamp() seems like a great alternative for evaluating the significance of individual coefficients, but not for groups of coefficients as might occur in an experimental design