Skip to main content

All Questions

Tagged with
Filter by
Sorted by
Tagged with
0 votes
0 answers
19 views

How to plot hazard ratio from coxph model with tt() term [closed]

This question is related to another that I posted here: How to visually assess tt() suitability in coxph If we have a time-varying HR that arises from a time-dependent coefficient because we have ...
LucaS's user avatar
  • 857
0 votes
0 answers
32 views

How to visually assess tt() suitability in coxph? [closed]

For this example, I am taking cues from the time-dependent survival vignette. I am interested in understanding how to assess the suitability of a covariate-time interaction using ...
LucaS's user avatar
  • 857
0 votes
0 answers
46 views

Constructing nomogram from approximate model in Regression Modelling Strategies

In section 19.5 in Regression Modelling Strategies by Frank Harrell we make an approximate model using linear regression with ols. Since this is an ols object we have to calculate survival quantities ...
ScapeProf's user avatar
  • 101
1 vote
1 answer
1k views

violation of cox proportional hazard assumption

I'm using cox regression to analyse my data. The explanatory variable is a congenital disease (X) and the outcome is an another disease (Y), which is a comorbidity of the congenital disease. I'm ...
Devi Sita's user avatar
  • 333
1 vote
1 answer
519 views

Using multiple genes building gene signature and survival analysis

This is the paper which is kind of I'm trying to implement based on my set of genes which i have narrowed down from WGCNA analysis. Its a both conceptual and R related question[How to do it in R] my ...
PesKchan's user avatar
  • 235
1 vote
1 answer
144 views

Difference between family = gaussian() and family = cox.ph(link='identity') in GAM and family = binomial(link="logit")

I wonder how do u decide if family = gaussian() or family = cox.ph(link='identity') or ...
nerd's user avatar
  • 165
2 votes
1 answer
119 views

Is it possible to generate a scatterplot of relative hazard for participants superimposed on Cox regression line?

I have been using the rms package in R to perform Cox regression on time-to-event data. I have used the ...
Nicholas Black's user avatar
0 votes
1 answer
349 views

Cox time-varying coefficient memory allocation issue

I'm trying to add time-varying coefficients using the tt() function with coxph to solve the problem of PH violations in my Cox ...
JED HK's user avatar
  • 409
1 vote
1 answer
383 views

Hazard ratio from Royston-Parmar model (flexsurv::flexsurvspline)

I have a covariate with time-varying coefficient with two categories (lets call it T), which I have modeled using the Royston-Parmar model from flexsurv package as following. ...
lvdp's user avatar
  • 397
3 votes
2 answers
3k views

IPTW in Cox Regression model using the WeightIt package - Question on ATT vs. ATE interpretation

I am currently trying to perform some IPTW adjustment in the context of Cox Regression models. I was interested in expanding my understanding of the differences between ATE vs. ATT estimation. I've ...
user89547235's user avatar
1 vote
0 answers
49 views

IPTW and adjustment in Cox Regression Analysis [duplicate]

