ICF-native, single-case clinical-reasoning tools for rehabilitation.
Rehabilitation reasons differently from disease medicine: it targets disability and life reconstruction, evaluates the individual rather than a randomised group, combines qualitative judgement with quantitative signals, and is delivered by allied-health professionals (PT / OT / ST) with varied statistical backgrounds. PhysioRehab re-centres physiological measurement around that way of reasoning: it anchors measures and goals to the International Classification of Functioning (ICF), detects change with single-case methods, keeps the clinician in the loop, and drafts an ICF-structured progress note.
# the containers build on Bioconductor, so its repositories are needed too
install.packages("BiocManager", repos = "https://cloud.r-project.org")
install.packages("PhysioRehab",
repos = c("https://x-biosignal.r-universe.dev", BiocManager::repositories()))
The core is a single guided workflow:
measure the individual over time against personal goals
-> detect change defensibly with single-case methods (NAP + MCID + 2-SD band)
-> visualise against ICF and the trajectory
-> auto-draft an ICF-structured progress note
library(PhysioRehab)
ep <- simulate_stroke_gait_case() # a synthetic single case
hyp <- rehab_hypothesis("task-oriented training improves gait",
expect_speed_mcid = TRUE, expect_icf = c(d450 = 1))
res <- rehab_workflow(ep, hyp) # analyse -> reason -> plot -> draft
cat(res$report) # the ICF-structured progress note
res$plot_file # the single-case trajectory plot
The source repository bundles a fuller end-to-end demo script, run from a checkout of the package root:
Rscript inst/examples/run_demo.R
It simulates a chronic-stroke, left-hemiplegia single case (AB design, 12 sessions), runs the workflow, and writes two clinician-facing artefacts — an auto-drafted, ICF-structured progress note and a single-case trajectory plot — both to a temporary directory.
| Component | Description | Code |
|---|---|---|
| ICF-native semantics | Measures, goals and observations are anchored to WHO ICF codes with 0–4 qualifiers — the domain data model of rehabilitation. |
R/icf.R, R/goals.R
|
| Quantitative–qualitative fusion with an honest reasoning scaffold | Single-case change detection fuses signals with ICF qualifiers; a hypothesis-to-evidence check keeps the clinician in the loop and explicitly reports what the evidence does not support. |
R/sced.R, R/reasoning.R
|
| Guided workflow and clinician GUI | One call, rehab_workflow(), runs the whole path; a Shiny interface, rehab_app(), exposes it to non-programmers, while experts call the components directly. |
R/workflow.R, R/app.R
|
The clinician-facing output (R/report.R) drafts the progress note the
therapist already has to write, so measurement and analysis accompany routine
documentation.
PhysioRehab builds on the x-biosignal ecosystem rather than reimplementing it:
PhysioAppKit (NAP effect size, threshold-and-band
analysis; reconciled with PhysioClinStats::scedNAP).PhysioAnnotationHub (icf_for_measure() resolves a measure
to ICF codes from the maintained ontology).PhysioMoCap (markerless gait via add_session_from_mocap())
and PhysioEMG (muscle fatigue via add_session_from_emg()).PhysioAppKit.PhysioReport.See CITATION.cff. Licensed under the MIT License.