Displaying 20 results from an estimated 100 matches similar to: "Coxph and ordered factors"
2010 May 26
2
Survival analysis extrapolation
Dear all,
I'm trying to fit a curve to some 1 year failure-time data, so that I can
extrapolate and predict failure rates up to 3 years. The data is in the
general form:
Treatment Time Status
Treatment A 28 0
Treatment B 28 0
Treatment B 28 0
Treatment A 28
2012 May 11
2
survival analysis simulation question
Hi,
I am trying to simulate a regression on survival data under a few
conditions:
1. Under different error distributions
2. Have the error term be dependent on the covariates
But I'm not sure how to specify either conditions. I am using the Design
package to perform the survival analysis using the survreg, bj, coxph
functions. Any help is greatly appreciated.
This is what I have so far:
2010 Sep 21
2
Survival curve mean adjusted for covariate: NEED TO DO IN NEXT 2 HOURS, PLEASE HELP
Hi
I am trying to determine the mean of a Weibull function that has been fit to
a data set, adjusted for a categorical covariate , gender (0=male,1=female).
Here is my code:
library(survival)
survdata<-read.csv("data.csv")
##Fit Weibull model to data
WeiModel<-survreg(Surv(survdata$Time,survdata$Status)~survdata$gender)
summary(WeiModel)
P<-pweibull(n,
2007 Apr 26
3
adding a column to a matrix
i would like to add a variable to an existing matrix by manipulating 2 previous variables eg for the data
m
treat strata censti survTime
[1,] 1 2 284.684074 690.4961005
[2,] 1 1 172.764515 32.3990335
[3,] 1 1 2393.195400 24.6145279
[4,] 2 1 30.364771 8.0272267
[5,] 1 1 523.182282 554.7659501
l
2006 Jan 16
0
Snow Rmpi Heterogeneous Cluster
Dear R-users,
I am trying to make Snow and Rmpi working on an heterogenous cluster of
linux computers. The master computer is built on a 64 bit architecture
whereas all nodes are built on a 32 bit architecture. LAM/MPI was
installed successfully on all machine. LAM boots correctly on the master
computer and it recognizes all nodes defined in the lamhosts file.
However, when starting R,
2007 May 07
4
creating a new column
hie l would like to create a 6th column "actual surv time" from the following data
the condition being
if censoringTime>survivaltime then actual survtime =survival time
else actual survtime =censoring time
the code l used to create the data is
s=2
while(s!=0){ n=20
m<-matrix(nrow=n,ncol=4)
2005 Nov 11
1
Snow parLapply
Dear R-user,
I am trying to use the function 'parLapply' from the 'snow' package
which is supposed to work the same wys as 'lapply' but for a
parallelized cluster of computers. The function I am trying to call in
parallel is 'dudi.pca' (from the 'ade4' package) which performs
principal component analyses. When I call this function on a list of
2020 Sep 29
5
2 KM curves on the same plot
Hello,
Can anyone suggest a simple way to generate a Kaplan-Meier plot with 2 survfit objects, just like this one:?
https://drive.google.com/file/d/1fEcpdIdE2xYtA6LBQN9ck3JkL6-goabX/view?usp=sharing
Suppose I have 2 survfit objects: fit1 is for the curve on the left (survtime has been truncated to the cutoff line: year 5), fit2 is for the curve on the right (minimum survival time is at the
2010 Nov 24
2
Is there an equivalent to predict(..., type="linear") of a Proportional hazard model for a Cox model instead?
Hi all,
Is there an equivalent to predict(...,type="linear") of a Proportional hazard
model for a Cox model instead?
For example, the Figure 13.12 in MASS (p384) is produced by:
(aids.ps <- survreg(Surv(survtime + 0.9, status) ~ state + T.categ +
pspline(age, df=6), data = Aidsp))
zz <- predict(aids.ps, data.frame(state = factor(rep("NSW", 83), levels =
2013 Apr 24
2
Trouble Computing Type III SS in a Cox Regression
I should hope that there is trouble, since "type III" is an undefined concept for a Cox
model. Since SAS Inc fostered the cult of type III they have recently added it as an
option for phreg, but I am not able to find any hints in the phreg documentation of what
exactly they are doing when you invoke it. If you can unearth this information, then I
will be happy to tell you whether
2004 Nov 02
3
time dependency of Cox regression
Hi,
How can I specify a Cox proportional hazards model
with a covariate which i believe its strength on
survival changes/diminishes with time? The value of
the covariate was only recorded once at the beginning
of the study for each individual (e.g. at the
diagnosis of the disease), so I do not have the time
course data of the covariate for any given individual.
For example, I want to state at the
2002 Dec 08
1
(no subject)
Dear listers
I am a very newbie with graphs in R. I have a pulmonary function prediction
equation in the form of PVC = 1.1 - 0.45*age in years + 0.011*height in cm.
How can I draw the corresponding nomogram?. I read the help for the
design.nomogram function but it is too difficult for me. Excuse my
ignorance. Any direct help will be appreciated.
Thanks in advance.
2008 Dec 09
2
R Graphics Device margins
Hello,
I am relatively new to R and am using it to run Classification and Regression Tree analysis. My only issue at this point is that numbers are always cut off on the lower nodes. I've tried changing the margins with
mai=c(0, 0.5, 0.5, 0) but this has not so far worked.
Any suggestions would be appreciated.
Best,
John Z. Metcalfe, M.D., M.P.H.
Division of Pulmonary and Critical
2013 Apr 24
1
Trouble Computing Type III SS in a Cox Regression using drop1 and Anova
Hello All,
Am having some trouble computing Type III SS in a Cox Regression using either drop1 or Anova from the car package. Am hoping that people will take a look to see if they can tell what's going on.
Here is my R code:
cox3grp <- subset(survData,
Treatment %in% c("DC", "DA", "DO"),
c("PTNO", "Treatment", "PFS_CENSORED",
2007 Apr 25
0
Use of Lexis function to convert survival data to counting format
I'm trying to convert a dataset from the time-independent analysis form
> head(addicts)
id clinic status survtime prison meth clinic01
1 1 1 1 428 0 50 1
2 2 1 1 275 1 55 1
3 3 1 1 262 0 55 1
into the "counting data format" necessary to perform extended Cox regression.
I got
2007 Mar 23
3
distribution graph
I am looking for a way to produce a "distribution graph" as in the example:
(http://cecsweb.dartmouth.edu/release1.1/datatools/dgraph.php?year=2003&geotype=STD_HRR&event=A01_DIS&eventtype=UTIL
Anybody who can help?
Christian von Plessen
Department of Pulmonary Medicine
Haukeland university hospital
Bergen
Norway
2003 Mar 12
1
simulating 'non-standard' survival data
Dear all,
I'm looking for someone that help me to write an R function to simulate
survival data under complex situations, namely time-varying hazard ratio,
marginal distribution of survival times and covariates. The algorithm is
described in the reference below and it should be not very difficult to
implement it. However I tried but without success....;-(
Below there the code that I used; it
2009 Sep 09
2
ggplot2: mixing colour and linetype in geom_line
Hi all,
I try to represent a multiple curve graphic where the x-axis is the
temperature and the different y-axes are the different X (X22,X43,X44...)
some X corresponds to the same molecule (22 and 44 are for CO2 for instance)
so I use the same colour for them.
I wanna mix the linetype with the colour to be able to visually see the
difference between X43 and X45
The best I have done up to now
2002 Jun 11
2
Installing R with g77 fortran compiler
Hello,
I am trying to compile sources of R-1.5.0 on a Mandrake 8.1 linux box.
For Fortran compiler needs, I downloaded and installed a g77 rpm. But
the configure step fails with following output. I would like to know if
any of you had similar problem and how you solved.
Thanks in advance.
Mohan
------------------- configure output ------
checking for g77... g77
checking whether we are using the
2012 Nov 08
2
Formatting digits in a table with mix of numbers and characters
Hello,
I am currently trying to find an easy way to take a table with a mix
of numbers and characters and format the numbers in the table to be
constrained to 4 significant digits.
Example:
#this is my table creation
> table <- matrix(c(12.34567, "--", 10, 12.34567, "--", "NA", "--", 123.45678, "--"), ncol = 3, byrow=TRUE)
>
> table