Version: 0.99.3 (Bioconductor x.99.y devel)
ClinicalVariantR is an R Shiny application for ACMG/AMP evidence-based germline variant prediction with per-variant curator workflow.
Repository: https://github.com/safarafique/ClinicalVariantR
Package metadata and submission guides live under inst/Bioconductor/:
| Document | Purpose |
|---|---|
inst/Bioconductor/SUBMISSION_CHECKLIST.md |
Required files + readiness status |
inst/Bioconductor/PACKAGE_CONVERSION.md |
Convert Shiny-app layout → Bioconductor package |
inst/Bioconductor/ISSUE_TEMPLATE_DRAFT.md |
Draft for BiocContributions issue |
Core package files: DESCRIPTION (version 0.99.3), NAMESPACE, LICENSE, NEWS.md, man/, vignettes/ClinicalVariantR.Rmd, tests/, inst/CITATION.
Install and launch (Bioconductor Shiny style — return app, user runs it). On Windows, restart R first if the package is already loaded:
# install.packages("remotes")
# Preferred while developing from this clone:
remotes::install_local("E:/ACGM/ClinicalVariantR", force = TRUE, upgrade = "never")
# Or from GitHub after the latest launcher is pushed:
# remotes::install_github("safarafique/ClinicalVariantR")
library(ClinicalVariantR)
app <- ClinicalVariantR()
if (interactive()) shiny::runApp(app, launch.browser = TRUE)
# Fast path without reinstall (avoids package R/ auto-load warning):
# shiny::runApp("E:/ACGM/ClinicalVariantR/inst/shinyapp", launch.browser = TRUE)
# Or from package root (app.R delegates to inst/shinyapp):
# shiny::runApp("E:/ACGM/ClinicalVariantR", launch.browser = TRUE)
On Windows with R 4.6, install Rtools 4.5+ before devtools::check() / package builds. Rtools 4.4 is not compatible. Until Rtools is fixed, you can still check without compiling:
devtools::check(vignettes = FALSE, args = "--no-manual", error_on = "never")
Important: documentation scaffold is ready; full package conversion (paths to inst/, remove source() chains, clean R CMD check / BiocCheck) must finish before opening a BiocContributions issue.
| Pipeline | Inputs | Scope |
|---|---|---|
| Group A (Clinical prediction) | VCF + Clinical CSV + Pedigree CSV | 28 criteria + per-variant curation |
| Group B (Automated prediction) | VCF only | 18 automated criteria |
| Group C (Gene panel) | VCF + gene list | Group B engine, panel-filtered |
Prediction mode (v2.5+): HPO/OMIM phenotype matching (PP4), trio genotype parsing (PS2/PM3/BP2), ClinGen AutoPVS1, login + encrypted uploads, formal validation report.
Prediction mode (v2.4+): stricter PVS1 (LoF panel required), evidence strength labels, prediction limitations per variant, reference readiness checks.
See config/prediction_reference_install.md for full gnomAD/ClinVar/REVEL setup.
AUTH_ENABLED <- FALSE in R/auth_storage.R). For secured demos, provide users through config/auth_users.csv or the CLINICALVARIANTR_USER / CLINICALVARIANTR_PASSWORD environment variables.CLINICALVARIANTR_USER and CLINICALVARIANTR_PASSWORD when no user file is present.logs/secure_uploads/; set CLINICALVARIANTR_ENCRYPTION_KEY (32 chars) for production.logs/access_audit.csv.cd ClinicalVariantR
Rscript scripts/generate_validation_report.R
Expert-classified variants live in data/validation/clinicalvariantr_validation_set.tsv (expand toward 500+ for production sign-off).
Features include VCF requirement validation (green/red readiness), variant preview, complete large-VCF streaming analysis (no row cap), optional bcftools integration on Ubuntu/WSL, color-coded results, audit logging, and CSV export.
First launch from this clone auto-installs missing R packages (CRAN + Bioconductor), then opens the app:
shiny::runApp("E:/ACGM/ClinicalVariantR", launch.browser = TRUE)
Or install dependencies once, then launch:
# Optional one-shot install (same as first-run auto-install):
# Rscript scripts/install_app_deps.R
shiny::runApp("E:/ACGM/ClinicalVariantR", launch.browser = TRUE)
Package install path:
install.packages("remotes")
remotes::install_local("E:/ACGM/ClinicalVariantR", force = TRUE, upgrade = "never", dependencies = TRUE)
library(ClinicalVariantR)
app <- ClinicalVariantR()
if (interactive()) shiny::runApp(app, launch.browser = TRUE)
To install dependencies once from a clone (not used by the Bioconductor package tarball):
# Rscript scripts/install_app_deps.R
# Or: source("scripts/bootstrap_deps.R"); clinicalvariantr_ensure_dependencies()
shiny::runApp("E:/ACGM/ClinicalVariantR", launch.browser = TRUE)
cd /mnt/e/ACGM/ClinicalVariantR
bash scripts/ubuntu_setup.sh # bcftools + R CLI packages
# Or install R CLI deps only:
Rscript scripts/install_r_cli_deps.R # data.table, readr, jsonlite → ~/R/.../library
R -e "shiny::runApp('.', host='0.0.0.0', port=3838)"
Verify scripts (after install_r_cli_deps.R completes):
Rscript scripts/verify_group_a_28.R
Rscript scripts/verify_group_b_c.R
Rscript scripts/generate_validation_report.R
Each pipeline includes an Expert review checklist accordion with worklist counts and filtered CSV exports:
Use the full prediction report for audit; use the worklist export to start manual sign-out review.
For a fuller file-by-file orientation, see CODEBASE_MAP.md.
ClinicalVariantR/
├── app.R
├── global.R
├── ui.R
├── server.R
├── R/ # ACMG logic, VCF parsing, validation, streaming
├── data/reference/ # gnomAD, ClinVar, REVEL placeholders
├── data/samples/ # Example VCF and CSV files
├── scripts/ # ubuntu_setup.sh, validate_logic.R
├── logs/ # Runtime audit logs (gitignored)
└── www/ # Custom CSS
| Option | Default | Purpose |
|---|---|---|
| Analyze entire VCF | ON | Process every row (no limit) |
| FILTER=PASS only | OFF | Optional QC pre-filter |
| Minimum QUAL | 0 | Drop low-quality rows |
| Use bcftools | auto | Ubuntu/WSL speed boost |
| Chunk size | 10,000 | Variants per memory batch |
Best input for expert review: download the ClinicalVariantR CSV export after analysis completes.
| Export | When to use |
|---|---|
ClinicalVariantR_Expert_Worklist_*.csv |
Start here — LP+ and high-priority VUS for sign-out review |
ClinicalVariantR_LP_Plus_*.csv |
Pathogenic / Likely Pathogenic only |
ClinicalVariantR_Prediction_Report_*.csv |
Full audit trail — all variants and evidence |
Key columns for expert review: variant_id, gene, classification, criteria_met, criteria_rationale, prediction_limitations, evidence_json, confidence_score, evidence_strength.
Also written automatically under logs/ during streaming runs. Audit trail: logs/analysis_log.csv.
setwd("path/to/ClinicalVariantR")
source("global.R")
test_acmg_logic_engine()
MIT (add LICENSE file if required for Bioconductor submission)