4

There is no advantage to using the log-rank statistic and several disadvantages: Unlike the Cox model, log-rank does not generalize to a Bayesian framework the log-rank test only works for mutually exclusive categories and does not handle a continuous exposure variable log-rank does not allow for general covariate adjustment Since the log-rank test is a ...


2

Here is a purely algebraic and entirely rigorous demonstration. As a matter of notation, when $\mathcal A\subset\Omega,$ the indicator function of $\mathcal A$ is defined by $$\mathscr{I}_{\mathcal{A}}(\omega)=\left\{\begin{aligned}1 & \quad\omega\in \mathcal{A}\\0&\quad\text{otherwise.}\end{aligned}\right.$$ Indicator functions connect probabilities ...


2

There are quite a few reasons why proportionality does not hold. One of them is omission of an important variable and thus you get a wrong model that may appear as time-varying coefficients. Let's have a look at a simple situation when there are two covariates $x_1$ and $x_2$. The true model is $$\lambda(t) = \lambda_0(t)\exp(x_1\beta_1+x_2\beta_2).$$ You ...


2

The value of the CDF (y-axis) is the quantile, and you want quantile $0.10$ at $x=0.15$. $$F_X(x\vert\lambda) = 1-e^{-\lambda x}$$ $$0.10 = 1-e^{-0.15\lambda }$$ Solve for lambda. There is no reason to use R for this task, except maybe as a calculator when you need to evaluate a logarithm (but you might even prefer to use the exact value and let your ...


2

Survival analysis can't really work with negative time values, as its starts with 100% survival at time=0. So either you need to define time=0 in some better way or, more likely, you need to adopt a different approach. My decades-ago experience in accounts receivable suggests that the problem with a single simple Cox model as you have tried so far is that it ...


2

First, it's critical to use the date of entry of a patient into the study as time = 0 for that patient. All subsequent dates for that patient should be expressed as differences from that patient-specific time reference. It's not clear that you are doing this, as all of your survival times seem to be truncated at 1 year. If you have 9 years of data, I would ...


1

As @Dave already noted, you can solve your problem analytically without resorting to R. Although this is possible in this case beacuse of the very simple density function of the exponential distribution, it might nevertheless be interesting how to achive this in case of more complicated distrubutions. The important thing to know is that R has four functions ...


1

The semi-parametric nature of Cox models is both a strength and a weakness. The strength is that you don't need to specify a model for the overall shape of the survival curve. The baseline survival curve is estimated from the data themselves. The weakness is that unless you have access to the baseline survival curve upon which the model was built, you can't ...


1

As stated in my comments, I typically wouldn't recommend using OLS for this type of data. But given that you are insistent in your update on using OLS in and given that you want to use this method to seemingly compare your work with using OLS methods which, according to you is a standard approach in your field, then I'd recommend simply attempting A, B, and ...


1

I contacted the authors of the package who responded very quickly. The problem was that when generating the data, the default number of sampler steps in the numerical approximation procedure was not high enough for this scenario (default is 1000). I upped this to 10000, and the estimates of shape and scale were accurate. How to generate the data correctly: ##...


1

Actually, the probability for March given Feb is 0.943/0.962 or about 0.980 So Survival(March) = Survival(Jan) * S(F|J) * S(M|F) = 0.987 * 0.975 * 0.980 which comes out to the 0.943 provided


Only top voted, non community-wiki answers of a minimum length are eligible