Skip to main content

qikit

SPC charts and quality improvement tools for healthcare, in Python.

One function. One result object. One .plot() call.

Install

pip install clinical-qikit

Quickstart

from qikit import qic

result = qic(y=values, chart="i")
result.plot()   # returns a Plotly figure

qic() mirrors R's qicharts2, the package most healthcare QI practitioners already know — same chart types, same run-chart signal detection, same mental model, now in Python.

Chart types

All chart types are computed by the same qic() entry point via the chart= argument:

chart= Chart Use for
run Run chart Any sequential data, median center line
i Individuals (I) chart Continuous data, one observation per subgroup
mr Moving range Variation between consecutive observations
xbar X-bar chart Continuous data with subgroups (paired with s)
s S chart Subgroup standard deviation
t Time-between-events chart Time or count between rare events
p P chart Proportion (percent) defective, unequal subgroup sizes
pp P′ (Laney) chart Proportion data with overdispersion
c C chart Count of defects, constant opportunity
u U chart Rate of defects, unequal opportunity
up U′ (Laney) chart Rate data with overdispersion
g G chart Number of opportunities between rare events

qic(..., funnel=True) renders a funnel plot instead, for cross-sectional comparison across p/pp/u/up charts sorted by denominator.

Beyond qic(), the package also provides:

  • paretochart(x, data=...) — Pareto chart of categorical frequencies.
  • bchart(...) — Bernoulli CUSUM chart for early detection of shifts in binary (pass/fail) data.
  • design(factors, ...) / analyze(design_obj, response, ...) — full-factorial design of experiments (DOE) and effect analysis.

Excel add-in

A Microsoft Excel task-pane add-in built on the same charting engine (ported to TypeScript) lives in excel-addin/ — see its README for dev-harness and sideload instructions, and docs/excel-addin-roadmap.md for the roadmap.

Web app

app.py is a Streamlit front end over the same engine:

pip install -e .[app]
streamlit run app.py

Development

uv sync --extra dev
uv run ruff check .        # lint (CI-enforced)
uv run pytest tests/       # 176 tests incl. cross-language fixture conformance

The Python engine is authoritative; the TypeScript port in excel-addin/packages/engine conforms to it via the shared JSON fixtures in fixtures/. After intentional engine changes, regenerate the fixture snapshots with uv run python scripts/update_snapshots.py.

References

  1. Montgomery DC. Introduction to Statistical Quality Control, 8th ed. Wiley, 2019.
  2. Provost LP, Murray SK. The Health Care Data Guide, 2nd ed. Jossey-Bass, 2022.

License

MIT

Metadata

Release files for clinical-qikit 0.1.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for clinical-qikit 0.1.3
File Size Uploaded Provenance Actions
clinical_qikit-0.1.3.tar.gz 282.2 kB Without provenance Details for clinical_qikit-0.1.3.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for clinical-qikit 0.1.3
File Interpreter ABI Platform Actions
clinical_qikit-0.1.3-py3-none-any.whl Python 3 none any Details for clinical_qikit-0.1.3-py3-none-any.whl

Total release size: 323.8 kB

Release files / clinical_qikit-0.1.3.tar.gz

Download URL clinical_qikit-0.1.3.tar.gz
Size 282.2 kB
Tags Source
SHA-256 checksum
How to use checksums
60247f493866163edfe6f682ac3ddd9e5ae61f8a043fd9c6edec737b681c938f
BLAKE2b-256 checksum
How to use checksums
a67032049706155131a7959afe2972f4acbede813e25c32ef8590fb2931b91e8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.14.0

Release files / clinical_qikit-0.1.3-py3-none-any.whl

Download URL clinical_qikit-0.1.3-py3-none-any.whl
Size 41.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
2d62106e53800c55e806136f644d0ea981273ff691caee61ff8bd441de0be17c
BLAKE2b-256 checksum
How to use checksums
caf5892e0071c028d515fb2902f6317a4bbfdf30d0b5e5de01df7bda8be21579
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.14.0

Security for clinical-qikit 0.1.3

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page