A question on how to deal with inverse probability of treatment weighted-Cox regression analysis. Basically, I am evaluating how to use IPTW in the context of survival (and specifically, Cox ...
user89547235's user avatar
1 vote
1 answer
552 views

In data setup for Cox regression, how to handle a subject's time before treatment of interest (i.e. before time-zero)?

Background I'm designing a study that models time-to-event for two groups of study subject: people who receive a treatment and those who do not. I'm fairly new to applied survival analysis, so I've ...
logjammin's user avatar
  • 739
0 votes
1 answer
1k views

Testing the difference between 2 Cox regression models

I am running an ANOVA test on R comparing the results of 2 cox regression models. Model 1 has variableA (binary). Model 2 has the interaction term for variableA * variableB (3 categories). I'm not ...
qwert's user avatar
  • 1
0 votes
1 answer
658 views

How do you interpret outputs of Cox regression based on data type of an independent categorical variable?

I have the following data frame which consists of a grouping variable, as well as time ans status variables for survival analysis: ...
Takanashi's user avatar
  • 199
0 votes
1 answer
150 views

What should I do if only 1 covariate violate the proportionality assumption in Cox PH?

Can I still use Cox PH model? or I will have to find a non-PH model? What are the available models that can be used here? Schoenfeld residuals (using ...
HNSKD's user avatar
  • 227
4 votes
1 answer
2k views

Cox PH model and regression with log-log link function: is there a connection?

In this post: interpreting estimates of cloglog logistic regression, I read that when interpreting the results of a regression with a log-log link function, the exponent of the estimated coefficient ...
Michael Smith's user avatar
1 vote
1 answer
1k views

Evaluating Functional Form in Cox Regression using rcs

I was approaching Cox regression and need to evaluate whether is more suitable to model my independent variable as a non-linear prediction of the outcome. Main questions is: How do I check whether or ...
user89547235's user avatar
2 votes
1 answer
2k views

Estimating survival curves from Cox regression results

I can understand that it is possible to estimate survival curves directly from the results of a Cox regression. The way it can be done, mathematically, is furthermore very nicely explained in this ...
kurv17's user avatar
  • 21
0 votes
3 answers
4k views

Cox regression with multiple factors [R]

I'm running a Cox regression with three different groups... ...
garcesj's user avatar
  • 105
0 votes
0 answers
20 views

In cox model, can the hemoglobin and homoglobin group be put in the same model?

fit.tdc <- coxph(Surv(t1,t2,status) ~ Hemoglobingroup + hemoglobin + sex + diabet + cluster(id), data) fit.tdc Can the hemoglobin and hemoglobin group be put ...
Cgdmm's user avatar
  • 11
1 vote
1 answer
143 views

Presentation of a 3x3 categorical interaction for Cox proportional hazards regression using RMS package

I wanted to verify my presentation of a 3x3 interaction of two categorical variables var1 (exposure of interest) and var2 (effect modifier of interest) using the rms...
apos13's user avatar
  • 11
0 votes
2 answers
1k views

Calculating the Hazard Ratio for a Cox-regression model stratified by a variable (R)

I have built a Cox-regression model for 6 month mortality. When I created the original Kaplan–Meier curve, grouped by my variable of interest (hospital-acquired infection, Present vs Absent) the ...
FrenchToast's user avatar
2 votes
1 answer
304 views

Cox proportional hazards with left-censored time-dependent covariates

I'm doing statistical analysis on a cancer study. My specific dataset contains id, various co-variates such as age, sex, metastatic burden, etc. and time to event data for overall survival I want to ...
Luke's user avatar
  • 55
3 votes
2 answers
186 views

Should I use Cox model?

In a study of crowdfunding, I am investigating the relationship between the reputation of a person seeking funding for a project (a continuous variable) and the proportion of funding target received (...
SanMelkote's user avatar
2 votes
1 answer
2k views

Cox PH - R 'rms' package - Concordance (Train, CV & Test)

Please could someone verify if my methodology for calculating these three versions of concordance are correct when using the rms package? I have really struggled to ...
Liam Morgan's user avatar
5 votes
0 answers
4k views

How to better understand when to use Weibull AFT versus Cox Model for Failure Data

I am struggling to understand when I should consider using a Cox regression model versus using a Weibull AFT model to predict the end of life of mechanical components. I have tried to apply the Cox ...
Py_Mel's user avatar
  • 95
1 vote
1 answer
771 views

Interaction not significant in Cox regression model?

I ran a cox model with an interaction between two categorical variables (sex and treatment group) included like: ...
llbia's user avatar
  • 381
1 vote
1 answer
1k views

Baseline hazard function is the hazard function obtained when all covariates are set to zero

I am trying to learn Cox proportional hazard model but I have hit a wall with the basehaz function. Lets suppose for example I have some data that I want to use ...
John.Doh's user avatar
2 votes
2 answers
5k views

How to choose the best combination of covariates in Cox multiple regression?

I am performing a multivariate Cox regression analysis, and would like to find what combination of those covariates best predict my outcome. Say I have a list of candidate genes whose expressions ...
Douglas's user avatar
  • 21
1 vote
1 answer
106 views

Cox Regression and Linkage Disequilibrium

I'm trying to figure out the best way to account for linkage disequilibrium in a cox regression, and would really appreciate your advice. I'm testing the effect of a particular allele on overall ...
krc3004's user avatar
  • 41
2 votes
2 answers
547 views

How can I visualize fitting survival data to a proportional hazards model with a continuous variable?

I have (censored) survival data that I am fitting with a proportional hazards model with a continuous covariate, X (for my purposes, X ranges from 0 to 1). After fitting the model, I get a ...
user3593717's user avatar
0 votes
1 answer
2k views

How to interpret Coxnet in R?

I am using Coxnet package for a dataset of 457 observations and 180 variables and also for another dataset of 457 observations and 25000 variables. ...
Jesvin Joy's user avatar
7 votes
1 answer
11k views

How to interpret concordance index in Cox models?

I'm new using the survival package in R. Consider an example provided with the package: ...
jroberayalas's user avatar
4 votes
1 answer
2k views

Cox survival data with time-varying continuous variable and time fixed covariate

I am interested in the paper entitled "Generating survival times to simulate Cox proportional hazards models with time-varying covariates " (Stat Med. 2012 Dec 20;31(29):3946-58.),and want to simulate ...
Z. Zhang's user avatar
  • 183
2 votes
1 answer
1k views

What if linearity doesn't hold in a cox model?

I have built a multivariable cox model with coxph(). However, I am unable to run ggcoxfunctional() on some of the variables because of missing data. ...
saifulsafuan's user avatar
3 votes
1 answer
691 views

Cox Proportional-Hazards Regression vs. Regression modeling of competing risk using Fine and Gray

30000 patients all have one diagnosis in common, 3000 of them have been exposed to a potential risk factor before the common diagnosis. 1500 patients develop a malignancy after the common diagnosis. ...
ATM's user avatar
  • 31
1 vote
1 answer
6k views

Why are SPSS and R producing different results for a cox regression on the same data, with the same model specification?

I've performed a cox regression in rstudio (version 1.0.136) using the coxph function in the package "OIsurv". I've also performed the same analysis on SPSS using the same dataset, but i keep on ...
GaryStats's user avatar
0 votes
1 answer
2k views

How to use survival model to predict when there are time dependent continuous covariates

In my practical projects, I usually track a group of people for a few months, then I run a model based on the first few months behavior. Hopefully I can predict both overall and individual level's ...
Jen G's user avatar
  • 21
5 votes
1 answer
7k views

Can a Cox Proportional-Hazards Model be built only with continuous predictors

The literature on Survival Analysis is mainly from the Medical science where tipically the researcher want to evaluate the effect of a treatment to that of another one. So far, all the example I read ...
Filippo's user avatar
  • 349
1 vote
1 answer
817 views

How to get Cox p-value for 20,000 genes?

If you run the following code, you will have a data frame real.dat which has 1063 samples for 20531 genes. There are 2 extra columns named ...
nafizh's user avatar
  • 101
7 votes
1 answer
5k views

Relative importance of variables in Cox regression

I've understood that relative importance of predictors is a tricky question. Suggested methods range from very complex models to very simple variable transformations. I've understood that the ...
Adam Robinsson's user avatar
1 vote
1 answer
391 views

Comparing regression models with different coding of the same linear predictor

How can I determine whether one coding of a linear predictor leads to a better fit of the corresponding regression model than the other? In the following example, the restricted cubic spline coding of ...
Gurkenhals's user avatar
7 votes
1 answer
1k views

Time varying coefficient in Cox model

I have a model for survival after an injury that is borderline passing the Schoenfeld test for the proportional hazards assumption (cox.zph() in R). However, ...
Misha's user avatar
  • 1,333
7 votes
1 answer
4k views

Interpretation of coefficients of glmnet - LASSO/Cox model?

I have done a LASSO / Cox model run for a large dataset of 10K observations which has 1200 Variables. ...
Sam's user avatar
  • 85
2 votes
1 answer
108 views

R adds unexpected variable to interaction model

Not sure if this is more of a programming question (in which case please move to stack overflow) or a statistical model question (in which case, please read on!) I'm exploring a data set and doing ...
bdeonovic's user avatar
  • 10.2k
7 votes
1 answer
6k views

Difference in chi-squared calculated by anova from cph and coxph

Is there a difference between chi-squared (from coxph -> anova) and Wald chi-squared (from ...
Gurkenhals's user avatar
8 votes
2 answers
2k views

Cumulative Hazard Function where "status" is dependent on "time"

This question is in relation to a dataset I've previously discussed here. I'm trying to determine whether a treatment affects not only the number of visits a patient has to the doctor, but also how ...
OFish's user avatar
  • 458
5 votes
1 answer
5k views

Using the calibrate function in rms package for Cox model: use 'hare' method or 'KM'?

I'm creating a calibration plot for my breast cancer prognostic Cox model, which doesn't include any fancy transformations, using the calibrate() function in the <...
JJM's user avatar
  • 927
2 votes
1 answer
1k views

Simulation Analysis of a Cox Survival Model with Change Point.

I wish to simulate survival data for the following probabilistic model which will be analyzed using a Cox model: An exposure $X$ is modeled as binary having $X \sim_{iid} \mbox{Bernoulli}(p)$ where $...
anxoestevez's user avatar
9 votes
3 answers
17k views

Computing c-index for an external validation of a Cox PH model with R

First off, I'll state that I'm aware many questions get asked about the c-index. I've searched this site and others, and I haven't found an answer for my situation. I can successfully use ...
JJM's user avatar
  • 927