define-variables

Featured

Literature-grounded variable operationalization for observational research. Turns a data dictionary + research question into a citation-backed table of exposure/outcome/covariate definitions, cutoffs, and DB variable mappings. Prevents ad-hoc phenotype definitions that invite reviewer rejection. Bridges /search-lit output into /write-protocol Methods.

Data & Documents 292 stars 71 forks Updated 4 days ago MIT

Install

View on GitHub

Quality Score: 95/100

Stars 20%
82
Recency 20%
100
Frontmatter 20%
70
Documentation 15%
100
Issue Health 10%
50
License 10%
100
Description 5%
100

Skill Content

# Define-Variables Skill ## Purpose Every observational study operationalizes abstract constructs (MASLD, CKD, emphysema, obesity, incidentaloma) into concrete rules against the available data dictionary. When that operationalization is invented ad-hoc from the dictionary alone, reviewers reject on construct validity regardless of downstream statistics. This skill forces a **literature-first** pass: each variable is mapped to a canonical guideline/consensus definition, cross-checked against prior operationalizations in comparable cohorts, then mapped to available DB variables. Ad-hoc deviations are flagged explicitly and justified, not hidden. Use it when: - a study question is known and variables are being selected - inclusion/exclusion criteria or phenotype definitions need citation backing - a data dictionary has ambiguous or derived variables (eGFR formula, BMI class, liver steatosis criteria, etc.) - a reviewer asked "why this cutoff?" - a retrospective audit reveals drifted definitions across projects in the same cohort Call after `/design-study`, before `/write-protocol`. ## Communication Rules - Communicate in the user's preferred language. - All variable names, guideline names, cutoffs in English. - Produce one artifact: `variable_operationalization.md` in the project root (or path the user specifies). ## Inputs 1. **Research question** (one sentence) 2. **Candidate variables** — exposure, outcome, key covariates, eligibility filters 3. **Data dictionary pat...

Details

Author
Aperivue
Repository
Aperivue/medsci-skills
Created
5 months ago
Last Updated
4 days ago
Language
Python
License
MIT

Bundled in these plugins

Similar Skills

Semantically similar based on skill content — not just same category

Data & Documents Featured

generate-codebook

Generate a citable data dictionary / codebook from a tabular dataset (CSV/TSV/Excel/Parquet/Stata/SAS). Profiles every variable — role, type, units placeholder, level frequencies, range/quantiles, missingness — and emits codebook.md + codebook.json. Flags coded variables whose level meanings are unknown as [NEEDS DICTIONARY] rather than guessing them, feeding /define-variables and the dictionary-first workflow.

292 Updated 4 days ago
Aperivue
Data & Documents Listed

lookdnbc

Look up DNBC (Danish National Birth Cohort) study variables by topic across all questionnaire waves. Use this whenever the user asks to find, list, or identify DNBC variables related to a concept (e.g. "find variables about smoking", "which variables cover maternal depression / breastfeeding / infections / childhood adversity?"), asks what variables exist in a given wave, needs variable names, descriptions, or answer labels from the DNBC codebooks, or is deciding which variables to pull during preprocessing. Searches a pre-built dictionary of ~7,900 variables from the Interview 1-4, 7-year, 11-year (child & adult) and 18-year follow-up codebooks and returns matches grouped by wave with each variable's name, description, and value labels. Trigger this even when the user only names a topic and asks "what DNBC variables are there for this?", or references a codebook, a wave, or a variable code such as A018, E_QDATE, Z004_1, or A031_5.

0 Updated 1 weeks ago
alkat19
Web & Frontend Featured

design-study

Study design and validity review for radiology and medical AI research. Identifies analysis unit, cohort logic, leakage risks, comparator design, validation strategy, and reporting guideline fit before drafting or submission.

292 Updated 4 days ago
Aperivue