similar to: survival::predict.coxph

Displaying 20 results from an estimated 2000 matches similar to: "survival::predict.coxph"

2010 Jun 15
2
coxph and remaing events
Hi everyone, I'm running a cox ph model on a dataset with a number of variables. Each variable has a different number of missing data, so that coxph() drops the individuals who are missing data at one or more variables. Because of this dropping (totally fine btw) I want to know how many events I am left with in the model. Is there a way of extracting them from the coxph() fit? or in any other
2012 Jan 04
1
Extract concordance from coxph.object
Dear all, As I said in my previous email I have just upgraded to R 2.14.0 on Windows 7. I have just run the 'coxph' function and notice that a Concordance statistic is produced. Is there any way to extract this information from the output? E.g. can I call the concordance value independently of calling the output? Many thanks, Laura [[alternative HTML version deleted]]
2011 Oct 01
4
Is the output of survfit.coxph survival or baseline survival?
Dear all, I am confused with the output of survfit.coxph. Someone said that the survival given by summary(survfit.coxph) is the baseline survival S_0, but some said that is the survival S=S_0^exp{beta*x}. Which one is correct? By the way, if I use "newdata=" in the survfit, does that mean the survival is estimated by the value of covariates in the new data frame? Thank you very much!
2007 Nov 13
2
plotting coxph results using survfit() function
i want to make survival plots for a coxph object using survfit function. mod.phm is an object of coxph class which calculated results using columns X and Y from the DataFrame. Both X and Y are categorical. I want survival plots which shows a single line for each of the categories of X i.e. '4' and 'C'. I am getting the following error: > attach(DataFrame) >
2006 Dec 29
2
Survfit with a coxph object
I am fitting a coxph model on a large dataset (approx 100,000 patients), and then trying to estimate the survival curves for several new patients based on the coxph object using survfit. When I run coxph I get the coxph object back fairly quickly however when I try to run survfit it does not come back. I am wondering if their is a more efficient way to get predicted survival curves from a coxph
2012 Nov 27
4
Fitting and plotting a coxph with survfit, package(surv)
Hi Dear R-users I have a database with 18000 observations and 20 variables. I am running cox regression on five variables and trying to use survfit to plot the survival based on a specific variable without success. Lets say I have the following coxph: >library(survival) >fit <- coxph(Surv(futime, fustat) ~ age + rx, data = ovarian) >fit what I am trying to do is plot a survival
2005 Jul 14
2
Coxph with factors
Hello, I am fitting a coxph model with factors. I am running into problems when using 'survfit'. I am unsure how R is treating the factors when I fit, say: > DATA<-data.frame(time.sec,done,f.pom=factor(f.pom),po,vo) > final<-coxph(Surv(time.sec,done)~f.pom*vo+po,data=DATA) > final.surv<-survfit((final), individual=T,conf.type="log-log")
2010 Oct 27
2
coxph linear.predictors
I would like to be able to construct hazard rates (or unconditional death prob) for many subjects from a given survfit. This will involve adjusting the ( n.event/n.risk) with (coxph object )$linear.predictors I must be having another silly day as I cannot reproduce the linear predictor: fit <- coxph(Surv(futime, fustat) ~ age, data = ovarian) fit$linear.predictors[1] [1] 2.612756
2012 Jul 06
1
How to compute hazard function using coxph.object
My question is, how to compute hazard function(H(t)) after building the coxph model. I even aware of the terminology that differs from hazard function(H(t)) and the hazard rate(h(t)). Here onward I wish to calculate both. Here what I have done in two different methods; ##########################################################################################
2007 Dec 09
2
Getting estimates from survfit.coxph
Dear all, I'm having difficulty getting access to data generated by survfit and print.survfit when they are using with a Cox model (survfit.coxph). I would like to programmatically access the median survival time for each strata together with the 95% confidence interval. I can get it on screen, but can't get to it algorithmically. I found myself examining the source of print.survfit to
2005 Jun 29
1
sbrier (Brier score) and coxph
Hello I've decided to try and distill an earlier rather ill focused question to try and elicit a response. Any help is greatly appreciated. Why does mod.cox not work with sbrier whilst mod.km does? Can I make it work? > data(DLBCL) > DLBCL.surv<-Surv(DLBCL$time,DLBCL$cens) > > mod.km<-survfit(DLBCL.surv) > mod.cox<-survfit(coxph(DLBCL.surv~IPI, data=DLBCL)) >
2017 Jul 06
1
Generate simulated data respecting some conditions
Hello, Is it possible to generate simulated data that look like the attached figure? The curve in the figure can be obtained from this equation respecting some conditions: if(Temperature > T_min & Temperature < T_max){ a*( Temperature -T_min)*( Temperature -T_max) } else 0 T_min ~ Uniform(0, 24) T_max ~ Uniform(25, 45) -a ~ Gamma(1, 1) Temperature <- seq(0, 45, by = 1)
2012 Jan 24
1
Plotting coxph survival curves
Hi, I am attempting to plot survival curves estimated by cox proportional hazards regression model. The formula for the model is this: F.cox.weight <- coxph(Surv(Lifespan, Status) ~ MS + Weight + Laid + MS:Laid + Weight:Laid, data = LongF) MS = Mating status (mated/virgin) Weight = adult female weight, continuous covariate Laid = number of eggs laid by each female, continuous covariate I
2011 May 06
2
coxph and survfit issue - strata
Dear users, In a study with recurrent events: My objective is to get estimates of survival (obtained through a Cox model) by rank of recurrence and by treatment group. With the following code (corresponding to a model with a global effect of the treatment=rx), I get no error and manage to obtain what I want : data<-(bladder)
2012 Oct 13
4
Problems with coxph and survfit in a stratified model with interactions
I?m trying to set up proportional hazard model that is stratified with respect to covariate 1 and has an interaction between covariate 1 and another variable, covariate 2. Both variables are categorical. In the following, I try to illustrate the two problems that I?ve encountered, using the lung dataset. The first problem is the warning: To me, it seems that there are too many dummies
2005 Jun 22
2
predict.coxph fitted values for failure times
I would like to extract predicted failure times from a coxph model in library(survival). However, none of the prediction options ("lp", "risk", "expected", "terms") seem to bear any relationship to failure time. Perhaps I am asking the wrong question, but can coxph provide predicted failure times? Thanks, Dan Bebber Department of Plant Sciences University
2013 Dec 07
1
combine glmnet and coxph (and survfit) with strata()
Dear All, I want to generate survival curve with cox model but I want to estimate the coefficients using glmnet. However, I also want to include a strata() term in the model. Could anyone please tell me how to have this strata() effect in the model in glmnet? I tried converting a formula with strata() to a design matrix and feeding to glmnet, but glmnet just treats the strata() term with one
2011 Feb 03
3
coxph fails to survfit
I have a model with quant vars only and the error message does not make sense: (mod1 <- coxph(Surv(time=strt,time2=stp,event=(resp==1))~ +incpost+I(amt/1e5)+rate+strata(termfac), subset=dt<"2010-08-30", data=inc,method="efron")) Call: coxph(formula = Surv(time = strt, time2 = stp, event = (resp == 1)) ~ +incpost + I(amt/1e+05) + rate + strata(termfac),
2013 Jan 17
3
coxph with smooth survival
Hello users, I would like to obtain a survival curve from a Cox model that is smooth and does not have zero differences due to no events for those particular days. I have: > sum((diff(surv))==0) [1] 18 So you can see 18 days where the survival curve did not drop due to no events. Is there a way to ask survfit to fit a nice spline for the survival?? Note: I tried survreg and it did not
2010 Apr 01
1
predicted time length differs from survfit.coxph:
Hello All, Does anyone know why length(fit1$time) < length(fit2$n) in survfit.coxph output? Why is the predicted time length is not the same as the number of samples (n)? I tried: example(survfit.coxph). Thanks, parmee > fit2$n [1] 241 > fit2$time [1] 0 31 32 60 61 152 153 174 273 277 362 365 499 517 518 547 [17] 566 638 700 760 791