Survival Tools¶
Configuration File: survival_tools.json
Tool Type: Local
Tools Count: 3
This page contains all tools defined in the survival_tools.json configuration file.
Available Tools¶
Survival_cox_regression (Type: SurvivalTool)¶
Fit Cox proportional hazards regression model to assess effect of covariates on survival. Returns…
Survival_cox_regression tool specification
Tool Information:
Name:
Survival_cox_regressionType:
SurvivalToolDescription: Fit Cox proportional hazards regression model to assess effect of covariates on survival. Returns hazard ratios with 95% CI, p-values, and significance for each covariate. HR > 1 = increased hazard (worse survival); HR < 1 = decreased hazard (better survival). Use for: multivariate survival analysis, identifying prognostic biomarkers, adjusting for confounders.
Parameters:
operation(string) (required) Operation typedurations(array) (required) Observed time durationsevent_observed(array) (required) Event indicators (1=event, 0=censored)covariates(object) (required) Dict mapping covariate name to array of values. E.g., {‘age’: [45, 62, …], ‘stage’: [1, 2, …]}
Example Usage:
query = {
"name": "Survival_cox_regression",
"arguments": {
"operation": "example_value",
"durations": ["item1", "item2"],
"event_observed": ["item1", "item2"],
"covariates": "example_value"
}
}
result = tu.run(query)
Survival_kaplan_meier (Type: SurvivalTool)¶
Compute Kaplan-Meier survival estimates from time-to-event data. Returns survival probability at …
Survival_kaplan_meier tool specification
Tool Information:
Name:
Survival_kaplan_meierType:
SurvivalToolDescription: Compute Kaplan-Meier survival estimates from time-to-event data. Returns survival probability at each event time, number at risk, events, censored observations, and median survival time. Supports optional stratification by group for visual comparison. Use for: analyzing patient survival in clinical data, time-to-event analysis, comparing treatment groups.
Parameters:
operation(string) (required) Operation typedurations(array) (required) Observed time durations (e.g., months to event or censoring). All values must be >= 0.event_observed(array) (required) Event indicator: 1 = event occurred (death/relapse), 0 = censored. Same length as durations.group_labels([‘array’, ‘null’]) (optional) Optional group labels for stratified KM analysis (e.g., [‘high’, ‘low’, ‘high’, …])
Example Usage:
query = {
"name": "Survival_kaplan_meier",
"arguments": {
"operation": "example_value",
"durations": ["item1", "item2"],
"event_observed": ["item1", "item2"]
}
}
result = tu.run(query)
Survival_log_rank_test (Type: SurvivalTool)¶
Perform Mantel-Cox log-rank test to compare survival between two groups. Tests null hypothesis th…
Survival_log_rank_test tool specification
Tool Information:
Name:
Survival_log_rank_testType:
SurvivalToolDescription: Perform Mantel-Cox log-rank test to compare survival between two groups. Tests null hypothesis that survival curves are identical. Returns chi-squared statistic, p-value, observed vs expected events per group. A p-value < 0.05 indicates statistically significant difference in survival. Use for: comparing treatment arms, high vs low expression groups.
Parameters:
operation(string) (required) Operation typedurations_a(array) (required) Time durations for group Aevents_a(array) (required) Event indicators for group A (1=event, 0=censored)durations_b(array) (required) Time durations for group Bevents_b(array) (required) Event indicators for group B (1=event, 0=censored)
Example Usage:
query = {
"name": "Survival_log_rank_test",
"arguments": {
"operation": "example_value",
"durations_a": ["item1", "item2"],
"events_a": ["item1", "item2"],
"durations_b": ["item1", "item2"],
"events_b": ["item1", "item2"]
}
}
result = tu.run(query)