Displaying 20 results from an estimated 301 matches for "trt".
Did you mean:
tort
2006 Aug 24
1
how to constrast with factorial experiment
...40.10 2 Ctl 3
312.76 2 Ctl 4
804.05 2 Ctl 5
28.22 2 Ctl 6
68.51 2 Ctl 7
46.15 2 Ctl 8
123.14 2 Ctl 9
33.78 2 Ctl 10
121.28 2 Ctl 11
30.96 3 Ctl 1
36.10 3 Ctl 2
47.19 3 Ctl 3
345.80 3 Ctl 4
644.61 3 Ctl 5
27.73 3 Ctl 6
56.63 3 Ctl 7
42.63 3 Ctl 8
61.25 3 Ctl 9
59.43 3 Ctl 10
109.87 3 Ctl 11
143.50 1 Trt 1
82.76 1 Trt 2
125.03 1 Trt 3
493.76 1 Trt 4
868.48 1 Trt 5
45.09 1 Trt 6
249.43 1 Trt 7
167.28 1 Trt 8
274.72 1 Trt 9
176.40 1 Trt 10
393.10 1 Trt 11
93.75 2 Trt 1
63.83 2 Trt 2
117.50 2 Trt 3
362.68 2 Trt 4
659.40 2 Trt 5
62.10 2 Trt 6
218.24 2 Trt 7
210.98 2 Trt 8
291.48 2 Trt 9
209.36 2 Trt 10...
2008 Oct 15
2
Network meta-analysis, varConstPower in nlme
...mparisons" (Statist Med, 2002) with great interest. I found it very
helpful that you included the R code to replicate your analysis;
however, I have had a problem replicating your example and wondered if
you are able to give me a hint. When I use the code from the article:
lme1 <- lme(Y1 ~ trt.B + trt.C + trt.D + trt.E, random = ~ 1 | trtpair,
data=lumley1, var = varConstPower(form=~sigma, fixed=list(power=1)))
I get an error message:
Error in lme(Y1 ~ trt.B + trt.C + trt.D + trt.E, random = ~1 | trtpair, :
unused argument(s) (var = list(const = numeric(0), power = numeric(0)))
Th...
2007 Mar 14
1
How to transform matrices to ANOVA input datasets?
...experts,
I have a list called dataHP which has 30 elements (m1, m2, ..., m30).
Each element is a 7x6 matrix holding yield data from two factors
experimental design, with treatment in column, position in row. For
instance, the element 20 is:
dataHP[[20]]
col1 col2 col3 trt1 trt2 trt3
[1,] 22.0 20.3 29.7 63.3 78.5 76.4
[2,] 102.4 92.3 72.2 199.2 201.1 218.9
[3,] 18.8 20.8 22.9 106.2 148.4 147.6
[4,] 14.5 17.2 15.6 120.1 115.8 124.6
[5,] 31.9 28.3 22.8...
2011 May 03
3
ANOVA 1 too few degrees of freedom
...evels(as.factor(Combined.Plot))
[1] "60m" "A1" "B1" "B3" "B4" "C5" "C9" "D2" "D9" "F60m"
"F8" "Q7"
> nlevels(as.factor(Combined.Plot))
[1] 12
> Anova.Trt.D.M.T.Pr.Model <- aov(Combined.Rs~Combined.Trt +
> as.factor(Combined.Plot) + as.factor(Combined.Day) +
> Combined.Trt*as.factor(Combined.Day) +
> Combined.Plot*as.factor(Combined.Day))
Warning message:
In model.matrix.default(mt, mf, contrasts) :
variable 'Combined.Plot' con...
2006 Aug 29
0
how to contrast with factorial experiment
Hello, R experts,
If I understand Ted's anwser correctly, then I can not contrast the
mean yields between sections 1-8 and 9-11 under "Trt" but I can
contrast mean yields for sections 1-3 and 6-11 because there exists
significant interaction between two factors (Trt:section4,
Trt:section5). Could I use the commands below to test
the difference between sections 1-3 and 6-11 ?
> contrasts(section)<-c(-2,-2,-2,0,0,1,1,1...
2011 Mar 07
5
Parsing question, partly comma separated partly underscore separated string
...Sunday trying to figure this out and thought I would try the list to see if someone here would be able to get me started.
My data structure looks like this,
(in a example.txt file)
Subject ID,ExperimentName,2010-04-23,32:34:23,Version 0.4, 640 by 960 ?pixels, On Device M, M, 3.2.4,ZZ_373_462_488_TRT at 9z.svg,592,820,3.35,ZZ_032_288_436_CON at 9z.svg,332,878,3.66,ZZ_384_204_433_TRT at 9z.svg,334,824,3.28,ZZ_365_575_683_TRT at 9z.svg,598,878,3.50,ZZ_005_480_239_CON at 9z.svg,630,856,8.03,ZZ_030_423_394_CON at 9z.svg,98,846,4.09,ZZ_033_596_398_CON at 9z.svg,636,902,3.28,ZZ_263_064_320_TRT at 9z....
2010 Dec 01
2
Lattice dotplots
Dear,
I have a dataset with 4 subjects (see ID in example), and 4 treatment (see
TRT in example) which are tested on 2 locations and in 3 blocs. By using
Lattice dotplot, I made a graph that shows the raw data per location and
per bloc. In that graph, I would like to have a reference line per bloc
that refers to the first treatment (T1). However, I can not find how to do
that....
2012 Jan 27
1
Confused with Student's sleep data description
...nfused whether Student's sleep data "show the effect of two
soporific drugs" or Control against Treatment (one drug). The reason
is the next:
> require(stats)
> data(sleep)
> attach(sleep)
> extra[group==1]
numeric(0)
> group
[1] Ctl Ctl Ctl Ctl Ctl Ctl Ctl Ctl Ctl Ctl Trt Trt Trt Trt Trt Trt Trt Trt Trt
[20] Trt
Levels: Ctl Trt
> sleep$group
[1] 1 1 1 1 1 1 1 1 1 1 2 2 2 2 2 2 2 2 2 2
Levels: 1 2
Does some package overwrite my attach()? I am worried mostly in the
right performance of my code by others. So have the attach() to be
avoided?
Thanks for answers!
2008 Jun 04
1
"& not meaningful for factors"
...are the AJCC TNM stages of cancer, and another variable diameter with factor levels ("=< 4", "4 - 6.5, > 6.5; limit values are exclusive).
I am trying to define series of groupings based on these variables and others like them.
My first attempts were;
1. node1 <- data.trt[data.trt$stage=="1B" & data.trt$diameter=="=< 4"]
2. data.trt$stage[data.trt$stage=="1B"]& data.trt$diameter[data.trt$diameter=="=< 4"]
The second attempt was purely a fishing exercise.
R gave me the waring message:
Warning message:
In Ops...
2011 Apr 20
2
survexp with weights
...enerate a weighted model, with the addition
of a "weights=albumin" argument (I only chose albumin because it had
no missing values, not because of any real relevance). Below are my
code with the resulting error messages. Thanks in advance!
> pfit <- coxph(Surv(time,status>0) ~ trt + log(bili) + log(protime) + age +
+ + platelet, data=pbc
+ )
>
> pfit
Call:
coxph(formula = Surv(time, status > 0) ~ trt + log(bili) +
log(protime) +
age + +platelet, data = pbc)
coef exp(coef) se(coef) z p
trt -0.000624 0.999 0.1...
2006 Mar 03
1
Help with lme and correlated residuals
Dear R - Users
I have some problems fitting a linear mixed effects model using the lme function (nlme library). A sample data is as shown at the bottom of this mail. I fit my linear mixed model
using the following R code:
bmr <-lme (outcome~ -1 + as.factor(endpoint)+ as.factor(endpoint):trt, data=datt,
random=~-1 + as.factor(endpoint) + as.factor(endpoint):trt|as.factor(Trial),
correlation = corSymm(form=~subject|as.factor(endpoint)),
weights=varIdent (form=~subject|endpoint))
With this code, i want to obtain random effects for each Trial. ALso my residuals...
2008 Mar 05
1
Question on "assign(paste.."
Hello,
I'm having trouble in using "assign(paste ..." command . I could create
several dataframes following trinomial distribution using it but it could
not be used to check their row means of the created dataframe.
For example, the following works:
probTrt=matrix(0,4,3);
probTrt;
#malf, death, normal
probTrt[1,]=c(0.064,0.119,0.817);#for Trt 1
probTrt[2,]=c(0.053,0.125,0.823);#for Trt 2
probTrt[3,]=c(0.111,0.139,0.750);#for Trt 3
probTrt[4,]=c(0.351,0.364,0.285);#for Trt 4
for (t in 4){
assign(paste("Trt",t,sep=""),rmultin...
2011 Dec 11
2
multiple comparison of interaction of ANCOVA
Hi there,
The following data is obtained from a long-term experiments.
> mydata <- read.table(textConnection("
+ y year Trt
+ 9.37 1993 A
+ 8.21 1995 A
+ 8.11 1999 A
+ 7.22 2007 A
+ 7.81 2010 A
+ 10.85 1993 B
+ 12.83 1995 B
+ 13.21 1999 B
+ 13.70 2007 B
+ 15.15 2010 B
+ 5.69 1993 C
+ 5.76 1995 C
+ 6.39 1999 C
+ 5.73 2007 C
+ 5.55 2010 C...
2012 Mar 14
0
statistical contrasts on 3-way interaction
...term
in a linear model to do some comparisons. I am little uncertain on how to construct contrasts on a 3-way interaction containing a continuous variable, and hope someone can confirm what I did is correct or wrong:
The linear model has a continuous dependent
variable “y”, with treatment factor “Trt” with value 0 and 1, a factor variable
“A” with value 0 and 1, a continuous variable “x”.
A simpler model is:
set.seed(10)
dat <- cbind(y=c(rnorm(10,3),rnorm(10,4),rnorm(10,3.1),rnorm(10,6)),
x=runif(40,5,15), expand.grid(A=rep(factor(0:1),each=10),Trt=factor(0:1)))
fit <- lm(y
~ x + T...
2005 Feb 22
1
Re: R-help Digest, Vol 24, Issue 22
...ob Wheeler'" <bwheeler at echip.com>
> Cc: r-help at stat.math.ethz.ch
> Subject: RE: [R] power.anova.test for interaction effects
> Reply-To: akniss at uwyo.edu
>
>
> It's a rather complex model. A 37*4 factorial (37 cultivars[var]; 4
> herbicide treatments[trt]) with three replications[rep] was carried
> out at
> two locations[loc], with different randomizations within each rep at
> each
> location.
>
> Source DF Error Term MS
> Loc 1 Trt*rep(loc) 12314
> Rep(loc) 4 Trt*rep(loc)...
2012 May 29
2
use xyplot to plot mean and CI by groups
...dividual points, CI and
the lines connect group means from different time points;
2. Add jitters to x axis to allow CIs not be overlapped
Could anyone modify the attached code to achieve this?
Thanks
library(lattice)
set.seed(123)
src <- data.frame(time = rep(c(1, 6, 24), rep(6,3)), trt =
rep(rep(c('C','T'), each=3), 3))
src <- transform(src, x=sqrt(time)+2*(trt=='C')+rnorm(18), trt =
ordered(trt, levels=c('C','T')))
src <- src[-5,]
src$m <- ave(src$x, src[c('time','trt')], FUN = mean)
src$sd <- ave(src$x, src[c(&...
2005 Dec 09
1
lmer for 3-way random anova
I have been using lme from nlme to do a 3-way anova with all the effects treated as random. I was wondering if someone could direct me to an example of how to do this using lmer from lme4.
I have 3 main effects, tim, trt, ctr, and all the interaction effects tim*trt*ctr. The response variable is ge.
Here is my lme code:
dat <- data.frame(ge=ge,trt=factor(trt),tim=factor(tim),ctr=factor(ctr))
dat$grp = as.factor(rep(1, nrow(dat)))
# dim(dat) = 216x5
w <- lme(ge ~ 1,data=dat,
random = list(...
2009 Jun 27
4
questions about meta-analysis
Dear R users:
In the example of meta-analysis (cochrane, package rmeta), I can not found the p-value of Test for overall effect, and some other indices (Z, I, weight and et al). How can I get the these indices listed?
> library(rmeta)
> data(cochrane)
> cochrane
name ev.trt n.trt ev.ctrl n.ctrl
1 Auckland 36 532 60 538
2 Block 1 69 5 61
3 Doran 4 81 11 63
4 Gamsu 14 131 20 137
5 Morrison 3 67 7 59
6 Papageorgiou 1 71 7 75
7 Tauesch...
2013 Sep 13
1
Creating dummy vars with contrasts - why does the returned identity matrix contain all levels (and not n-1 levels) ?
...regression I am generating (I use glmnet for variable selection and
then generate a Cox regression) - That is, if I get an HR of 3 for the
variable 300mg what does it mean ? the hazard is 3 times higher of what ?
Here is some code to reproduce the issue:
# Create a 4 level example factor
trt <- factor( sample( c("PLACEBO", "300 MG", "600 MG", "1200 MG"),
100, replace=TRUE ) )
# Use contrasts to get the identity matrix of dummy variables to be used in
glmnet
trt2 <- contrasts (trt,contrasts=FALSE)
Results...
2007 Jun 01
2
Interaction term in lmer
Dear R users,
I'm pretty new on using lmer package. My response is binary and I have fixed
treatment effect (2 treatments) and random center effect (7 centers). I want
to test the effect of treatment by fitting 2 models:
Model 1: center effect (random) only
Model 2: trt (fixed) + center (random) + trt*center interaction.
Then, I want to compare these 2 models with Likelihood Ratio Test. Here are
my lmer codes that I don't feel comfortable about their correctness.
model1 <- try(lmer(cbind( yvect, nvect-yvect) ~ 1 + (1 | center),
family = binomial, niter...