Skip to main content

Crate splice_girl

Crate splice_girl 

Source
Expand description

Library entry point tying the pipeline together: parsed junctions -> per-(sample, gene) graphs -> Hodge decomposition. main.rs is a thin CLI wrapper around analyze_junctions.

Modules§

annotations
Carry supplied candidate evidence into results by exact versioned gene ID. These labels are input annotations, never inferred from Hodge measurements.
audit
Compact input and analysis audit used by splice-girl validate.
baselines
Descriptive baselines on exactly the same eligible biological samples.
compare
Joins a parsed sample manifest (manifest.rs) against the per-sample decomposition results (analyze_junctions in lib.rs) for one gene, producing sample-preserving case/control comparisons. This layer adds no inferential statistics and does not touch graph.rs/hodge.rs: it decides which already-computed samples are eligible, reports every exclusion, and can calculate transparent descriptive summaries for every observed gene.
fdr
Benjamini–Hochberg adjusted p-values for an explicitly supplied family. The caller chooses eligible tests before calling this library function. It does not select genes, perform tests, or assign significance labels.
graph
Turns the junction rows for one (sample, gene) group into a directed graph with a normalized edge signal, ready for the incidence-matrix and Hodge-decomposition steps in matrix.rs / hodge.rs.
hodge
The core Hodge decomposition, matching docs/math_spec.md. Splits a graph’s normalized junction-usage signal F into:
manifest
Parses and validates the sample manifest described in docs/data_contract.md: a TSV assigning each sample_id used in the junction table to a case or control group. Required columns are found by name rather than a fixed header, since real metadata files carry many extra columns this tool does not need.
matrix
A small dense linear-algebra toolkit used only by hodge.rs. Kept dependency-free (no external numerical crate) per the roadmap’s MVP priority of correctness over performance; revisit if graphs get large.
output
Machine-readable result exports and reproducibility manifests (R13).
parser
Reads and validates the tab-separated junction input described in the README: one row per observed splice junction, with columns sample_id, gene_id, from, to, count. This is the only place raw input is trusted from disk; everything downstream assumes rows already passed these checks.
permutation
Exact permutation testing for one gene’s case/control comparison, per docs/statistics_spec.md S5. Takes the already-eligible samples from compare::GeneComparison (inclusion/exclusion is decided there, not here) and tests whether the observed case-minus-control effect is unusual among every possible relabeling of the same group sizes.
ranking
Optional ordering of tested results. Ordering is not a significance decision.
report
Offline, academic comparison reports built from the existing analysis. Figures use individual sample values; missing measurements stay missing.
shared
Native preparation of a common graph for every covered cohort sample. These are explicit analysis choices, not implicit biological defaults.
statistics
Explicit-family statistics orchestration. Scientific choices are supplied by the caller; no gene list, sidedness, or replication threshold is inferred.
visualize
Dependency-free SVG rendering for one analyzed sample/gene graph.

Structs§

GroupResult
The graph and decomposition computed for one sample’s one gene.

Functions§

analyze_junctions
Groups junction rows by (sample_id, gene_id) — the decomposition is always computed within a single sample/gene, never pooled across samples — then builds a graph and runs the decomposition for each group.