Displaying 20 results from an estimated 22 matches for "time3".
Did you mean:
time
2007 Jan 19
4
Newbie question: Statistical functions (e.g., mean, sd) in a "transform" statement?
Greetings listeRs -
Given a data frame such as
times
time1 time2 time3 time4
1 70.408543 48.92378 7.399605 95.93050
2 17.231940 27.48530 82.962916 10.20619
3 20.279220 10.33575 66.209290 30.71846
4 NA 53.31993 12.398237 35.65782
5 9.295965 NA 48.929201 NA
6 63.966518 42.16304 1.777342 NA
one can use "transform"...
2007 Dec 16
4
improving a bar graph
...have seen much more sophisticated examples using lattice (e.g
each person has a separate panel/plot). I am open to alternative code
as to how I could present this data.
Time1 <- c(9.0,6.0,1.0,5.0,7.0,9.0,5.0,7.5,6.0,8.0,5.0,5.0,9.0,4.0,5.0,5.0)
Time2 <- c (10,5,3,3,3,6,7,8,5,8,7,7,9,8,5,3)
Time3 <- c (10,0,3,0,0,6,0,0,0,0,0,0,0,0,0,0)
df <- rbind (Time1, Time2, Time3)
dft <- (t(df))
dft
barplot(dft, beside = TRUE, main= "Risk score by assessment", xlab =
" Score", ylab = "frequency", col="blue")
Any assistance is much appreciated,
rega...
2010 May 20
1
Strange behaviour when using diff with POSIXt and POSIXlt objects
...ot;%Y %m %d %H %M")
> time2=strptime("2009 05 31 23 07 00",format="%Y %m %d %H %M")
>
> diff(c(time1,time2),units="mins")
Time difference of 10 mins
.. I get the correct response in minutes. But if I try the same thing with
different values, say..
> time3=strptime("2009 06 01 00 47 00",format="%Y %m %d %H %M")
> time4=strptime("2009 06 01 00 57 00",format="%Y %m %d %H %M")
>
> diff(c(time3,time4))
Time difference of NA secs
...which is not what I´m looking for. The difference should also be 10
minute...
2012 Nov 30
1
help on "stacking" matrices up
...ollowing code
Dose<-1000
Tinf <-0.5
INTERVAL <-8
TIME8 <-matrix(c((0*INTERVAL):(1*INTERVAL)))
TIME7 <-matrix(c((0*INTERVAL):(2*INTERVAL)))
TIME6 <-matrix(c((0*INTERVAL):(3*INTERVAL)))
TIME5 <-matrix(c((0*INTERVAL):(4*INTERVAL)))
TIME4 <-matrix(c((0*INTERVAL):(5*INTERVAL)))
TIME3 <-matrix(c((0*INTERVAL):(6*INTERVAL)))
TIME2 <-matrix(c((0*INTERVAL):(7*INTERVAL)))
TIME1 <-matrix(c((0*INTERVAL):(8*INTERVAL)))
CDURINF1 <-((Dose/Tinf)*(1/(0.088*76.9)))*(1-exp(-0.088*TIME1))
CAFTINF1 <-((Dose/Tinf)*(1/(0.088*76.9)))*(1-exp(-0.088*Tinf))*(exp(-0.088*(TIME1)))
CONC1...
2004 Jul 04
2
Random intercept model with time-dependent covariates, results different from SAS
Dear list-members
I am new to R and a statistics beginner. I really like the ease with which I can
extract and manipulate data in R, and would like to use it primarily. I've
been learning by checking analyses that have already been run in SAS.
In an experiment with Y being a response variable, and group a 2-level
between-subject factor, and time a 5-level within-subject factor. 2
2010 Jul 16
1
Nested if help
...px>px1){ #nested if stmt to see if subsequent times are higher than base,
thus replacing base with new max (I am seeking max in the time period in
this instance)
px2<-px #px2 would be the new higher maximum
time2<-time #time associated with px2
px3<-px+1 #price immediately following max
time3<-time+1 #time immed. follows max
out<-(cur_date,px2,time2,px3,time3) #output the high price/time and the
immediately following price/time
cat(out,"\n")}
This code however, does nothing. Any help would be apreciated. The manuals
seem to only take one so far.
Thanks,
George
[[a...
2012 Apr 15
2
xyplot type="l"
Probably a stupidly simple question, but I wouldn't know how to google it:
xyplot(neuro ~ time | UserID, data=data_sub)
creates a proper plot.
However, if I add
type = "l"
the lines do not go first through time1, then time2, then time3 etc but in
about 50% of all subjects the lines go through points seemingly random
(e.g. from 1 to 4 to 2 to 5 to 3).
The lines always start at time point 1, though.
Defining "time" as factor or ordered doesn't change this.
"neuro" is a numerical variable.
It's probably...
2005 Nov 15
1
Repeates Measures MANOVA for Time*Treatment Interactions
...a
slightly different mind-set behind their experiments than, say, an
ecologist, who is interested in the effects of time per se, and not
just the effects of a treatment. For example, here's my dataset, say,
looking at plant height in cm with and without fertilizer
Treatment, Time1, Time2, Time3, Time4, Time5
Fertilizer, 1, 4, 8, 10, 12
Control,1,2,3,4,5
Fertilizer,1,8,10,12,20
Control,1,3,5,6,6
Fertilizer,2,5,10,20,25
Control,1,2,4,4,4
Clearly there is a time*treatment interaction (just eyeballing the
dataset)
My question is, how does one set this up using the anova.mlm approach
so t...
2011 Aug 17
1
contrast package with interactions in gls model
...260.48540 16.48991 15.796653 0.0000
Tra0 -9.38703 23.74893 -0.395261 0.6935
LugarChixchulub -0.15377 19.60260 -0.007845 0.9938
Lugar Hobonil -173.21354 15.89736 -10.895741 0.0000
Time2 -14.74999 14.55909 -1.013112 0.3135
Time3 14.42177 15.64594 0.921758 0.3589
Time4 14.77803 16.72367 0.883659 0.3790
Tra0:Time2 17.93859 20.78257 0.863156 0.3901
Tra0:Time3 -48.77118 22.17628 -2.199250 0.0302
Tra0:Time4 -52.63611 23.20192 -2.268610 0...
2005 Aug 10
2
Treatment-response analysis along time
...hand with some of my data. I have a very
typical analysis in biology, however it is difficult for me to find the
right way to analyse. I had a group of animals, I gave them a treatment, and
I measure a variable along time -one??s per day- along 5 days,for
example(fake data):
Animals Time1 Time2 Time3 Time4
1 1 5 3 1
2 2 7 4 1
3 5 5 3 1
4 1 3 7 2
5 2 7 7 1
Please, notice that all the animals get the same treatment, and there are no...
2002 Aug 10
0
lme output
...up + time + group:time, random=~1|subject,
na.action=na.omit, data=mydata)
...for a dataset where there are two groups being followed over time. pre is
before the treatment, and there are 4 post-treatment times (unequally spaced).
The fitted coefficients are:
(Intercept) pre group2 time2 time3 time4 group2:time2 group2:time3
group2:time4
2.6442 0.5478 1.0183 0.6085 0.2326 0.5059 -1.9177 -0.3500
-2.2029
of which there are only significant p-values (<0.05) for (Intercept), pre,
group2:time2 and group2:time4.
anova(fit) gives:
numDF denDF F-value p-valu...
2012 Mar 28
3
Connect lines in a dot plot on a subject-by-subject basis
...he few lines drawn are not drawn on a subject-by-subject basis, (2) not all lines are drawn.
I hope someone can help me fix my code
Thanks,
John
# Create a matrix to hold our data.
mydata <- matrix(nrow=10,ncol=10)
dimnames(mydata) <- list(NULL,c("time1", "time2", "time3", "time4", "time5",
"clot1", "clot2", "clot3", "clot4", "clot5"))
# load data into the matrix.
# The first five columns represent time of measurement
# Columns 6-10 have the measured values....
2016 Dec 08
3
wish list: generalized apply
Dear All,
I regularly want to "apply" some function to an array in a way that the arguments to the user function depend on the index on which the apply is working. A simple example is:
A <- array( runif(160), dim=c(5,4,8) )
x <- matrix( runif(32), nrow=4, ncol=8 )
b <- runif(8)
f1 <- function( A, x, b ) { sum( A %*% x ) + b }
result <- rep(0.0,8)
for (i in 1:8) {
2011 May 01
1
Mean/SD of Each Position in Table
I have 100+ .csv files which have the basic format:
> test
X Substance1 Substance2 Substance3 Substance4 Substance5
1 Time1 10 0 0 0 0
2 Time2 9 5 0 0 0
3 Time3 8 10 1 0 0
4 Time4 7 20 2 1 0
5 Time5 6 25 3 2 1
6 Time6 5 30 4 2 2
7 Time7 4 25 5...
2007 May 13
2
Some questions on repeated measures (M)ANOVA & mixed models with lme4
...aron & Li, 2006), something along the lines of:
aov(outcome ~ group * time + baseline + Error(subj+subj:time))
(from: http://cran.r-project.org/doc/contrib/Baron-rpsych.pdf, p. 41)
C. "Repeated measures" MANOVA as follows (using data in wide format):
response <- cbind(time1,time2,time3,time4,time5,time6)
mlmfit <- lm(response ~ group)
mlmfit1 <- lm(response ~ 1)
mlmfit0 <- lm(response ~ 0)
# Test time*group effect
anova.mlm(mlmfit, mlmfit1, X=~1, test="Spherical")
# Test overall group effect
anova.mlm(mlmfit, mlmfit1, M=~1)
# Test overall time effect
anova.mlm(...
2008 Oct 29
2
call works with gee and yags, but not geepack
...an,corstr="exch",data=dat)
I obtain the following error:
Error in geese.fit(x, y, id, offset, soffset, w, waves, zsca, zcor, corp, :
nrow(zsca) and length(y) not match
Could someone tell me what I have done incorrectly. Thanks for your
time, Juliet.
Data Below:
id treat time1 time2 time3 time4 chem1 chem2 chem3 chem4 time score chem
1 1 20 18 15 15 1000 1100 1200 1300 0 20 1000
1 1 20 18 15 15 1000 1100 1200 1300 2 18 1100
1 1 20 18 15 15 1000 1100 1200 1300 3 15 1200
1 1 20 18 15 15 1000 1100 1200 1300 6 15 1300
2 1 22 24 18 22 1000 1000 1055 950 0 22 1000
2 1 22 24 18 22 1000 100...
2009 May 15
13
How to calculate java method timestamp?
Hi,
I need help in calculating Java method time-stamp in following fashion.
Consider following method example.
long method3(long stop) {
try {
Thread.sleep(1500);
} catch (Exception e) {
}
//////////////////// real CPU intensive operation ///////////////////////////
for (int i = 1; i < stop; i++) {
stop = stop * stop * i;
};
2007 Oct 29
3
Strange results with anova.glm()
Hi,
I have been struggling with this problem for some time now. Internet,
books haven't been able to help me.
## I have factorial design with counts (fruits) as response variable.
> str(stubb)
'data.frame': 334 obs. of 5 variables:
$ id : int 6 23 24 25 26 27 28 29 31 34 ...
$ infl.treat : Factor w/ 2 levels "0","1": 2 2 2 2 1 1 1 2 1 1 ...
$ def.treat :
2007 Dec 12
3
ntpd
I am running a server inside of VMWare, and the clock gains ~30 seconds
every 1000 seconds or 1.03X.
I need to keep the drift under the magic 1000 limit that ntpd kills its
self, but despite setting maxpoll really low I get:
Dec 11 23:58:14 host ntpd[4909]: kernel time discipline status change 41
Dec 11 23:59:17 host ntpd[4909]: kernel time discipline status change 1
Dec 11 23:59:17 host
2011 Nov 10
2
performance of adaptIntegrate vs. integrate
Dear list,
[cross-posting from Stack Overflow where this question has remained
unanswered for two weeks]
I'd like to perform a numerical integration in one dimension,
I = int_a^b f(x) dx
where the integrand f: x in IR -> f(x) in IR^p is vector-valued.
integrate() only allows scalar integrands, thus I would need to call
it many (p=200 typically) times, which sounds suboptimal. The