Longitudinal trajectories
Explore how repeated numerical measurements, such as PSA, tumor mutational burden, or tumor size, change over time within patients and across patient groups.
Explore how repeated numerical measurements, such as PSA, tumor mutational burden, or tumor size, change over time within patients and across patient groups.
Individual patient trajectories
Description
Analysis summary
Preserves each patient's repeated numeric measurements over time without combining patients or assigning categories. Supports inspection of individual longitudinal changes.
Computation
Retains unique patient/time/measurement combinations sorted by patient and time. An optional baseline shift subtracts each patient's earliest time, converting dates to elapsed days; alternatively, ordinal alignment replaces successive observations with shared visit-rank labels. The result table contains individual measurements and original or transformed times. A single descriptive row summarises all retained patients: distinct-patient count, observation count, mean, median, minimum, maximum and sample standard deviation of the measurements across time. No longitudinal model, change estimate or hypothesis test is fitted.
When to use
Use for 'how does this measurement change in each patient?' with repeated samples or events at different timepoints. This analysis is value-based: it requires a numeric measurement and summarises its evolution, not the occurrence, ordering or duration of clinical events. For which treatments a patient received, when, and for how long, use timeline_analysis. Prefer the category-preserving mode to relate individual histories to patient categories, or the aggregated mode for cohort-level trends.
Caveats
Repeated observations at different times are needed to assess change. Exact duplicates are removed, but distinct values at the same patient/time remain separate. Null numeric measurements are excluded. Overall statistics pool observations across visits, so patients with more measurements contribute more heavily; these statistics are not within-patient change summaries. Ordinal alignment discards elapsed intervals and does not establish clinically equivalent visits; tied times receive separate ranks. Baseline shifting and ordinal alignment are mutually exclusive, and baseline shifting needs subtractable times.
Example questions
Input columns
Visualizations
lineplotHow to read: Each line connects one patient's observed measurements, with markers at recorded timepoints and a patient key in the legend. The vertical axis is the measured quantity; the horizontal axis is original time, elapsed time from the patient's first observation (days for date inputs), or ordinal visit labels after alignment. Colours distinguish patients. Rising or falling segments describe observed changes, not fitted trends or values measured between visits. Ordinal spacing does not encode elapsed duration. Only the first patients in sorted identifier order are drawn up to the configured limit; the returned table and descriptive summary still include all retained patients.
Example analysis 1
Name — TMB Trajectories per Patient (MOSAIC Bladder)
Analysis parameters
Visualization — lineplot

Output table
Individual patient trajectories with categories
Description
Analysis summary
Preserves individual patients' repeated numeric measurements together with a patient category such as treatment arm or mutation status. Category membership does not combine patients' trajectories.
Computation
Retains unique patient/category/time/measurement combinations, sorted by patient and time, with either original times, per-patient elapsed times from baseline, or ordinal visit ranks. The result table keeps patient-level observations and their categories. The descriptive table contains one row per category with distinct-patient and observation counts, mean, median, minimum, maximum and sample standard deviation of measurements pooled across time. No between-category tests or longitudinal models are computed.
When to use
Use to inspect individual longitudinal changes while relating patients to a category, without averaging their histories. This analysis is value-based: it requires a numeric measurement and summarises its evolution, not the occurrence, ordering or duration of clinical events. For which treatments a patient received, when, and for how long, use timeline_analysis. Prefer the per-patient mode when no category is needed, or the aggregated mode for a cohort-level summary at each timepoint.
Caveats
The category should be constant per patient; changing categories are not modelled as time-varying exposures. Records with null categories or numeric measurements are excluded. Category summaries pool observations over time rather than comparing changes, and uneven sampling weights frequently measured patients more heavily. Distinct measurements at tied times remain separate. Ordinal alignment discards duration and assigns separate ranks to tied times; matching ranks need not represent equivalent clinical visits. Baseline shifting and ordinal alignment are mutually exclusive.
Example questions
Input columns
Visualizations
lineplotHow to read: Each line connects one patient's measurements and markers identify observed timepoints. Line colours and the legend identify categories, not category averages; multiple lines of the same colour remain separate patients. A patient's first retained category determines its line colour. The vertical axis is the measurement and the horizontal axis is original time, time from individual baseline, or ordinal visit rank. Compare within-category variability as well as differences between categories; connected segments are not fitted trends. The display limit selects patients in sorted identifier order, while returned observations and category statistics include all retained patients.
Example analysis 1
Name — TMB Trajectories per Patient Colored by Gender (MOSAIC Bladder)
Analysis parameters
Visualization — lineplot

Output table
Group-level longitudinal summaries
Description
Analysis summary
Summarises repeated numeric measurements within patient groups to compare cohort-level patterns over time. Shared observation times or aligned visit ranks allow patients with different recording dates to contribute to comparable timepoints.
Computation
Deduplicates patient/group/time/measurement combinations and optionally shifts each patient's time to baseline or replaces it with ordinal visit ranks. Groups are retained in sorted order up to the requested limit. The returned table keeps patient observations rather than pre-aggregated timepoint values. The descriptive table contains one row per retained group with patient and observation counts, mean, median, minimum, maximum and sample standard deviation pooled across time. Timepoint summaries can use the requested mean or median of observations at exact shared times, or patient-weighted mean and median within time bins: repeated samples within a bin first yield one mean per patient. No repeated-measures model, group-difference test or change estimate is computed.
When to use
Use for 'how does the typical measurement evolve in each treatment arm or cohort?' when comparable timepoints are available. This analysis is value-based: it requires a numeric measurement and summarises its evolution, not the occurrence, ordering or duration of clinical events. For which treatments a patient received, when, and for how long, use timeline_analysis. Prefer ordinal alignment when a common visit sequence is needed rather than actual elapsed intervals. Prefer either individual trajectory mode when patient-to-patient histories or heterogeneous responses matter.
Caveats
Aligned ranks do not guarantee clinically comparable visits and discard elapsed time. Changing patient composition over follow-up can mimic within-patient change. Returned group statistics pool observations, not timepoint summaries, and therefore weight frequent sampling more heavily. Exact-time observation summaries and binned patient-weighted summaries need not agree. The group limit also restricts returned data and statistics. Null groups or numeric measurements are excluded; tied times with different measurements remain separate and get separate ordinal ranks. Baseline shifting and ordinal alignment are mutually exclusive.
Example questions
Input columns
Visualizations
lineplotHow to read: The vertical axis is the measurement and the horizontal axis is original time, elapsed time from each patient's baseline, or ordinal visits. In Plotly, one line per group connects the selected mean or median of observations at each exact shared time; colours and the legend identify groups. In ECharts, groups occupy separate panels: the solid line is the patient-weighted median and the dashed line the patient-weighted mean, regardless of the requested aggregation. Date inputs use calendar-month bins, numeric inputs use one-unit bins, and categorical visits remain distinct. Repeated samples in a bin first yield one mean per patient. For groups with at least 40 patients, shaded quantile fans span the 5th–95th percentiles in 5-point increments; these show patient variability, not confidence intervals. Hover text reports the bin's median, mean and patient count, plus outer percentiles when shown. Changes can reflect which patients were sampled, not just changes within patients.
Example analysis 1
Name — Mean Measurement Trajectories by Metric (MOSAIC Bladder)
Analysis parameters
Visualization — lineplot

Output table
Last updated
Was this helpful?