Displaying 20 results from an estimated 400 matches similar to: "Function call error in cph/survest (package Design)"
2009 Feb 16
1
How do i compute predicted failure time from a cox model?
Given a cox model:
library(Hmisc); library(survival); (library(Design);
cox.model=cph(Surv(futime, fustat) ~ age, data=ovarian, surv=T)
str(cox.model)
What I need is the total estimated time until failure (death), not the
probability of failing at a given time (survival probability), or hazard
etc, which is what I get from survest and predict for example.
I suspect the answer is
2011 Mar 07
0
survest() for cph() in Design package
Hi, I am trying to run a conditional logistic model on a nested case-control
study using cph() and then estimate survival based on the model. The data came
from Prof Bryan Langholz website where he also has the SAS code to this, so I am
trying to replicate the SAS results.
The data attached. Basically, the variables are:
rstime: risk set age
rsentry: fake entry time, just before rstime
setno:
2009 Mar 26
2
R 2.8.1 and 2.9 alpha crash when running survest of Design package
Dear Prof Harrell and everyone,
My PC: Window XP service pack 3 and service pack 2
R version 2.8.1 and 2.9 alpha
For the last 3 days, after updating R, my two computers have been facing
problems when running existing and runable R commands that involves with
Design package
I attempt to use 'survest', but I failed all the times with R (both 2.8.1
and 2.9 alpha) being shut down
2007 Nov 21
0
survest and survfit.coxph returned different confidence intervals on estimation of survival probability at 5 year
I wonder if anyone know why survest (a function in Design package) and
standard survfit.coxph (survival) returned different confidence
intervals on survival probability estimation (say 5 year).
I am trying to estimate the 5-year survival probability on a continuous
predictor (e.g. Age in this case). Here is what I did based on an
example in "help cph". The 95% confidence intervals
2010 May 26
3
Problem with plotting survival predictions from cph model
Dear R-helpers,
I am working with 'cph' models from 'rms' library. When I build simple
survival models, based on 'Surv(time, event)', everything is fine and I
can make nice plots using plot(Predict(f, time=3)).
However, recently I tried to be more specific and used 'Surv(start,
stop, event)' type model. Using this model 'plot(Predict(f))' works OK,
but
2009 Feb 06
1
Using subset in validate() in Design, what is the correct syntax?
Hi
I am trying to understand how to get the validate() function in Design
to work with the subset option. I tried this:
ovarian.cph=cph(Surv(futime, fustat) ~ age+factor(ecog.ps)+strat(rx),
time.inc=1000, x=T, y=T, data=ovarian)
validate(ovarian.cph)
#fine when no subset is used, but the following two don't work:
> validate(ovarian.cph, subset=ovarian$ecog.ps==2)
Error in
2004 Nov 03
3
Estimating survival?
Hi,
Sorry to trouble the list. I have a problem which I'm not sure how to resolve.
I have a Cox model with 1 independent variable with 2 categories (and
thus 2 survival curves on plotting survfit)
How can I get an estimate of survival for each category at a
particular time point, with standard error?
Looking through ?cph and ?coxph, I'm not quite sure how to go about
that. I would
2010 Jan 29
1
help on drawing right colors within a grouped xyplot (Lattice)
Hi,
I've lost my mind on it... I have to scatterplot two vectors, grouped by a third variable, with two different dimensions according to whether each cell line in the plot is sensitive or resistant to a given drug, and with a different color for each of 9 tissues of origin.
Here's what I've done:
2010 May 23
3
"order" issue
Hi everybody, this is a real dummy thing.
I sorted a matrix based on a given column, and what I get is right, until it comes to columns of negative and positive values; than, "order" orders everything from max to min in the negative values, and then AGAIN from max to min in the positive values!!!
Why isn't everything order from max to min, and that's it?
Thank you!!!
Attached
2009 Oct 26
1
Unable to get Legend with survplot rms package
Hello,
I apologize for the post as I am certainly overlooking a simple
solution to my difficulties with getting a legend to print on a
survplot from the rms package.
I am plotting the following:
survplot(survest(fita), n.risk=T, conf='none', cex.n.risk=.85, dots=T,
col='gray10', lty=2)
survplot(survest(fit), n.risk=F, conf='none', add=T)
survplot(survest(fitb), n.risk=F,
2018 May 24
1
Predictions from a Cox model - understanding centering of binary/categorical variables
Dear all,
I am using R 3.4.3 on Windows 10. I am preparing some teaching materials and I'm having trouble matching the by-hand version with the R code.
I have fitted a Cox model - let's use the ovarian data as an example:
library(survival)
data(ovarian)
ova_mod <- coxph(Surv(futime,fustat)~age+rx,data=ovarian)
If I want to make predict survival for a new set of individuals at 100
2009 Mar 30
1
Possible bug in summary.survfit - 'scale' argument ignored?
Hi all,
Using:
R version 2.8.1 Patched (2009-03-07 r48068)
on OSX (10.5.6) with survival version:
Version: 2.35-3
Date: 2009-02-10
I get the following using the first example in ?summary.survfit:
> summary( survfit( Surv(futime, fustat)~1, data=ovarian))
Call: survfit(formula = Surv(futime, fustat) ~ 1, data = ovarian)
time n.risk n.event survival
2007 Jan 23
1
Estimate and plot hazard function using "muhaz" package
Dear R users,
I am trying to use "muhaz" and "plot.muhaz" functions in "muhaz" package to
estimate and plot hazard funciton. However function "muhaz" always gives
error message "Error in Surv(times, delta) : object "times" not found". I
could not even run their sample codes in the user's manual as follows:
data(ovarian)
2009 May 20
1
turning off specific types of warnings
Dear R users,
I have a long function that among other things uses the "survest" function from the Design package. This function generates the warning:
In survest.cph (...)
S.E. and confidence intervals are approximate except at predictor means.
Use cph(...,x=T,y=T) (and don't use linear.predictors=) for better estimates.
I would like to turn this specific warning off, as it
2006 Jun 15
0
survival probabilities with cph (counting process)
Hi,
I have fitted a cox model with time-varying covariates (counting process style)
using the cph function of the Design package. Now I want to know the survival probabilities at each time point given the history of a single individual.
I know the survest function, but I am not sure how to interpretet its output when using time-varying covariates. Does it just give the probabilities as if it
2009 Feb 18
1
Age as time-scale in a cox model-How to calculate x-time risk?
Dear R users,
My question is more methodology related rather than specific to R usage. Using time on study as time in a cox model, eg:
library(Design)
stanf.cph1=cph(Surv(time, status) ~ t5+id+age, data=stanford2, surv=T)
#In this case the 1000-day survival probability would be:
stanf.surv1=survest(stanf.cph1, times=1000)
#Age in this case is a covariate.
#I now want to compare the above
2009 Nov 13
2
survreg function in survival package
Hi,
Is it normal to get intercept in the list of covariates in the output of survreg function with standard error, z, p.value etc? Does it mean that intercept was fitted with the covariates? Does Value column represent coefficients or some thing else?
Regards,
-------------------------------------------------
tmp = survreg(Surv(futime, fustat) ~ ecog.ps + rx, ovarian,
2010 Oct 30
1
two group cox model
Dear all,
I am doing
library(survival)
fit <- coxph(Surv(futime,fustat) ~ rx, ovarian)
plot(survfit(fit,newdata=ovarian),col=c(1,2))
legend("bottomleft", legend=c("rx = 0", "rx = 1"),
lty=c(1,2),col=c(1,2))
Is this correct to compare these two groups? Is the 0.31 the p-value that
the median f two groups are equal
Why lty does not work here?
Many thanks
2005 Nov 27
1
the output of coxph
Dear All:
I have some questions about the output of coxph.
Below is the input and output:
----------------------------------------
> coxph(formula = Surv(futime, fustat) ~ age + rx + ecog.ps, data =
+ ovarian, x = TRUE)
Call:
coxph(formula = Surv(futime, fustat) ~ age + rx + ecog.ps, data =
ovarian, x = TRUE)
coef exp(coef) se(coef) z p
age 0.147 1.158
2003 Feb 27
2
interval-censored data in survreg()
I am trying to fit a lognormal distribution on interval-censored
data. Some of my intervals have a lower bound of zero.
Unfortunately, it seems like survreg() cannot deal with lower
bounds of zero, despite the fact that plnorm(0)==0 and
pnorm(-Inf)==0 are well defined. Below is a short example to
reproduce the problem.
Does anyone know why survreg() must behave that way?
Is there an alternate