survival-models

survival-models is a skill for Claude Code from choxos/BiostatAgent. It costs 30 tokens per session (1,362 once invoked), scanned A, original, MIT.

Statistical models for studying how long it takes for an event to happen when some observations end before the event occurs. They include several probability models and support censored data, where the exact event time is unknown.

In plain words
What is it for?
Use them to model time until events such as failure or recovery, include explanatory variables, and fit models in Stan or JAGS.
Why use it?
They let you use incomplete time-to-event records instead of discarding cases whose event has not happened by the end of the study.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Part of the bayesian-modeling plugin — 9 skills, 3 commands, 6 agents shipped together

Good fit Use them to model time until events such as failure or recovery, include explanatory variables, and fit models in Stan or JAGS.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/choxos/biostatagent/survival-models
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add choxos/BiostatAgent --skill survival-models
Clone the repo
git clone --depth 1 https://github.com/choxos/BiostatAgent

Made for: Claude Code.

Or install bayesian-modeling, the plugin that ships this one along with the rest of its 9 skills, 3 commands, 6 agents.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for survival-models

README.md
[![agentmods](https://agentmods.dev/badge/skills/choxos/biostatagent/survival-models/github.svg)](https://agentmods.dev/skills/choxos/biostatagent/survival-models)
Your own site
<a href="https://agentmods.dev/skills/choxos/biostatagent/survival-models"><img src="https://agentmods.dev/badge/skills/choxos/biostatagent/survival-models/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for survival-models

Your own site · 80×15
<a href="https://agentmods.dev/skills/choxos/biostatagent/survival-models"><img src="https://agentmods.dev/badge/skills/choxos/biostatagent/survival-models.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 30 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,362 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00030 $0.01362
Opus 5 $0.00015 $0.00681
Sonnet 5 $0.00006 $0.00272
Haiku 4.5 $0.00003 $0.00136

Measured 9d ago against content hash 3b82a187dbe2, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-08, from the pricing page.

Security

Grade A, and why

survival-models scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 9d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

plugins/bayesian-modeling/skills/survival-models/SKILL.md · 200 lines

How it starts

The opening of the file, as written. The whole thing — 200 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Survival Models

Data Structure

data {
  int<lower=0> N;
  vector<lower=0>[N] time;      // Observed/censored time
  array[N] int<lower=0,upper=1> event;  // 1=event, 0=censored
  matrix[N, K] X;               // Covariates
}

Exponential Model

Stan

parameters {
  real alpha;           // Log baseline hazard
  vector[K] beta;
}
model {
  alpha ~ normal(0, 2);
  beta ~ normal(0, 1);

  for (n in 1:N) {
    real lambda = exp(alpha + X[n] * beta);
    if (event[n] == 1)
      target += exponential_lpdf(time[n] | lambda);
    else
      target += exponential_lccdf(time[n] | lambda);  // Survival
  }
}

JAGS (with censoring)

model {
  for (i in 1:N) {
    is.censored[i] ~ dinterval(t[i], t.cen[i])
    t[i] ~ dexp(lambda[i])
    log(lambda[i]) <- alpha + inprod(X[i,], beta[])
  }
  alpha ~ dnorm(0, 0.25)
  for (k in 1:K) { beta[k] ~ dnorm(0, 1) }
}

Weibull Model

Stan (AFT Parameterization)

parameters {
  real alpha;                    // Intercept (log scale)
  vector[K] beta;
  real<lower=0> shape;           // Weibull shape
}
model {
  alpha ~ normal(0, 5);
  beta ~ normal(0, 2);
  shape ~ exponential(1);

  for (n in 1:N) {
    real mu = alpha + X[n] * beta;
    if (event[n] == 1)
      target += weibull_lpdf(time[n] | shape, exp(mu));
    else
      target += weibull_lccdf(time[n] | shape, exp(mu));
  }
}

JAGS

model {
  for (i in 1:N) {
    is.censored[i] ~ dinterval(t[i], t.cen[i])
    t[i] ~ dweib(shape, lambda[i])
    log(lambda[i]) <- alpha + inprod(X[i,], beta[])
  }
  shape ~ dgamma(1, 0.001)
  alpha ~ dnorm(0, 0.01)
  for (k in 1:K) { beta[k] ~ dnorm(0, 0.01) }
}

Log-Normal Model

Stan

parameters {
  real alpha;
  vector[K] beta;
  real<lower=0> sigma;
}
model {
  for (n in 1:N) {
    real mu = alpha + X[n] * beta;
    if (event[n] == 1)
      target += lognormal_lpdf(time[n] | mu, sigma);
    else
      target += lognormal_lccdf(time[n] | mu, sigma);
  }
}

Read the full file on GitHub · 200 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 9d ago First seen · 200 lines · 30 tokens per session scan A 3b82a187dbe2

Subscribe to this mod's changes

survival-models is a skill published in the GitHub repository choxos/BiostatAgent (11 stars, last pushed 3mo ago), licensed MIT. It adds 30 tokens to every session and 1,362 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

imaging-data-commons

Query and download public cancer imaging data from NCI Imaging Data Commons. Invoke for any question about IDC collections, cancer imaging datasets, DICOM data access, radiology (CT, MR, PET) or pathology AI training sets, metadata queries, visualization, or license checks — even when the user doesn't explicitly…

K-Dense-AI/scientific-agent-skills · 75 tokens

lab-hardware-cad

Design custom laboratory hardware as parametric build123d models and export fabrication-ready STEP, STL, and DXF files - microfluidic chips and molds, optomechanical mounts and breadboard adapters, cuvette and microplate holders, tube racks, animal-behavior rigs, and 3D-printed instrument fixtures. Use when a research…

K-Dense-AI/scientific-agent-skills · 106 tokens

pkpd-modeling

Pharmacokinetic and pharmacodynamic modelling and simulation - non-compartmental analysis, compartmental and population PK, PK/PD and exposure-response, TMDD, PBPK orientation, bioequivalence, allometric scaling and first-in-human dose, drug interaction prediction, and Bayesian therapeutic drug monitoring. Use when…

K-Dense-AI/scientific-agent-skills · 273 tokens

diffdock

DiffDock and DiffDock-L molecular docking. Use for protein-small-molecule pose prediction from PDB or sequence plus SMILES/SDF/MOL2, batch docking, virtual screening, and pose-confidence interpretation. Not for binding affinity prediction.

K-Dense-AI/scientific-agent-skills · 51 tokens

latex-posters

Create professional research posters in LaTeX using beamerposter, tikzposter, or baposter. Support for conference presentations, academic posters, and scientific communication. Includes layout design, color schemes, multi-column formats, figure integration, and poster-specific best practices for visual communication.

K-Dense-AI/scientific-agent-skills · 60 tokens

neuropixels-analysis

Analyze Neuropixels extracellular recordings end-to-end with SpikeInterface. Covers loading SpikeGLX/Open Ephys/NWB data, preprocessing, drift/motion correction, Kilosort4 (and CPU) spike sorting, quality metrics, and unit curation (threshold-based, model-based UnitRefine, and AI-assisted visual review). Use when…

K-Dense-AI/scientific-agent-skills · 98 tokens