Custom fitting with apply_fit()1 days ago
Overview | Data setup | The fit_fn contract | Minimal example | Single-agent: apply_fit() | Writing to the Metrics assay | Idempotent merge | Coexisting fit sources | Reference Hill fit: fit_drug_response_metrics() | Numerical equivalence with fit_SE() | summary_fn: cell-level aggregation | Combination data: synergy scores | What fit_SE.combinations() does internally | Running all steps individually | Skipping a step | Two approaches for combination scoring in the new API | Approach 1: apply_combo_scores() — replicate fit_SE.combinations exactly | Approach 2: bliss_fit_fn / hss_fit_fn — simplified, no SA fits needed | Efficient multi-fit: apply_fits() | Shared pre-computation pattern | Chaining with pipe | Error handling | Time-course data: fit_SE.timecourse() | Inputs | Output structure | Custom fitting for time-course data | Key design notes | Provenance: how each fit was produced | Quick reference | Function signatures | fit_fn contract | summary_fn contract | Reference implementations | Single-agent fit functions (for apply_fit()) | Combination scoring | Composable step functions | Lower-level scoring functions (for apply_fit()) | SessionInfo