Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature: Cure models #1452

Open
yananlong opened this issue Feb 7, 2023 · 1 comment
Open

Feature: Cure models #1452

yananlong opened this issue Feb 7, 2023 · 1 comment

Comments

@yananlong
Copy link

Mixture cure models are used in survival analysis when not all subjects are expected to experience the event(s) under investigation. As reviewed in Amico and Van Keilegom (2018), there exist two broad classes of cure models: mixture cure models and promotion time/latent activation cure models. For the former, we assume that the overall (population) survival function is a mixture of event (uncured) and cured subjects: $ S(t|x,z) = [1-p(z)] + p(z) S_u(t|x), $ where the event survival function ($ S_u $) can be parametric (e.g. Weibull) or non-parametric (Cox PH).

An example of mixture cure models can be found here. I was only able to do log-normal and Weibull since log-logistic lccdf is not available in the stan math library, even though is more commonly used because the posterior has a closed form.

@spinkney
Copy link

spinkney commented Jun 18, 2023

Is there any reason you can't just write the log_logistic_lccdf function yourself? It is easily written in Stan as

  real log_logistic_lccdf(real x, real alpha, real beta) {
    if (alpha <= 0) {
      reject("alpha must be > 0!");
    }
    if (beta <= 0) {
      reject("beta must be > 0!");
    }
    if (x < 0) {
      reject("x >= 0!");
    }
    
    return -log1p(pow(x / alpha, beta));
  }

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants