medsci-skills 4.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +50 -0
- package/README.md +602 -0
- package/README_FIRST.md +27 -0
- package/bin/medsci-skills.js +159 -0
- package/installers/install-macos.command +19 -0
- package/installers/install-windows.cmd +26 -0
- package/installers/install-windows.ps1 +17 -0
- package/installers/install.py +218 -0
- package/metadata/skills_catalog.json +452 -0
- package/package.json +48 -0
- package/skills/academic-aio/SKILL.md +408 -0
- package/skills/academic-aio/references/case_studies/kjr_mllm_2025.md +82 -0
- package/skills/academic-aio/references/checklists/AIO_GENERAL.md +354 -0
- package/skills/academic-aio/references/journal_summarybox_templates.yaml +126 -0
- package/skills/academic-aio/references/oac_funding_checklist.yaml +129 -0
- package/skills/academic-aio/references/reporting_guideline_mapping.md +39 -0
- package/skills/academic-aio/references/schema_markup_templates/CodeRepository.jsonld +32 -0
- package/skills/academic-aio/references/schema_markup_templates/Dataset.jsonld +36 -0
- package/skills/academic-aio/references/schema_markup_templates/Person.jsonld +30 -0
- package/skills/academic-aio/references/schema_markup_templates/README.md +43 -0
- package/skills/academic-aio/references/schema_markup_templates/ScholarlyArticle.jsonld +55 -0
- package/skills/academic-aio/scripts/batch_metadata_audit.py +169 -0
- package/skills/academic-aio/scripts/validate_schema.py +118 -0
- package/skills/academic-aio/skill.yml +36 -0
- package/skills/academic-aio/templates/aio_audit_checklist.md.j2 +108 -0
- package/skills/add-journal/SKILL.md +482 -0
- package/skills/add-journal/skill.yml +33 -0
- package/skills/analyze-stats/SKILL.md +598 -0
- package/skills/analyze-stats/references/analysis_guides/missing_data.md +109 -0
- package/skills/analyze-stats/references/analysis_guides/nhis_icd10_mapping.md +247 -0
- package/skills/analyze-stats/references/analysis_guides/propensity_score.md +132 -0
- package/skills/analyze-stats/references/analysis_guides/regression.md +115 -0
- package/skills/analyze-stats/references/analysis_guides/repeated_measures.md +160 -0
- package/skills/analyze-stats/references/analysis_guides/survey_weighted.md +366 -0
- package/skills/analyze-stats/references/analysis_guides/test_selection.md +86 -0
- package/skills/analyze-stats/references/style/figure_style.mplstyle +69 -0
- package/skills/analyze-stats/references/style/theme_publication.R +147 -0
- package/skills/analyze-stats/references/table-standards/journal-profiles/ajr.yaml +51 -0
- package/skills/analyze-stats/references/table-standards/journal-profiles/european_radiology.yaml +55 -0
- package/skills/analyze-stats/references/table-standards/journal-profiles/jama.yaml +66 -0
- package/skills/analyze-stats/references/table-standards/journal-profiles/lancet.yaml +57 -0
- package/skills/analyze-stats/references/table-standards/journal-profiles/nejm.yaml +51 -0
- package/skills/analyze-stats/references/table-standards/journal-profiles/radiology.yaml +66 -0
- package/skills/analyze-stats/references/table-standards/table-standards.md +287 -0
- package/skills/analyze-stats/references/table-standards/table-types/diagnostic_accuracy.md +36 -0
- package/skills/analyze-stats/references/table-standards/table-types/meta_analysis.md +58 -0
- package/skills/analyze-stats/references/table-standards/table-types/model_comparison.md +36 -0
- package/skills/analyze-stats/references/table-standards/table-types/regression_results.md +50 -0
- package/skills/analyze-stats/references/table-standards/table-types/table1_demographics.md +51 -0
- package/skills/analyze-stats/references/table-standards/tool-comparison.md +79 -0
- package/skills/analyze-stats/references/templates/agreement_analysis.py +436 -0
- package/skills/analyze-stats/references/templates/dca_plot.R +237 -0
- package/skills/analyze-stats/references/templates/diagnostic_accuracy.py +401 -0
- package/skills/analyze-stats/references/templates/dta_meta_analysis.R +384 -0
- package/skills/analyze-stats/references/templates/forest_plot.py +412 -0
- package/skills/analyze-stats/references/templates/likert_summary.py +356 -0
- package/skills/analyze-stats/references/templates/meta_analysis.R +365 -0
- package/skills/analyze-stats/references/templates/propensity_score.py +478 -0
- package/skills/analyze-stats/references/templates/regression.py +425 -0
- package/skills/analyze-stats/references/templates/repeated_measures.py +434 -0
- package/skills/analyze-stats/references/templates/sample_size.R +382 -0
- package/skills/analyze-stats/references/templates/survey_weighted_analysis.py +411 -0
- package/skills/analyze-stats/references/templates/survival_analysis.py +325 -0
- package/skills/analyze-stats/references/templates/table1_demographics.py +287 -0
- package/skills/analyze-stats/scripts/check_generated_code.py +335 -0
- package/skills/analyze-stats/skill.yml +38 -0
- package/skills/analyze-stats/tests/fixtures/gen_bad.R +16 -0
- package/skills/analyze-stats/tests/fixtures/gen_bad.py +24 -0
- package/skills/analyze-stats/tests/fixtures/gen_clean.py +21 -0
- package/skills/analyze-stats/tests/test_generated_code.sh +59 -0
- package/skills/analyze-stats/tests/test_survival_template.sh +53 -0
- package/skills/author-strategy/SKILL.md +117 -0
- package/skills/author-strategy/analyze_patterns.py +303 -0
- package/skills/author-strategy/fetch_pubmed.py +374 -0
- package/skills/author-strategy/skill.yml +34 -0
- package/skills/batch-cohort/SKILL.md +223 -0
- package/skills/batch-cohort/references/base_template_knhanes.R +210 -0
- package/skills/batch-cohort/references/batch_template_generator.R +222 -0
- package/skills/batch-cohort/references/variable_coding_registry.md +136 -0
- package/skills/batch-cohort/skill.yml +35 -0
- package/skills/calc-sample-size/SKILL.md +491 -0
- package/skills/calc-sample-size/references/formulas.md +655 -0
- package/skills/calc-sample-size/references/observational_cohort.md +49 -0
- package/skills/calc-sample-size/skill.yml +51 -0
- package/skills/check-reporting/SKILL.md +534 -0
- package/skills/check-reporting/references/LICENSES.md +41 -0
- package/skills/check-reporting/references/checklists/AMSTAR2.md +54 -0
- package/skills/check-reporting/references/checklists/ARRIVE_2.md +234 -0
- package/skills/check-reporting/references/checklists/CARE.md +102 -0
- package/skills/check-reporting/references/checklists/CLAIM_2024.md +128 -0
- package/skills/check-reporting/references/checklists/CLEAR.md +113 -0
- package/skills/check-reporting/references/checklists/CONSORT.md +86 -0
- package/skills/check-reporting/references/checklists/COSMIN_RoB.md +136 -0
- package/skills/check-reporting/references/checklists/GRRAS.md +61 -0
- package/skills/check-reporting/references/checklists/MI_CLEAR_LLM.md +167 -0
- package/skills/check-reporting/references/checklists/MOOSE.md +85 -0
- package/skills/check-reporting/references/checklists/NOS.md +88 -0
- package/skills/check-reporting/references/checklists/PRISMA_2020.md +135 -0
- package/skills/check-reporting/references/checklists/PRISMA_DTA.md +36 -0
- package/skills/check-reporting/references/checklists/PRISMA_P.md +56 -0
- package/skills/check-reporting/references/checklists/PROBAST.md +75 -0
- package/skills/check-reporting/references/checklists/PROBAST_AI.md +130 -0
- package/skills/check-reporting/references/checklists/QUADAS2.md +77 -0
- package/skills/check-reporting/references/checklists/QUADAS_C.md +131 -0
- package/skills/check-reporting/references/checklists/ROBINS_E.md +179 -0
- package/skills/check-reporting/references/checklists/ROBINS_I.md +87 -0
- package/skills/check-reporting/references/checklists/ROBIS.md +114 -0
- package/skills/check-reporting/references/checklists/ROB_ME.md +126 -0
- package/skills/check-reporting/references/checklists/RoB2.md +79 -0
- package/skills/check-reporting/references/checklists/RoB_NMA.md +96 -0
- package/skills/check-reporting/references/checklists/SPIRIT.md +112 -0
- package/skills/check-reporting/references/checklists/SQUIRE_2.md +68 -0
- package/skills/check-reporting/references/checklists/STARD.md +129 -0
- package/skills/check-reporting/references/checklists/STARD_AI.md +211 -0
- package/skills/check-reporting/references/checklists/STROBE.md +80 -0
- package/skills/check-reporting/references/checklists/SWiM.md +33 -0
- package/skills/check-reporting/references/checklists/TRIPOD.md +157 -0
- package/skills/check-reporting/references/checklists/TRIPOD_AI.md +140 -0
- package/skills/check-reporting/references/step4c_registration_timing.md +93 -0
- package/skills/check-reporting/references/step4d_prisma_figure_audit.md +137 -0
- package/skills/check-reporting/scripts/check_checklist_exists.py +183 -0
- package/skills/check-reporting/scripts/check_checklist_version.py +168 -0
- package/skills/check-reporting/scripts/check_framework_naming.py +206 -0
- package/skills/check-reporting/scripts/check_prisma_figure.py +209 -0
- package/skills/check-reporting/scripts/prisma_cascade_check.py +274 -0
- package/skills/check-reporting/skill.yml +41 -0
- package/skills/check-reporting/tests/fixtures/framework_bad.md +8 -0
- package/skills/check-reporting/tests/fixtures/framework_clean.md +7 -0
- package/skills/check-reporting/tests/test_checklist_fail_fast.sh +77 -0
- package/skills/check-reporting/tests/test_checklist_version.sh +72 -0
- package/skills/check-reporting/tests/test_framework_naming.sh +45 -0
- package/skills/check-reporting/tests/test_prisma_cascade.sh +104 -0
- package/skills/clean-data/SKILL.md +180 -0
- package/skills/clean-data/references/cleaning_patterns.md +299 -0
- package/skills/clean-data/references/profiling_template.py +304 -0
- package/skills/clean-data/scripts/check_structural_zero.py +174 -0
- package/skills/clean-data/skill.yml +35 -0
- package/skills/clean-data/tests/fixtures/smoking.csv +8 -0
- package/skills/clean-data/tests/test_structural_zero.sh +49 -0
- package/skills/cross-national/SKILL.md +264 -0
- package/skills/cross-national/skill.yml +37 -0
- package/skills/define-variables/SKILL.md +146 -0
- package/skills/define-variables/references/common_definitions.md +190 -0
- package/skills/define-variables/skill.yml +34 -0
- package/skills/define-variables/templates/variable_operationalization.md +64 -0
- package/skills/deidentify/SKILL.md +203 -0
- package/skills/deidentify/deidentify.py +1224 -0
- package/skills/deidentify/locales/_template.json +45 -0
- package/skills/deidentify/locales/au.json +43 -0
- package/skills/deidentify/locales/ca.json +44 -0
- package/skills/deidentify/locales/cn.json +47 -0
- package/skills/deidentify/locales/de.json +48 -0
- package/skills/deidentify/locales/fr.json +48 -0
- package/skills/deidentify/locales/in.json +48 -0
- package/skills/deidentify/locales/jp.json +48 -0
- package/skills/deidentify/locales/kr.json +48 -0
- package/skills/deidentify/locales/uk.json +45 -0
- package/skills/deidentify/locales/us.json +43 -0
- package/skills/deidentify/references/date_shift_guide.md +82 -0
- package/skills/deidentify/references/hipaa_18_identifiers.md +48 -0
- package/skills/deidentify/references/korean_phi_patterns.md +135 -0
- package/skills/deidentify/skill.yml +43 -0
- package/skills/deidentify/tests/README.md +26 -0
- package/skills/deidentify/tests/test_clean.csv +16 -0
- package/skills/deidentify/tests/test_edge_cases.csv +11 -0
- package/skills/deidentify/tests/test_phi_korean.csv +11 -0
- package/skills/design-ai-benchmarking/SKILL.md +214 -0
- package/skills/design-ai-benchmarking/references/benchmark_export_schema.json +69 -0
- package/skills/design-ai-benchmarking/references/elicitation_rubric_template.md +37 -0
- package/skills/design-ai-benchmarking/skill.yml +38 -0
- package/skills/design-study/SKILL.md +298 -0
- package/skills/design-study/skill.yml +33 -0
- package/skills/fill-icmje-coi/SKILL.md +216 -0
- package/skills/fill-icmje-coi/scripts/fill_icmje_coi.py +140 -0
- package/skills/fill-icmje-coi/skill.yml +35 -0
- package/skills/fill-icmje-coi/templates/icmje_coi_seed_synthetic.docx +0 -0
- package/skills/fill-protocol/SKILL.md +248 -0
- package/skills/fill-protocol/examples/example_irb_template.yaml +53 -0
- package/skills/fill-protocol/references/best_practices.md +121 -0
- package/skills/fill-protocol/scripts/doc_to_docx.py +111 -0
- package/skills/fill-protocol/scripts/fill_form.py +611 -0
- package/skills/fill-protocol/scripts/inspect_template.py +61 -0
- package/skills/fill-protocol/setup.sh +162 -0
- package/skills/fill-protocol/skill.yml +37 -0
- package/skills/find-cohort-gap/SKILL.md +309 -0
- package/skills/find-cohort-gap/references/cohort_profile_template.md +93 -0
- package/skills/find-cohort-gap/references/onepager_template.md +84 -0
- package/skills/find-cohort-gap/references/pattern_scoring_rubric.md +169 -0
- package/skills/find-cohort-gap/references/saturation_query_templates.md +143 -0
- package/skills/find-cohort-gap/skill.yml +35 -0
- package/skills/find-journal/POLICY.md +87 -0
- package/skills/find-journal/SKILL.md +340 -0
- package/skills/find-journal/references/journal_profiles/AJNR.md +29 -0
- package/skills/find-journal/references/journal_profiles/AJR.md +30 -0
- package/skills/find-journal/references/journal_profiles/Abdominal_Radiology.md +30 -0
- package/skills/find-journal/references/journal_profiles/Academic_Radiology.md +30 -0
- package/skills/find-journal/references/journal_profiles/Annals_of_Internal_Medicine.md +33 -0
- package/skills/find-journal/references/journal_profiles/Artificial_Intelligence_in_Medicine.md +28 -0
- package/skills/find-journal/references/journal_profiles/BMC_Medicine.md +31 -0
- package/skills/find-journal/references/journal_profiles/British_Journal_of_Radiology.md +39 -0
- package/skills/find-journal/references/journal_profiles/CVIR.md +30 -0
- package/skills/find-journal/references/journal_profiles/Chest.md +39 -0
- package/skills/find-journal/references/journal_profiles/Clinical_Radiology.md +30 -0
- package/skills/find-journal/references/journal_profiles/Clinical_and_Molecular_Hepatology.md +32 -0
- package/skills/find-journal/references/journal_profiles/Diabetes_Metabolism_Journal.md +36 -0
- package/skills/find-journal/references/journal_profiles/Diagnostic_and_Interventional_Radiology.md +32 -0
- package/skills/find-journal/references/journal_profiles/Endocrinology_and_Metabolism.md +37 -0
- package/skills/find-journal/references/journal_profiles/European_Journal_of_Preventive_Cardiology.md +39 -0
- package/skills/find-journal/references/journal_profiles/European_Radiology.md +29 -0
- package/skills/find-journal/references/journal_profiles/Hepatology_Communications.md +40 -0
- package/skills/find-journal/references/journal_profiles/Hepatology_International.md +37 -0
- package/skills/find-journal/references/journal_profiles/IEEE_JBHI.md +28 -0
- package/skills/find-journal/references/journal_profiles/IEEE_TMI.md +28 -0
- package/skills/find-journal/references/journal_profiles/INSI.md +29 -0
- package/skills/find-journal/references/journal_profiles/Investigative_Radiology.md +25 -0
- package/skills/find-journal/references/journal_profiles/JACC_Advances.md +41 -0
- package/skills/find-journal/references/journal_profiles/JACC_Asia.md +30 -0
- package/skills/find-journal/references/journal_profiles/JACR.md +28 -0
- package/skills/find-journal/references/journal_profiles/JAMA.md +40 -0
- package/skills/find-journal/references/journal_profiles/JAMA_Network_Open.md +30 -0
- package/skills/find-journal/references/journal_profiles/JCSM.md +39 -0
- package/skills/find-journal/references/journal_profiles/JKMS.md +32 -0
- package/skills/find-journal/references/journal_profiles/JMIR.md +29 -0
- package/skills/find-journal/references/journal_profiles/JMIR_Medical_Education.md +29 -0
- package/skills/find-journal/references/journal_profiles/JNIS.md +35 -0
- package/skills/find-journal/references/journal_profiles/JVIR.md +31 -0
- package/skills/find-journal/references/journal_profiles/Journal_of_Biomedical_Informatics.md +29 -0
- package/skills/find-journal/references/journal_profiles/Journal_of_Clinical_Endocrinology_and_Metabolism.md +40 -0
- package/skills/find-journal/references/journal_profiles/Journal_of_Magnetic_Resonance_Imaging.md +30 -0
- package/skills/find-journal/references/journal_profiles/Journal_of_Nuclear_Medicine.md +31 -0
- package/skills/find-journal/references/journal_profiles/Journal_of_Stroke.md +32 -0
- package/skills/find-journal/references/journal_profiles/KJR.md +38 -0
- package/skills/find-journal/references/journal_profiles/Korean_Circulation_Journal.md +38 -0
- package/skills/find-journal/references/journal_profiles/Korean_Journal_of_Internal_Medicine.md +36 -0
- package/skills/find-journal/references/journal_profiles/Lancet_Diabetes_and_Endocrinology.md +40 -0
- package/skills/find-journal/references/journal_profiles/Lancet_Gastroenterology_and_Hepatology.md +49 -0
- package/skills/find-journal/references/journal_profiles/Lancet_Infectious_Diseases.md +38 -0
- package/skills/find-journal/references/journal_profiles/Lancet_Neurology.md +39 -0
- package/skills/find-journal/references/journal_profiles/Lancet_Oncology.md +40 -0
- package/skills/find-journal/references/journal_profiles/Lancet_Psychiatry.md +38 -0
- package/skills/find-journal/references/journal_profiles/Lancet_Public_Health.md +30 -0
- package/skills/find-journal/references/journal_profiles/Lancet_Respiratory_Medicine.md +39 -0
- package/skills/find-journal/references/journal_profiles/Liver_International.md +33 -0
- package/skills/find-journal/references/journal_profiles/Medical_Image_Analysis.md +28 -0
- package/skills/find-journal/references/journal_profiles/NEJM.md +33 -0
- package/skills/find-journal/references/journal_profiles/Nature_Machine_Intelligence.md +31 -0
- package/skills/find-journal/references/journal_profiles/Nature_Medicine.md +39 -0
- package/skills/find-journal/references/journal_profiles/Neuroradiology.md +31 -0
- package/skills/find-journal/references/journal_profiles/Nutrition_Metabolism_and_Cardiovascular_Diseases.md +39 -0
- package/skills/find-journal/references/journal_profiles/PLOS_Medicine.md +32 -0
- package/skills/find-journal/references/journal_profiles/RYAI.md +28 -0
- package/skills/find-journal/references/journal_profiles/Radiology.md +29 -0
- package/skills/find-journal/references/journal_profiles/Skeletal_Radiology.md +31 -0
- package/skills/find-journal/references/journal_profiles/Stroke.md +37 -0
- package/skills/find-journal/references/journal_profiles/The_BMJ.md +31 -0
- package/skills/find-journal/references/journal_profiles/The_Lancet.md +31 -0
- package/skills/find-journal/references/journal_profiles/The_Lancet_Digital_Health.md +29 -0
- package/skills/find-journal/references/journal_profiles/World_Journal_of_Hepatology.md +53 -0
- package/skills/find-journal/references/journal_profiles/npj_Digital_Medicine.md +29 -0
- package/skills/find-journal/skill.yml +34 -0
- package/skills/fulltext-retrieval/SKILL.md +174 -0
- package/skills/fulltext-retrieval/fetch_oa.py +433 -0
- package/skills/fulltext-retrieval/pdf_to_md.py +160 -0
- package/skills/fulltext-retrieval/skill.yml +41 -0
- package/skills/generate-codebook/SKILL.md +155 -0
- package/skills/generate-codebook/references/codebook_schema.md +76 -0
- package/skills/generate-codebook/scripts/generate_codebook.py +278 -0
- package/skills/generate-codebook/skill.yml +35 -0
- package/skills/generate-codebook/tests/test_generate_codebook.sh +76 -0
- package/skills/grant-builder/SKILL.md +251 -0
- package/skills/grant-builder/skill.yml +34 -0
- package/skills/humanize/SKILL.md +251 -0
- package/skills/humanize/references/ai_patterns.md +571 -0
- package/skills/humanize/skill.yml +33 -0
- package/skills/intake-project/SKILL.md +264 -0
- package/skills/intake-project/skill.yml +34 -0
- package/skills/lit-sync/SKILL.md +448 -0
- package/skills/lit-sync/references/locale/ko/note_templates.md +110 -0
- package/skills/lit-sync/skill.yml +52 -0
- package/skills/lit-sync/tests/test_poll_logic.sh +92 -0
- package/skills/ma-scout/SKILL.md +640 -0
- package/skills/ma-scout/references/project_readme_template.md +95 -0
- package/skills/ma-scout/references/project_readme_template_ko.md +82 -0
- package/skills/ma-scout/skill.yml +33 -0
- package/skills/make-figures/SKILL.md +957 -0
- package/skills/make-figures/references/critic_rubrics/data_plot.md +166 -0
- package/skills/make-figures/references/critic_rubrics/flow_diagram.md +169 -0
- package/skills/make-figures/references/design_principles.md +181 -0
- package/skills/make-figures/references/exemplar_diagrams/README.md +65 -0
- package/skills/make-figures/references/exemplar_diagrams/consort/README.md +15 -0
- package/skills/make-figures/references/exemplar_diagrams/consort/template_input.yaml +37 -0
- package/skills/make-figures/references/exemplar_diagrams/consort/template_output.pdf +0 -0
- package/skills/make-figures/references/exemplar_diagrams/consort/template_output.png +0 -0
- package/skills/make-figures/references/exemplar_diagrams/consort/template_output_600.png +0 -0
- package/skills/make-figures/references/exemplar_diagrams/other/other_02.meta.yaml +4 -0
- package/skills/make-figures/references/exemplar_diagrams/other/other_02.png +0 -0
- package/skills/make-figures/references/exemplar_diagrams/other/other_02_why.md +13 -0
- package/skills/make-figures/references/exemplar_diagrams/pipeline/README.md +15 -0
- package/skills/make-figures/references/exemplar_diagrams/pipeline/pipeline_01.meta.yaml +4 -0
- package/skills/make-figures/references/exemplar_diagrams/pipeline/pipeline_01.png +0 -0
- package/skills/make-figures/references/exemplar_diagrams/pipeline/pipeline_01_why.md +13 -0
- package/skills/make-figures/references/exemplar_diagrams/pipeline/pipeline_03.meta.yaml +4 -0
- package/skills/make-figures/references/exemplar_diagrams/pipeline/pipeline_03.png +0 -0
- package/skills/make-figures/references/exemplar_diagrams/pipeline/pipeline_03_why.md +13 -0
- package/skills/make-figures/references/exemplar_diagrams/pipeline/pipeline_04.meta.yaml +4 -0
- package/skills/make-figures/references/exemplar_diagrams/pipeline/pipeline_04.png +0 -0
- package/skills/make-figures/references/exemplar_diagrams/pipeline/pipeline_04_why.md +13 -0
- package/skills/make-figures/references/exemplar_diagrams/pipeline/pipeline_05.meta.yaml +4 -0
- package/skills/make-figures/references/exemplar_diagrams/pipeline/pipeline_05.png +0 -0
- package/skills/make-figures/references/exemplar_diagrams/pipeline/pipeline_05_why.md +13 -0
- package/skills/make-figures/references/exemplar_diagrams/pipeline/pipeline_06.meta.yaml +4 -0
- package/skills/make-figures/references/exemplar_diagrams/pipeline/pipeline_06.png +0 -0
- package/skills/make-figures/references/exemplar_diagrams/pipeline/pipeline_06_why.md +13 -0
- package/skills/make-figures/references/exemplar_diagrams/pipeline/pipeline_07.meta.yaml +4 -0
- package/skills/make-figures/references/exemplar_diagrams/pipeline/pipeline_07.png +0 -0
- package/skills/make-figures/references/exemplar_diagrams/pipeline/pipeline_07_why.md +13 -0
- package/skills/make-figures/references/exemplar_diagrams/pipeline/pipeline_08.meta.yaml +4 -0
- package/skills/make-figures/references/exemplar_diagrams/pipeline/pipeline_08.png +0 -0
- package/skills/make-figures/references/exemplar_diagrams/pipeline/pipeline_08_why.md +13 -0
- package/skills/make-figures/references/exemplar_diagrams/pipeline/pipeline_09.meta.yaml +4 -0
- package/skills/make-figures/references/exemplar_diagrams/pipeline/pipeline_09.png +0 -0
- package/skills/make-figures/references/exemplar_diagrams/pipeline/pipeline_09_why.md +13 -0
- package/skills/make-figures/references/exemplar_diagrams/pipeline/pipeline_10.meta.yaml +4 -0
- package/skills/make-figures/references/exemplar_diagrams/pipeline/pipeline_10.png +0 -0
- package/skills/make-figures/references/exemplar_diagrams/pipeline/pipeline_10_why.md +13 -0
- package/skills/make-figures/references/exemplar_diagrams/prisma/README.md +15 -0
- package/skills/make-figures/references/exemplar_diagrams/prisma/template_input.yaml +47 -0
- package/skills/make-figures/references/exemplar_diagrams/prisma/template_output.pdf +0 -0
- package/skills/make-figures/references/exemplar_diagrams/prisma/template_output.png +0 -0
- package/skills/make-figures/references/exemplar_diagrams/prisma/template_output_600.png +0 -0
- package/skills/make-figures/references/exemplar_diagrams/stard/README.md +15 -0
- package/skills/make-figures/references/exemplar_diagrams/stard/template_input.yaml +40 -0
- package/skills/make-figures/references/exemplar_diagrams/stard/template_output.pdf +0 -0
- package/skills/make-figures/references/exemplar_diagrams/stard/template_output.png +0 -0
- package/skills/make-figures/references/exemplar_diagrams/stard/template_output_600.png +0 -0
- package/skills/make-figures/references/exemplar_diagrams/strobe/template_input.yaml +43 -0
- package/skills/make-figures/references/exemplar_diagrams/strobe/template_input_pptx.yaml +43 -0
- package/skills/make-figures/references/exemplar_diagrams/strobe/template_output.pdf +0 -0
- package/skills/make-figures/references/exemplar_diagrams/strobe/template_output.png +0 -0
- package/skills/make-figures/references/exemplar_diagrams/strobe/template_output.pptx +0 -0
- package/skills/make-figures/references/exemplar_diagrams/strobe/template_output_600.png +0 -0
- package/skills/make-figures/references/figure_specs.md +291 -0
- package/skills/make-figures/references/flow_diagram_lessons.md +164 -0
- package/skills/make-figures/references/jacc_central_illustration_principles.md +91 -0
- package/skills/make-figures/references/medical_illustration_sources.md +98 -0
- package/skills/make-figures/references/pipeline_concepts_medical_ai.md +240 -0
- package/skills/make-figures/references/reporting_guideline_figure_map.md +104 -0
- package/skills/make-figures/references/visual_abstract_templates/european_radiology.pptx +0 -0
- package/skills/make-figures/references/visual_abstract_templates/jacc_central_illustration.pptx +0 -0
- package/skills/make-figures/references/visual_abstract_templates/medsci_default.pptx +0 -0
- package/skills/make-figures/references/visual_abstract_templates/template_guide.md +114 -0
- package/skills/make-figures/scripts/build_jacc_template.py +77 -0
- package/skills/make-figures/scripts/build_prisma2020_template.py +371 -0
- package/skills/make-figures/scripts/build_strobe_template.py +351 -0
- package/skills/make-figures/scripts/critic_figure.py +264 -0
- package/skills/make-figures/scripts/derive_figure_legend_counts.py +138 -0
- package/skills/make-figures/scripts/extract_exemplar_from_pdf.py +186 -0
- package/skills/make-figures/scripts/fetch_official_templates.sh +88 -0
- package/skills/make-figures/scripts/fill_prisma_template.py +142 -0
- package/skills/make-figures/scripts/generate_flow_diagram.R +133 -0
- package/skills/make-figures/scripts/generate_image.py +99 -0
- package/skills/make-figures/scripts/generate_visual_abstract.py +438 -0
- package/skills/make-figures/scripts/validate_pptx_mac_compat.py +233 -0
- package/skills/make-figures/skill.yml +52 -0
- package/skills/make-figures/templates/official/NOTES.md +62 -0
- package/skills/make-figures/templates/official/consort2010/CONSORT_2025_editable_checklist.docx +0 -0
- package/skills/make-figures/templates/official/consort2010/CONSORT_2025_flow_diagram.docx +0 -0
- package/skills/make-figures/templates/official/prisma2020/PRISMA_2020_flow_new_v1.pptx +0 -0
- package/skills/make-figures/templates/official/prisma2020/PRISMA_2020_flow_new_v2.pptx +0 -0
- package/skills/make-figures/templates/official/prisma2020/PRISMA_2020_flow_updated_v2.pptx +0 -0
- package/skills/make-figures/templates/official/spirit2013/SPIRIT_2025_editable_checklist.docx +0 -0
- package/skills/make-figures/templates/official/spirit2013/SPIRIT_2025_participant_timeline.docx +0 -0
- package/skills/make-figures/templates/official/stard2015/STARD_2015_checklist.docx +0 -0
- package/skills/make-figures/templates/official/stard2015/STARD_2015_flow_diagram.pdf +0 -0
- package/skills/make-figures/tests/fixtures/figure1_flow.yaml +8 -0
- package/skills/make-figures/tests/fixtures/manuscript_ok.md +9 -0
- package/skills/make-figures/tests/fixtures/manuscript_stale.md +4 -0
- package/skills/make-figures/tests/test_legend_reconcile.sh +36 -0
- package/skills/manage-project/SKILL.md +358 -0
- package/skills/manage-project/references/pre_submission_checklist.md +53 -0
- package/skills/manage-project/references/project_state_template.json +37 -0
- package/skills/manage-project/references/scaffold_templates.md +118 -0
- package/skills/manage-project/references/status_output_format.md +44 -0
- package/skills/manage-project/references/timeline_example.md +20 -0
- package/skills/manage-project/skill.yml +36 -0
- package/skills/manage-project/templates/SSOT.yaml.template +41 -0
- package/skills/manage-refs/LICENSE.zotero-mcp +21 -0
- package/skills/manage-refs/NOTICE.md +29 -0
- package/skills/manage-refs/SKILL.md +289 -0
- package/skills/manage-refs/citation_styles/README.md +40 -0
- package/skills/manage-refs/citation_styles/american-journal-of-roentgenology.csl +211 -0
- package/skills/manage-refs/citation_styles/cardiovascular-and-interventional-radiology.csl +19 -0
- package/skills/manage-refs/citation_styles/european-radiology.csl +19 -0
- package/skills/manage-refs/citation_styles/journal-of-cachexia-sarcopenia-and-muscle.csl +150 -0
- package/skills/manage-refs/citation_styles/journal-of-korean-medical-science-strict.csl +533 -0
- package/skills/manage-refs/citation_styles/journal-of-korean-medical-science.csl +16 -0
- package/skills/manage-refs/citation_styles/korean-journal-of-radiology.csl +155 -0
- package/skills/manage-refs/citation_styles/nature.csl +189 -0
- package/skills/manage-refs/citation_styles/nlm-citation-sequence.csl +535 -0
- package/skills/manage-refs/citation_styles/radiology.csl +228 -0
- package/skills/manage-refs/citation_styles/springer-basic-brackets.csl +187 -0
- package/skills/manage-refs/citation_styles/springer-vancouver-brackets.csl +276 -0
- package/skills/manage-refs/citation_styles/vancouver-superscript.csl +536 -0
- package/skills/manage-refs/citation_styles/vancouver.csl +535 -0
- package/skills/manage-refs/references/REFERENCE_STYLE_SPECS.md +59 -0
- package/skills/manage-refs/references/check_xref_symptoms.md +35 -0
- package/skills/manage-refs/scripts/_vendor_citation_writer.py +600 -0
- package/skills/manage-refs/scripts/check_citation_keys.py +112 -0
- package/skills/manage-refs/scripts/check_csl_render.py +102 -0
- package/skills/manage-refs/scripts/check_xref.py +633 -0
- package/skills/manage-refs/scripts/fill_journal_abbrev.py +104 -0
- package/skills/manage-refs/scripts/inject_zotero_cwyw.py +133 -0
- package/skills/manage-refs/scripts/md_marker_convert.py +193 -0
- package/skills/manage-refs/scripts/pre_submission_gate.sh +238 -0
- package/skills/manage-refs/scripts/render_pandoc.sh +88 -0
- package/skills/manage-refs/skill.yml +70 -0
- package/skills/manage-refs/tests/fixtures/pre_submission_gate/README.md +32 -0
- package/skills/manage-refs/tests/fixtures/pre_submission_gate/manuscript.md +10 -0
- package/skills/manage-refs/tests/fixtures/pre_submission_gate/refs.bib +34 -0
- package/skills/manage-refs/tests/fixtures/pre_submission_gate/run.sh +117 -0
- package/skills/manage-refs/tests/test_vN_docx_check.sh +145 -0
- package/skills/meta-analysis/SKILL.md +739 -0
- package/skills/meta-analysis/references/LICENSES.md +21 -0
- package/skills/meta-analysis/references/PROSPERO_template.md +221 -0
- package/skills/meta-analysis/references/ai_pre_screening_template.py +245 -0
- package/skills/meta-analysis/references/checklists/JBI_Case_Series.md +45 -0
- package/skills/meta-analysis/references/checklists/NOS.md +88 -0
- package/skills/meta-analysis/references/checklists/PRISMA_DTA.md +36 -0
- package/skills/meta-analysis/references/checklists/PROBAST.md +75 -0
- package/skills/meta-analysis/references/checklists/QUADAS2.md +77 -0
- package/skills/meta-analysis/references/checklists/ROBINS_I.md +87 -0
- package/skills/meta-analysis/references/checklists/RoB2.md +79 -0
- package/skills/meta-analysis/references/data_integrity_checklist.md +57 -0
- package/skills/meta-analysis/references/icmje_coi_guide.md +181 -0
- package/skills/meta-analysis/references/phase10_recovery.md +136 -0
- package/skills/meta-analysis/references/phase4_km_composite.md +58 -0
- package/skills/meta-analysis/references/phase6_statistical_synthesis.md +148 -0
- package/skills/meta-analysis/references/phase9_circulation.md +84 -0
- package/skills/meta-analysis/references/post_submission_release_ops.md +41 -0
- package/skills/meta-analysis/references/r_templates.md +132 -0
- package/skills/meta-analysis/references/review_orchestration.md +40 -0
- package/skills/meta-analysis/references/submission_package_drift.md +71 -0
- package/skills/meta-analysis/scripts/check_pool_consistency.py +201 -0
- package/skills/meta-analysis/scripts/cohort_overlap_check.py +242 -0
- package/skills/meta-analysis/scripts/dta_extraction_qc.py +137 -0
- package/skills/meta-analysis/scripts/screening_reconcile.py +160 -0
- package/skills/meta-analysis/skill.yml +47 -0
- package/skills/meta-analysis/templates/FINAL_POOL_LOCK.yaml.template +70 -0
- package/skills/meta-analysis/templates/extraction_form_v2.md +129 -0
- package/skills/meta-analysis/templates/supplementary_8file_checklist.md +94 -0
- package/skills/meta-analysis/tests/test_pool_consistency.sh +123 -0
- package/skills/orchestrate/SKILL.md +501 -0
- package/skills/orchestrate/references/dialogue_nodes.md +196 -0
- package/skills/orchestrate/references/report_template.md +109 -0
- package/skills/orchestrate/references/report_template_ko.md +88 -0
- package/skills/orchestrate/skill.yml +44 -0
- package/skills/peer-review/SKILL.md +381 -0
- package/skills/peer-review/references/aczel_2021_reviewer2_patterns.md +88 -0
- package/skills/peer-review/references/domain-probes/ai_overclaiming.md +47 -0
- package/skills/peer-review/references/domain-probes/narrative_review.md +44 -0
- package/skills/peer-review/references/domain-probes/observational_confounding.md +48 -0
- package/skills/peer-review/references/domain-probes/radiomics.md +38 -0
- package/skills/peer-review/references/domain-probes/sr_ma.md +87 -0
- package/skills/peer-review/references/domain-probes/survival_prognostic.md +68 -0
- package/skills/peer-review/references/exemplar_reviews/README.md +43 -0
- package/skills/peer-review/references/exemplar_reviews/ai_overclaiming.md +47 -0
- package/skills/peer-review/references/exemplar_reviews/calibration_missing.md +44 -0
- package/skills/peer-review/references/exemplar_reviews/data_leakage.md +48 -0
- package/skills/peer-review/references/exemplar_reviews/reference_standard_validity.md +45 -0
- package/skills/peer-review/references/narrative_review_audit.md +67 -0
- package/skills/peer-review/references/reviewer_calibration/README.md +34 -0
- package/skills/peer-review/references/reviewer_calibration/compliance_floor.md +52 -0
- package/skills/peer-review/references/reviewer_profiles/AJR.md +82 -0
- package/skills/peer-review/references/reviewer_profiles/EURE.md +64 -0
- package/skills/peer-review/references/reviewer_profiles/INSI.md +57 -0
- package/skills/peer-review/references/reviewer_profiles/KJR.md +100 -0
- package/skills/peer-review/references/reviewer_profiles/README.md +32 -0
- package/skills/peer-review/references/reviewer_profiles/RYAI.md +86 -0
- package/skills/peer-review/skill.yml +39 -0
- package/skills/present-paper/SKILL.md +675 -0
- package/skills/present-paper/references/critic_rubrics/slide.md +155 -0
- package/skills/present-paper/references/generate_pptx_templates.py +604 -0
- package/skills/present-paper/references/medical_presentation_templates.md +277 -0
- package/skills/present-paper/references/slide_design_principles.md +202 -0
- package/skills/present-paper/references/slide_visual_styles/nature_lancet.md +168 -0
- package/skills/present-paper/references/workflow-checklist.md +109 -0
- package/skills/present-paper/scripts/extract_pdf_figures.py +243 -0
- package/skills/present-paper/scripts/inject_pronunciation_notes.py +178 -0
- package/skills/present-paper/scripts/inject_speaker_notes.py +133 -0
- package/skills/present-paper/scripts/strip_notes_for_sharing.py +140 -0
- package/skills/present-paper/scripts/trim_caption.py +271 -0
- package/skills/present-paper/skill.yml +41 -0
- package/skills/present-paper/templates/build_pptx_nature_lancet.py +688 -0
- package/skills/publish-skill/SKILL.md +370 -0
- package/skills/publish-skill/references/license-compatibility-matrix.md +132 -0
- package/skills/publish-skill/references/pii-patterns.md +130 -0
- package/skills/publish-skill/scripts/audit_skill.sh +278 -0
- package/skills/publish-skill/skill.yml +35 -0
- package/skills/render-pdf-doc/SKILL.md +146 -0
- package/skills/render-pdf-doc/references/known_pitfalls.md +53 -0
- package/skills/render-pdf-doc/references/pandoc_korean_cheatsheet.md +77 -0
- package/skills/render-pdf-doc/scripts/check_deps.sh +42 -0
- package/skills/render-pdf-doc/scripts/infer_colwidths.py +164 -0
- package/skills/render-pdf-doc/scripts/render_pdf.sh +98 -0
- package/skills/render-pdf-doc/skill.yml +57 -0
- package/skills/render-pdf-doc/templates/anchor-doc.md +27 -0
- package/skills/render-pdf-doc/templates/anchor-doc_ko.md +25 -0
- package/skills/render-pdf-doc/templates/briefing-handout.md +33 -0
- package/skills/render-pdf-doc/templates/briefing-handout_ko.md +31 -0
- package/skills/render-pdf-doc/templates/proposal-cover.md +33 -0
- package/skills/render-pdf-doc/templates/proposal-cover_ko.md +31 -0
- package/skills/render-pdf-doc/templates/reference-table.md +22 -0
- package/skills/render-pdf-doc/templates/reference-table_ko.md +20 -0
- package/skills/replicate-study/SKILL.md +150 -0
- package/skills/replicate-study/references/harmonization_3country.csv +47 -0
- package/skills/replicate-study/references/harmonization_knhanes_nhanes.csv +68 -0
- package/skills/replicate-study/references/methodology_extraction_template.md +134 -0
- package/skills/replicate-study/skill.yml +37 -0
- package/skills/review-paper/SKILL.md +104 -0
- package/skills/review-paper/references/macro_skeleton.md +6 -0
- package/skills/review-paper/skill.yml +25 -0
- package/skills/revise/SKILL.md +515 -0
- package/skills/revise/references/r2r_voice.md +346 -0
- package/skills/revise/skill.yml +43 -0
- package/skills/search-lit/SKILL.md +443 -0
- package/skills/search-lit/references/parse_pubmed.py +326 -0
- package/skills/search-lit/references/pubmed_eutils.sh +111 -0
- package/skills/search-lit/skill.yml +46 -0
- package/skills/self-review/SKILL.md +1045 -0
- package/skills/self-review/references/domain-probes/ai_overclaiming.md +47 -0
- package/skills/self-review/references/domain-probes/narrative_review.md +44 -0
- package/skills/self-review/references/domain-probes/observational_confounding.md +48 -0
- package/skills/self-review/references/domain-probes/radiomics.md +38 -0
- package/skills/self-review/references/domain-probes/sr_ma.md +87 -0
- package/skills/self-review/references/domain-probes/survival_prognostic.md +68 -0
- package/skills/self-review/references/exemplar_findings/README.md +43 -0
- package/skills/self-review/references/exemplar_findings/cohort_arithmetic_mismatch.md +35 -0
- package/skills/self-review/references/exemplar_findings/estimand_drift_posthoc_primary.md +39 -0
- package/skills/self-review/references/exemplar_findings/scope_overreach_cross_sectional.md +35 -0
- package/skills/self-review/references/exemplar_findings/unadjusted_confounder.md +36 -0
- package/skills/self-review/references/panel_review_template.md +177 -0
- package/skills/self-review/scripts/check_artifact_coverage.py +301 -0
- package/skills/self-review/scripts/check_claim_artifact.py +248 -0
- package/skills/self-review/scripts/check_classical_style.py +185 -0
- package/skills/self-review/scripts/check_cohort_arithmetic.py +481 -0
- package/skills/self-review/scripts/check_confounding_completeness.py +287 -0
- package/skills/self-review/scripts/check_panel_diversity.py +336 -0
- package/skills/self-review/scripts/check_reference_adequacy.py +392 -0
- package/skills/self-review/scripts/check_reviewer_team_consistency.py +412 -0
- package/skills/self-review/scripts/check_scope_coherence.py +177 -0
- package/skills/self-review/skill.yml +47 -0
- package/skills/self-review/tests/fixtures/claim_manuscript.md +17 -0
- package/skills/self-review/tests/fixtures/claim_prereg.md +6 -0
- package/skills/self-review/tests/fixtures/cohort_bad.md +21 -0
- package/skills/self-review/tests/fixtures/cohort_clean.md +21 -0
- package/skills/self-review/tests/fixtures/cohort_partition.csv +5 -0
- package/skills/self-review/tests/fixtures/coverage_analysis/31_delong_nested_added_value.csv +3 -0
- package/skills/self-review/tests/fixtures/coverage_analysis/table1_demographics.csv +3 -0
- package/skills/self-review/tests/fixtures/coverage_clean.md +13 -0
- package/skills/self-review/tests/fixtures/coverage_manuscript.md +11 -0
- package/skills/self-review/tests/fixtures/panel_collapse.json +27 -0
- package/skills/self-review/tests/fixtures/panel_good.json +32 -0
- package/skills/self-review/tests/fixtures/panel_monoculture.json +32 -0
- package/skills/self-review/tests/fixtures/refadeq_letter.md +13 -0
- package/skills/self-review/tests/fixtures/refadeq_original_fixed.md +42 -0
- package/skills/self-review/tests/fixtures/refadeq_original_uncited.md +40 -0
- package/skills/self-review/tests/fixtures/scope_bad.md +9 -0
- package/skills/self-review/tests/fixtures/scope_clean.md +8 -0
- package/skills/self-review/tests/fixtures/scope_surrogate.md +8 -0
- package/skills/self-review/tests/fixtures/style_bad.md +13 -0
- package/skills/self-review/tests/fixtures/style_clean.md +11 -0
- package/skills/self-review/tests/fixtures/table1_by_exposure.csv +11 -0
- package/skills/self-review/tests/test_artifact_coverage.sh +44 -0
- package/skills/self-review/tests/test_claim_artifact.sh +50 -0
- package/skills/self-review/tests/test_classical_style.sh +44 -0
- package/skills/self-review/tests/test_cohort_arithmetic.sh +49 -0
- package/skills/self-review/tests/test_confounding_completeness.sh +66 -0
- package/skills/self-review/tests/test_panel_diversity.sh +55 -0
- package/skills/self-review/tests/test_panel_mode.sh +69 -0
- package/skills/self-review/tests/test_reference_adequacy.sh +68 -0
- package/skills/self-review/tests/test_reviewer_team_consistency.sh +138 -0
- package/skills/self-review/tests/test_scope_coherence.sh +46 -0
- package/skills/setup-medsci/SKILL.md +110 -0
- package/skills/setup-medsci/references/setup-checklist.md +51 -0
- package/skills/setup-medsci/skill.yml +30 -0
- package/skills/sync-submission/SKILL.md +382 -0
- package/skills/sync-submission/scripts/author_registry_example.yaml +36 -0
- package/skills/sync-submission/scripts/blind_sweep.py +203 -0
- package/skills/sync-submission/scripts/check_asset_anonymization.py +300 -0
- package/skills/sync-submission/scripts/check_cross_artifact_stale.py +211 -0
- package/skills/sync-submission/scripts/cover_letter_drift_check.py +451 -0
- package/skills/sync-submission/scripts/cross_document_n_check.py +486 -0
- package/skills/sync-submission/scripts/detect_copy_divergence.py +136 -0
- package/skills/sync-submission/scripts/preflight_gate.py +458 -0
- package/skills/sync-submission/scripts/scope_drift_check.py +362 -0
- package/skills/sync-submission/scripts/sync_submission.py +169 -0
- package/skills/sync-submission/skill.yml +43 -0
- package/skills/sync-submission/tests/fixtures/copy_ok.md +5 -0
- package/skills/sync-submission/tests/fixtures/copy_stale.md +5 -0
- package/skills/sync-submission/tests/fixtures/ssot.md +5 -0
- package/skills/sync-submission/tests/test_asset_anonymization.sh +99 -0
- package/skills/sync-submission/tests/test_copy_divergence.sh +44 -0
- package/skills/sync-submission/tests/test_cross_artifact_stale.sh +80 -0
- package/skills/sync-submission/tests/test_cross_document_n.sh +132 -0
- package/skills/sync-submission/tests/test_preflight_gate.sh +112 -0
- package/skills/sync-submission/tests/test_scope_drift.sh +122 -0
- package/skills/sync-submission/tests/test_vN_docx_assertion.sh +51 -0
- package/skills/verify-refs/SKILL.md +177 -0
- package/skills/verify-refs/references/manual_checkpoint_guide.md +100 -0
- package/skills/verify-refs/scripts/verify_cli.sh +62 -0
- package/skills/verify-refs/scripts/verify_refs.py +782 -0
- package/skills/verify-refs/skill.yml +44 -0
- package/skills/verify-refs/tests/fixtures/pagination_placeholder.bib +17 -0
- package/skills/verify-refs/tests/test_pagination_placeholder.sh +42 -0
- package/skills/version-dataset/SKILL.md +143 -0
- package/skills/version-dataset/references/manifest_schema.md +72 -0
- package/skills/version-dataset/scripts/version_dataset.py +242 -0
- package/skills/version-dataset/skill.yml +35 -0
- package/skills/version-dataset/tests/test_version_dataset.sh +52 -0
- package/skills/write-paper/SKILL.md +1148 -0
- package/skills/write-paper/references/exemplar_methods/README.md +38 -0
- package/skills/write-paper/references/exemplar_methods/ai_validation_tripod_claim.md +47 -0
- package/skills/write-paper/references/exemplar_methods/diagnostic_accuracy_stard.md +50 -0
- package/skills/write-paper/references/exemplar_methods/observational_cohort_strobe.md +43 -0
- package/skills/write-paper/references/journal_profiles/AJNR.md +185 -0
- package/skills/write-paper/references/journal_profiles/AJR.md +149 -0
- package/skills/write-paper/references/journal_profiles/Abdominal_Radiology.md +139 -0
- package/skills/write-paper/references/journal_profiles/Academic_Radiology.md +90 -0
- package/skills/write-paper/references/journal_profiles/Annals_of_Internal_Medicine.md +150 -0
- package/skills/write-paper/references/journal_profiles/Artificial_Intelligence_in_Medicine.md +82 -0
- package/skills/write-paper/references/journal_profiles/British_Journal_of_Radiology.md +161 -0
- package/skills/write-paper/references/journal_profiles/CVIR.md +157 -0
- package/skills/write-paper/references/journal_profiles/Chest.md +270 -0
- package/skills/write-paper/references/journal_profiles/Clinical_Radiology.md +160 -0
- package/skills/write-paper/references/journal_profiles/Clinical_and_Molecular_Hepatology.md +147 -0
- package/skills/write-paper/references/journal_profiles/Diabetes_Metabolism_Journal.md +163 -0
- package/skills/write-paper/references/journal_profiles/Diagnostic_and_Interventional_Radiology.md +216 -0
- package/skills/write-paper/references/journal_profiles/Endocrinology_and_Metabolism.md +167 -0
- package/skills/write-paper/references/journal_profiles/European_Journal_of_Preventive_Cardiology.md +192 -0
- package/skills/write-paper/references/journal_profiles/European_Radiology.md +159 -0
- package/skills/write-paper/references/journal_profiles/Hepatology_Communications.md +110 -0
- package/skills/write-paper/references/journal_profiles/Hepatology_International.md +106 -0
- package/skills/write-paper/references/journal_profiles/IEEE_TMI.md +180 -0
- package/skills/write-paper/references/journal_profiles/INSI.md +163 -0
- package/skills/write-paper/references/journal_profiles/Investigative_Radiology.md +86 -0
- package/skills/write-paper/references/journal_profiles/JACC_Advances.md +197 -0
- package/skills/write-paper/references/journal_profiles/JACC_Asia.md +168 -0
- package/skills/write-paper/references/journal_profiles/JACR.md +87 -0
- package/skills/write-paper/references/journal_profiles/JAMA.md +188 -0
- package/skills/write-paper/references/journal_profiles/JAMA_Network_Open.md +170 -0
- package/skills/write-paper/references/journal_profiles/JCSM.md +266 -0
- package/skills/write-paper/references/journal_profiles/JKMS.md +201 -0
- package/skills/write-paper/references/journal_profiles/JMIR.md +88 -0
- package/skills/write-paper/references/journal_profiles/JMIR_Medical_Education.md +86 -0
- package/skills/write-paper/references/journal_profiles/JNIS.md +227 -0
- package/skills/write-paper/references/journal_profiles/JVIR.md +158 -0
- package/skills/write-paper/references/journal_profiles/Journal_of_Clinical_Endocrinology_and_Metabolism.md +191 -0
- package/skills/write-paper/references/journal_profiles/Journal_of_Stroke.md +176 -0
- package/skills/write-paper/references/journal_profiles/KJR.md +185 -0
- package/skills/write-paper/references/journal_profiles/Korean_Circulation_Journal.md +184 -0
- package/skills/write-paper/references/journal_profiles/Korean_Journal_of_Internal_Medicine.md +178 -0
- package/skills/write-paper/references/journal_profiles/Lancet_Gastroenterology_and_Hepatology.md +127 -0
- package/skills/write-paper/references/journal_profiles/Liver_International.md +165 -0
- package/skills/write-paper/references/journal_profiles/Medical_Image_Analysis.md +147 -0
- package/skills/write-paper/references/journal_profiles/NEJM.md +147 -0
- package/skills/write-paper/references/journal_profiles/Nature_Medicine.md +181 -0
- package/skills/write-paper/references/journal_profiles/Neuroradiology.md +151 -0
- package/skills/write-paper/references/journal_profiles/Nutrition_Metabolism_and_Cardiovascular_Diseases.md +184 -0
- package/skills/write-paper/references/journal_profiles/PLOS_Medicine.md +166 -0
- package/skills/write-paper/references/journal_profiles/RYAI.md +124 -0
- package/skills/write-paper/references/journal_profiles/Radiology.md +173 -0
- package/skills/write-paper/references/journal_profiles/Skeletal_Radiology.md +135 -0
- package/skills/write-paper/references/journal_profiles/Stroke.md +210 -0
- package/skills/write-paper/references/journal_profiles/The_BMJ.md +121 -0
- package/skills/write-paper/references/journal_profiles/The_Lancet.md +112 -0
- package/skills/write-paper/references/journal_profiles/The_Lancet_Digital_Health.md +104 -0
- package/skills/write-paper/references/journal_profiles/World_Journal_of_Hepatology.md +106 -0
- package/skills/write-paper/references/journal_profiles/npj_Digital_Medicine.md +93 -0
- package/skills/write-paper/references/paper_types/ai_validation.md +270 -0
- package/skills/write-paper/references/paper_types/animal_study.md +194 -0
- package/skills/write-paper/references/paper_types/case_report.md +237 -0
- package/skills/write-paper/references/paper_types/cross_national.md +328 -0
- package/skills/write-paper/references/paper_types/letter.md +127 -0
- package/skills/write-paper/references/paper_types/meta_analysis.md +181 -0
- package/skills/write-paper/references/paper_types/nhis_cohort.md +297 -0
- package/skills/write-paper/references/paper_types/original_article.md +221 -0
- package/skills/write-paper/references/paper_types/technical_note.md +131 -0
- package/skills/write-paper/references/section_guides/discussion.md +155 -0
- package/skills/write-paper/references/section_guides/introduction.md +108 -0
- package/skills/write-paper/references/section_guides/methods.md +144 -0
- package/skills/write-paper/references/section_guides/results.md +113 -0
- package/skills/write-paper/references/section_guides/step7_1_classical_qc.md +67 -0
- package/skills/write-paper/references/section_guides/step7_4a_audit_recovery.md +74 -0
- package/skills/write-paper/references/section_guides/title_abstract.md +123 -0
- package/skills/write-paper/references/section_templates/methods_statistical.md +147 -0
- package/skills/write-paper/scripts/check_placeholders.py +182 -0
- package/skills/write-paper/skill.yml +48 -0
- package/skills/write-paper/tests/test_placeholders.sh +107 -0
- package/skills/write-protocol/SKILL.md +243 -0
- package/skills/write-protocol/references/ethics_checklist.md +150 -0
- package/skills/write-protocol/references/protocol_template.md +304 -0
- package/skills/write-protocol/skill.yml +34 -0
|
@@ -0,0 +1,655 @@
|
|
|
1
|
+
# Sample Size Formulas Reference
|
|
2
|
+
|
|
3
|
+
Mathematical formulas, R/Python implementations, and effect size conventions for all 10 supported tests.
|
|
4
|
+
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
## Test 1: Diagnostic Accuracy (Sensitivity/Specificity Precision)
|
|
8
|
+
|
|
9
|
+
### Formula
|
|
10
|
+
For estimating a single proportion p with desired 95% CI half-width w:
|
|
11
|
+
|
|
12
|
+
```
|
|
13
|
+
n_positive = ceil( (z_{alpha/2} / w)^2 * p * (1 - p) )
|
|
14
|
+
n_total = ceil( n_positive / prevalence )
|
|
15
|
+
```
|
|
16
|
+
|
|
17
|
+
Where:
|
|
18
|
+
- `z_{alpha/2}` = 1.96 for alpha = 0.05
|
|
19
|
+
- `p` = expected sensitivity (or specificity)
|
|
20
|
+
- `w` = desired CI half-width
|
|
21
|
+
- `prevalence` = disease prevalence in the study population
|
|
22
|
+
|
|
23
|
+
### R Implementation
|
|
24
|
+
```r
|
|
25
|
+
z <- qnorm(1 - alpha / 2)
|
|
26
|
+
n_pos <- ceiling((z / ci_half_width)^2 * se_expected * (1 - se_expected))
|
|
27
|
+
n_total <- ceiling(n_pos / prevalence)
|
|
28
|
+
n_adj <- ceiling(n_total / (1 - attrition_rate))
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
### Python Implementation
|
|
32
|
+
```python
|
|
33
|
+
from scipy.stats import norm
|
|
34
|
+
import math
|
|
35
|
+
|
|
36
|
+
z = norm.ppf(1 - alpha / 2)
|
|
37
|
+
n_pos = math.ceil((z / ci_half_width)**2 * se_expected * (1 - se_expected))
|
|
38
|
+
n_total = math.ceil(n_pos / prevalence)
|
|
39
|
+
n_adj = math.ceil(n_total / (1 - attrition_rate))
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
### R Package
|
|
43
|
+
Base R (no additional packages needed).
|
|
44
|
+
|
|
45
|
+
### Key Reference
|
|
46
|
+
Buderer NMF. Statistical methodology: I. Incorporating the prevalence of disease into the sample size calculation for sensitivity and specificity. Acad Emerg Med. 1996;3(9):895-900.
|
|
47
|
+
|
|
48
|
+
---
|
|
49
|
+
|
|
50
|
+
## Test 2: ICC Agreement (Bonett 2002)
|
|
51
|
+
|
|
52
|
+
### Formula
|
|
53
|
+
Fisher z-transformation approach:
|
|
54
|
+
|
|
55
|
+
```
|
|
56
|
+
z_1 = 0.5 * ln((1 + rho_1) / (1 - rho_1)) # expected ICC
|
|
57
|
+
z_0 = 0.5 * ln((1 + rho_0) / (1 - rho_0)) # null ICC
|
|
58
|
+
n = ceil( ((z_{alpha} + z_{beta}) / (z_1 - z_0))^2 + 3 )
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
Where:
|
|
62
|
+
- `rho_1` = expected ICC
|
|
63
|
+
- `rho_0` = null hypothesis ICC
|
|
64
|
+
- `z_{alpha}` = qnorm(1 - alpha) for one-sided, qnorm(1 - alpha/2) for two-sided
|
|
65
|
+
- `z_{beta}` = qnorm(power)
|
|
66
|
+
|
|
67
|
+
### R Implementation
|
|
68
|
+
```r
|
|
69
|
+
# Option A: MKpower package (preferred)
|
|
70
|
+
library(MKpower)
|
|
71
|
+
result <- sampleSize.ICC(rho0 = icc_null, rho1 = icc_expected,
|
|
72
|
+
k = n_raters, alpha = alpha, power = power)
|
|
73
|
+
n <- result$n
|
|
74
|
+
|
|
75
|
+
# Option B: Manual Fisher z (if MKpower unavailable)
|
|
76
|
+
z_exp <- 0.5 * log((1 + icc_expected) / (1 - icc_expected))
|
|
77
|
+
z_null <- 0.5 * log((1 + icc_null) / (1 - icc_null))
|
|
78
|
+
n <- ceiling(((qnorm(1 - alpha) + qnorm(power)) / (z_exp - z_null))^2 + 3)
|
|
79
|
+
```
|
|
80
|
+
|
|
81
|
+
### Python Implementation
|
|
82
|
+
```python
|
|
83
|
+
from scipy.stats import norm
|
|
84
|
+
import math
|
|
85
|
+
import numpy as np
|
|
86
|
+
|
|
87
|
+
z_exp = 0.5 * np.log((1 + icc_expected) / (1 - icc_expected))
|
|
88
|
+
z_null = 0.5 * np.log((1 + icc_null) / (1 - icc_null))
|
|
89
|
+
z_alpha = norm.ppf(1 - alpha)
|
|
90
|
+
z_beta = norm.ppf(power)
|
|
91
|
+
n = math.ceil(((z_alpha + z_beta) / (z_exp - z_null))**2 + 3)
|
|
92
|
+
```
|
|
93
|
+
|
|
94
|
+
### R Package
|
|
95
|
+
`MKpower` (preferred), or base R for manual calculation.
|
|
96
|
+
|
|
97
|
+
### Key Reference
|
|
98
|
+
Bonett DG. Sample size requirements for estimating intraclass correlations with desired precision. Stat Med. 2002;21(9):1331-1335.
|
|
99
|
+
|
|
100
|
+
---
|
|
101
|
+
|
|
102
|
+
## Test 3: Kappa Agreement (Donner & Eliasziw 1992)
|
|
103
|
+
|
|
104
|
+
### Formula
|
|
105
|
+
Z-test approximation for testing kappa_1 vs kappa_0:
|
|
106
|
+
|
|
107
|
+
```
|
|
108
|
+
n = ceil( ((z_{alpha/2} + z_{beta})^2 * kappa_1 * (1 - kappa_1)) / (kappa_1 - kappa_0)^2 + 1 )
|
|
109
|
+
```
|
|
110
|
+
|
|
111
|
+
Where:
|
|
112
|
+
- `kappa_1` = expected kappa
|
|
113
|
+
- `kappa_0` = null hypothesis kappa
|
|
114
|
+
- `pe` = expected chance agreement = (po - kappa) / (1 - kappa)
|
|
115
|
+
|
|
116
|
+
### R Implementation
|
|
117
|
+
```r
|
|
118
|
+
n_kappa <- ceiling(
|
|
119
|
+
((qnorm(1 - alpha / 2) + qnorm(power))^2 *
|
|
120
|
+
kappa_expected * (1 - kappa_expected)) /
|
|
121
|
+
(kappa_expected - kappa_null)^2 + 1
|
|
122
|
+
)
|
|
123
|
+
```
|
|
124
|
+
|
|
125
|
+
### Python Implementation
|
|
126
|
+
```python
|
|
127
|
+
from scipy.stats import norm
|
|
128
|
+
import math
|
|
129
|
+
|
|
130
|
+
z_a = norm.ppf(1 - alpha / 2)
|
|
131
|
+
z_b = norm.ppf(power)
|
|
132
|
+
n = math.ceil(((z_a + z_b)**2 * kappa_exp * (1 - kappa_exp)) /
|
|
133
|
+
(kappa_exp - kappa_null)**2 + 1)
|
|
134
|
+
```
|
|
135
|
+
|
|
136
|
+
### R Package
|
|
137
|
+
Base R. Also available via `kappaSize` package.
|
|
138
|
+
|
|
139
|
+
### Key Reference
|
|
140
|
+
Donner A, Eliasziw M. A goodness-of-fit approach to inference procedures for the kappa statistic: confidence interval construction, significance-testing and sample size estimation. Stat Med. 1992;11(11):1511-1519.
|
|
141
|
+
|
|
142
|
+
---
|
|
143
|
+
|
|
144
|
+
## Test 4: Two-Proportion Comparison (Chi-Square)
|
|
145
|
+
|
|
146
|
+
### Formula
|
|
147
|
+
Based on Cohen's h effect size (arcsine transformation):
|
|
148
|
+
|
|
149
|
+
```
|
|
150
|
+
h = 2 * arcsin(sqrt(p1)) - 2 * arcsin(sqrt(p2))
|
|
151
|
+
n_per_group = ceil( ((z_{alpha/2} + z_{beta}) / h)^2 )
|
|
152
|
+
```
|
|
153
|
+
|
|
154
|
+
### R Implementation
|
|
155
|
+
```r
|
|
156
|
+
library(pwr)
|
|
157
|
+
h <- ES.h(p1, p2)
|
|
158
|
+
result <- pwr.2p.test(h = h, sig.level = alpha, power = power)
|
|
159
|
+
n_per_group <- ceiling(result$n)
|
|
160
|
+
n_total <- n_per_group * 2
|
|
161
|
+
```
|
|
162
|
+
|
|
163
|
+
### Python Implementation
|
|
164
|
+
```python
|
|
165
|
+
from statsmodels.stats.power import NormalIndPower
|
|
166
|
+
import numpy as np
|
|
167
|
+
import math
|
|
168
|
+
|
|
169
|
+
h = 2 * np.arcsin(np.sqrt(p1)) - 2 * np.arcsin(np.sqrt(p2))
|
|
170
|
+
analysis = NormalIndPower()
|
|
171
|
+
n_per_group = math.ceil(analysis.solve_power(effect_size=h, alpha=alpha, power=power,
|
|
172
|
+
ratio=1, alternative='two-sided'))
|
|
173
|
+
n_total = n_per_group * 2
|
|
174
|
+
```
|
|
175
|
+
|
|
176
|
+
### R Package
|
|
177
|
+
`pwr`
|
|
178
|
+
|
|
179
|
+
### Key Reference
|
|
180
|
+
Cohen J. Statistical Power Analysis for the Behavioral Sciences. 2nd ed. Lawrence Erlbaum Associates; 1988.
|
|
181
|
+
|
|
182
|
+
---
|
|
183
|
+
|
|
184
|
+
## Test 5: McNemar Test (Paired Proportions)
|
|
185
|
+
|
|
186
|
+
### Formula
|
|
187
|
+
```
|
|
188
|
+
n = ceil(
|
|
189
|
+
(z_{alpha/2} * sqrt(p01 + p10) + z_{beta} * sqrt(p01 + p10 - (p10 - p01)^2))^2
|
|
190
|
+
/ (p10 - p01)^2
|
|
191
|
+
)
|
|
192
|
+
```
|
|
193
|
+
|
|
194
|
+
Where:
|
|
195
|
+
- `p01` = P(Method A negative, Method B positive)
|
|
196
|
+
- `p10` = P(Method A positive, Method B negative)
|
|
197
|
+
|
|
198
|
+
### R Implementation
|
|
199
|
+
```r
|
|
200
|
+
n_mc <- ceiling(
|
|
201
|
+
(qnorm(1 - alpha / 2) * sqrt(p01 + p10) +
|
|
202
|
+
qnorm(power) * sqrt(p01 + p10 - (p10 - p01)^2))^2 /
|
|
203
|
+
(p10 - p01)^2
|
|
204
|
+
)
|
|
205
|
+
```
|
|
206
|
+
|
|
207
|
+
### Python Implementation
|
|
208
|
+
```python
|
|
209
|
+
from scipy.stats import norm
|
|
210
|
+
import math
|
|
211
|
+
|
|
212
|
+
z_a = norm.ppf(1 - alpha / 2)
|
|
213
|
+
z_b = norm.ppf(power)
|
|
214
|
+
disc_sum = p01 + p10
|
|
215
|
+
disc_diff = p10 - p01
|
|
216
|
+
n = math.ceil((z_a * math.sqrt(disc_sum) +
|
|
217
|
+
z_b * math.sqrt(disc_sum - disc_diff**2))**2 / disc_diff**2)
|
|
218
|
+
```
|
|
219
|
+
|
|
220
|
+
### R Package
|
|
221
|
+
Base R. Also available via `exact2x2` package.
|
|
222
|
+
|
|
223
|
+
### Key Reference
|
|
224
|
+
Connor RJ. Sample size for testing differences in proportions for the paired-sample design. Biometrics. 1987;43(1):207-211.
|
|
225
|
+
|
|
226
|
+
---
|
|
227
|
+
|
|
228
|
+
## Test 6: Independent t-Test
|
|
229
|
+
|
|
230
|
+
### Formula
|
|
231
|
+
```
|
|
232
|
+
d = mean_diff / pooled_sd (Cohen's d)
|
|
233
|
+
n_per_group = ceil( 2 * ((z_{alpha/2} + z_{beta}) / d)^2 )
|
|
234
|
+
```
|
|
235
|
+
|
|
236
|
+
### R Implementation
|
|
237
|
+
```r
|
|
238
|
+
library(pwr)
|
|
239
|
+
d <- mean_diff / pooled_sd
|
|
240
|
+
result <- pwr.t.test(d = d, sig.level = alpha, power = power, type = "two.sample")
|
|
241
|
+
n_per_group <- ceiling(result$n)
|
|
242
|
+
n_total <- n_per_group * 2
|
|
243
|
+
```
|
|
244
|
+
|
|
245
|
+
### Python Implementation
|
|
246
|
+
```python
|
|
247
|
+
from statsmodels.stats.power import TTestIndPower
|
|
248
|
+
import math
|
|
249
|
+
|
|
250
|
+
d = mean_diff / pooled_sd
|
|
251
|
+
analysis = TTestIndPower()
|
|
252
|
+
n_per_group = math.ceil(analysis.solve_power(effect_size=d, alpha=alpha, power=power,
|
|
253
|
+
ratio=1, alternative='two-sided'))
|
|
254
|
+
n_total = n_per_group * 2
|
|
255
|
+
```
|
|
256
|
+
|
|
257
|
+
### R Package
|
|
258
|
+
`pwr`
|
|
259
|
+
|
|
260
|
+
### Key Reference
|
|
261
|
+
Cohen J. Statistical Power Analysis for the Behavioral Sciences. 2nd ed. Lawrence Erlbaum Associates; 1988.
|
|
262
|
+
|
|
263
|
+
---
|
|
264
|
+
|
|
265
|
+
## Test 7: Survival / Log-Rank Test (Schoenfeld 1981)
|
|
266
|
+
|
|
267
|
+
### Formula
|
|
268
|
+
Step 1 -- Required number of events:
|
|
269
|
+
```
|
|
270
|
+
d = ceil( ((z_{alpha/2} + z_{beta}) / ln(HR))^2 )
|
|
271
|
+
```
|
|
272
|
+
|
|
273
|
+
Step 2 -- Total sample size:
|
|
274
|
+
```
|
|
275
|
+
lambda_ctrl = ln(2) / median_ctrl
|
|
276
|
+
lambda_trt = lambda_ctrl * HR
|
|
277
|
+
p_event_ctrl = 1 - exp(-lambda_ctrl * follow_up)
|
|
278
|
+
p_event_trt = 1 - exp(-lambda_trt * follow_up)
|
|
279
|
+
avg_p_event = (p_event_ctrl + p_event_trt) / 2
|
|
280
|
+
n_total = ceil( d / avg_p_event )
|
|
281
|
+
```
|
|
282
|
+
|
|
283
|
+
### R Implementation
|
|
284
|
+
```r
|
|
285
|
+
n_events <- ceiling((qnorm(1 - alpha / 2) + qnorm(power))^2 / (log(hr))^2)
|
|
286
|
+
lambda_ctrl <- log(2) / median_ctrl
|
|
287
|
+
lambda_trt <- lambda_ctrl * hr
|
|
288
|
+
p_event_ctrl <- 1 - exp(-lambda_ctrl * follow_up)
|
|
289
|
+
p_event_trt <- 1 - exp(-lambda_trt * follow_up)
|
|
290
|
+
avg_p_event <- (p_event_ctrl + p_event_trt) / 2
|
|
291
|
+
n_total <- ceiling(n_events / avg_p_event)
|
|
292
|
+
n_adj <- ceiling(n_total / (1 - drop_rate))
|
|
293
|
+
```
|
|
294
|
+
|
|
295
|
+
### Python Implementation
|
|
296
|
+
```python
|
|
297
|
+
from scipy.stats import norm
|
|
298
|
+
import math
|
|
299
|
+
import numpy as np
|
|
300
|
+
|
|
301
|
+
z_a = norm.ppf(1 - alpha / 2)
|
|
302
|
+
z_b = norm.ppf(power)
|
|
303
|
+
n_events = math.ceil((z_a + z_b)**2 / np.log(hr)**2)
|
|
304
|
+
lambda_ctrl = np.log(2) / median_ctrl
|
|
305
|
+
lambda_trt = lambda_ctrl * hr
|
|
306
|
+
p_event_ctrl = 1 - np.exp(-lambda_ctrl * follow_up)
|
|
307
|
+
p_event_trt = 1 - np.exp(-lambda_trt * follow_up)
|
|
308
|
+
avg_p_event = (p_event_ctrl + p_event_trt) / 2
|
|
309
|
+
n_total = math.ceil(n_events / avg_p_event)
|
|
310
|
+
n_adj = math.ceil(n_total / (1 - drop_rate))
|
|
311
|
+
```
|
|
312
|
+
|
|
313
|
+
### R Package
|
|
314
|
+
Base R. Also available via `gsDesign`, `survival` packages.
|
|
315
|
+
|
|
316
|
+
### Key Reference
|
|
317
|
+
Schoenfeld DA. The asymptotic properties of nonparametric tests for comparing survival distributions. Biometrika. 1981;68(1):316-319.
|
|
318
|
+
|
|
319
|
+
---
|
|
320
|
+
|
|
321
|
+
## Test 8: One-Way ANOVA
|
|
322
|
+
|
|
323
|
+
### Formula
|
|
324
|
+
Using Cohen's f effect size:
|
|
325
|
+
|
|
326
|
+
```
|
|
327
|
+
f = sigma_between / sigma_within
|
|
328
|
+
```
|
|
329
|
+
|
|
330
|
+
Where:
|
|
331
|
+
- `sigma_between` = SD of group means
|
|
332
|
+
- `sigma_within` = pooled within-group SD
|
|
333
|
+
|
|
334
|
+
From eta-squared: `f = sqrt(eta_sq / (1 - eta_sq))`
|
|
335
|
+
|
|
336
|
+
The sample size per group is obtained via the F-test power formula (implemented in `pwr`).
|
|
337
|
+
|
|
338
|
+
### R Implementation
|
|
339
|
+
```r
|
|
340
|
+
library(pwr)
|
|
341
|
+
result <- pwr.anova.test(k = k, f = f, sig.level = alpha, power = power)
|
|
342
|
+
n_per_group <- ceiling(result$n)
|
|
343
|
+
n_total <- n_per_group * k
|
|
344
|
+
n_adj <- ceiling(n_total / (1 - attrition_rate))
|
|
345
|
+
```
|
|
346
|
+
|
|
347
|
+
### Python Implementation
|
|
348
|
+
```python
|
|
349
|
+
from statsmodels.stats.power import FTestAnovaPower
|
|
350
|
+
import math
|
|
351
|
+
|
|
352
|
+
analysis = FTestAnovaPower()
|
|
353
|
+
n_per_group = math.ceil(analysis.solve_power(effect_size=f, nobs=None, alpha=alpha,
|
|
354
|
+
power=power, k_groups=k))
|
|
355
|
+
n_total = n_per_group * k
|
|
356
|
+
n_adj = math.ceil(n_total / (1 - attrition_rate))
|
|
357
|
+
```
|
|
358
|
+
|
|
359
|
+
### R Package
|
|
360
|
+
`pwr`
|
|
361
|
+
|
|
362
|
+
### Key Reference
|
|
363
|
+
Cohen J. Statistical Power Analysis for the Behavioral Sciences. 2nd ed. Lawrence Erlbaum Associates; 1988. (Chapter 8: F tests for ANOVA)
|
|
364
|
+
|
|
365
|
+
---
|
|
366
|
+
|
|
367
|
+
## Test 9: Logistic Regression
|
|
368
|
+
|
|
369
|
+
### Approach A: Peduzzi Rule of Thumb (EPV >= 10)
|
|
370
|
+
|
|
371
|
+
```
|
|
372
|
+
N_events = 10 * p (where p = number of predictor variables)
|
|
373
|
+
N_total = N_events / event_rate
|
|
374
|
+
```
|
|
375
|
+
|
|
376
|
+
This ensures at least 10 events per predictor variable (EPV), the widely accepted minimum for stable logistic regression estimates.
|
|
377
|
+
|
|
378
|
+
### Approach B: Hsieh (1989) Formula
|
|
379
|
+
|
|
380
|
+
For detecting a specific odds ratio (OR) for a continuous or binary predictor:
|
|
381
|
+
|
|
382
|
+
```
|
|
383
|
+
# For a binary predictor (proportion B exposed):
|
|
384
|
+
n_unadj = ((z_{alpha/2} + z_{beta})^2) / (B * (1-B) * ln(OR)^2)
|
|
385
|
+
|
|
386
|
+
# Adjusted for correlation with other predictors:
|
|
387
|
+
n_adj = n_unadj / (1 - R^2)
|
|
388
|
+
```
|
|
389
|
+
|
|
390
|
+
Where:
|
|
391
|
+
- `OR` = odds ratio of interest
|
|
392
|
+
- `B` = proportion of subjects exposed (for binary predictor) or use p*(1-p) for the outcome
|
|
393
|
+
- `R^2` = multiple correlation of the predictor with other covariates
|
|
394
|
+
|
|
395
|
+
For a continuous predictor, the formula uses the standard normal density.
|
|
396
|
+
|
|
397
|
+
### R Implementation
|
|
398
|
+
```r
|
|
399
|
+
# Approach A: Peduzzi
|
|
400
|
+
n_events_peduzzi <- 10 * n_predictors
|
|
401
|
+
n_total_peduzzi <- ceiling(n_events_peduzzi / event_rate)
|
|
402
|
+
|
|
403
|
+
# Approach B: Hsieh (binary predictor)
|
|
404
|
+
z_a <- qnorm(1 - alpha / 2)
|
|
405
|
+
z_b <- qnorm(power)
|
|
406
|
+
n_hsieh <- ceiling((z_a + z_b)^2 /
|
|
407
|
+
(event_rate * (1 - event_rate) * log(or_interest)^2))
|
|
408
|
+
n_hsieh_adj <- ceiling(n_hsieh / (1 - r2_other))
|
|
409
|
+
|
|
410
|
+
# Report the larger of the two
|
|
411
|
+
n_final <- max(n_total_peduzzi, n_hsieh_adj)
|
|
412
|
+
```
|
|
413
|
+
|
|
414
|
+
### Python Implementation
|
|
415
|
+
```python
|
|
416
|
+
from scipy.stats import norm
|
|
417
|
+
import math
|
|
418
|
+
import numpy as np
|
|
419
|
+
|
|
420
|
+
# Approach A: Peduzzi
|
|
421
|
+
n_events_peduzzi = 10 * n_predictors
|
|
422
|
+
n_total_peduzzi = math.ceil(n_events_peduzzi / event_rate)
|
|
423
|
+
|
|
424
|
+
# Approach B: Hsieh (binary predictor)
|
|
425
|
+
z_a = norm.ppf(1 - alpha / 2)
|
|
426
|
+
z_b = norm.ppf(power)
|
|
427
|
+
n_hsieh = math.ceil((z_a + z_b)**2 /
|
|
428
|
+
(event_rate * (1 - event_rate) * np.log(or_interest)**2))
|
|
429
|
+
n_hsieh_adj = math.ceil(n_hsieh / (1 - r2_other))
|
|
430
|
+
|
|
431
|
+
n_final = max(n_total_peduzzi, n_hsieh_adj)
|
|
432
|
+
```
|
|
433
|
+
|
|
434
|
+
### R Package
|
|
435
|
+
Base R. Also see `powerMediation` package for Hsieh's formula.
|
|
436
|
+
|
|
437
|
+
### Key References
|
|
438
|
+
- Peduzzi P, Concato J, Kemper E, Holford TR, Feinstein AR. A simulation study of the number of events per variable in logistic regression analysis. J Clin Epidemiol. 1996;49(12):1373-1379.
|
|
439
|
+
- Hsieh FY. Sample size tables for logistic regression. Stat Med. 1989;8(7):795-802.
|
|
440
|
+
|
|
441
|
+
---
|
|
442
|
+
|
|
443
|
+
## Test 10: Non-Inferiority / Equivalence
|
|
444
|
+
|
|
445
|
+
### Non-Inferiority (Proportions)
|
|
446
|
+
|
|
447
|
+
```
|
|
448
|
+
n_per_group = ceil(
|
|
449
|
+
((z_{1-alpha} + z_{beta})^2 * (p_ref*(1-p_ref) + p_new*(1-p_new))) /
|
|
450
|
+
(margin - |p_new - p_ref|)^2
|
|
451
|
+
)
|
|
452
|
+
```
|
|
453
|
+
|
|
454
|
+
When assuming p_new = p_ref (no true difference):
|
|
455
|
+
```
|
|
456
|
+
n_per_group = ceil( ((z_{1-alpha} + z_{beta})^2 * 2 * p*(1-p)) / margin^2 )
|
|
457
|
+
```
|
|
458
|
+
|
|
459
|
+
Note: alpha is one-sided (typically 0.025) for non-inferiority.
|
|
460
|
+
|
|
461
|
+
### Non-Inferiority (Continuous)
|
|
462
|
+
|
|
463
|
+
```
|
|
464
|
+
n_per_group = ceil( ((z_{1-alpha} + z_{beta})^2 * 2 * sd^2) / margin^2 )
|
|
465
|
+
```
|
|
466
|
+
|
|
467
|
+
### Equivalence / TOST (Proportions)
|
|
468
|
+
|
|
469
|
+
```
|
|
470
|
+
n_per_group = ceil(
|
|
471
|
+
((z_{1-alpha/2} + z_{beta})^2 * 2 * p*(1-p)) / margin^2
|
|
472
|
+
)
|
|
473
|
+
```
|
|
474
|
+
|
|
475
|
+
Note: For TOST, each one-sided test uses alpha (e.g., alpha = 0.05 for overall 5% type I error).
|
|
476
|
+
|
|
477
|
+
### Equivalence / TOST (Continuous)
|
|
478
|
+
|
|
479
|
+
```
|
|
480
|
+
n_per_group = ceil( ((z_{1-alpha} + z_{beta})^2 * 2 * sd^2) / margin^2 )
|
|
481
|
+
```
|
|
482
|
+
|
|
483
|
+
### R Implementation
|
|
484
|
+
```r
|
|
485
|
+
# Non-inferiority for proportions (assuming no true difference)
|
|
486
|
+
z_a <- qnorm(1 - alpha) # one-sided, alpha = 0.025
|
|
487
|
+
z_b <- qnorm(power)
|
|
488
|
+
p <- p_reference
|
|
489
|
+
n_per_group <- ceiling(((z_a + z_b)^2 * 2 * p * (1 - p)) / margin^2)
|
|
490
|
+
n_total <- n_per_group * 2
|
|
491
|
+
|
|
492
|
+
# Non-inferiority for continuous
|
|
493
|
+
n_per_group <- ceiling(((z_a + z_b)^2 * 2 * sd^2) / margin^2)
|
|
494
|
+
n_total <- n_per_group * 2
|
|
495
|
+
|
|
496
|
+
# Equivalence / TOST for continuous
|
|
497
|
+
n_per_group <- ceiling(((z_a + z_b)^2 * 2 * sd^2) / margin^2)
|
|
498
|
+
n_total <- n_per_group * 2
|
|
499
|
+
|
|
500
|
+
n_adj <- ceiling(n_total / (1 - attrition_rate))
|
|
501
|
+
```
|
|
502
|
+
|
|
503
|
+
### Python Implementation
|
|
504
|
+
```python
|
|
505
|
+
from scipy.stats import norm
|
|
506
|
+
import math
|
|
507
|
+
|
|
508
|
+
# Non-inferiority for proportions (assuming no true difference)
|
|
509
|
+
z_a = norm.ppf(1 - alpha) # one-sided, alpha = 0.025
|
|
510
|
+
z_b = norm.ppf(power)
|
|
511
|
+
p = p_reference
|
|
512
|
+
n_per_group = math.ceil(((z_a + z_b)**2 * 2 * p * (1 - p)) / margin**2)
|
|
513
|
+
n_total = n_per_group * 2
|
|
514
|
+
|
|
515
|
+
# Non-inferiority for continuous
|
|
516
|
+
n_per_group = math.ceil(((z_a + z_b)**2 * 2 * sd**2) / margin**2)
|
|
517
|
+
n_total = n_per_group * 2
|
|
518
|
+
|
|
519
|
+
# Equivalence / TOST for continuous
|
|
520
|
+
# Same formula; the difference is in the hypothesis and alpha interpretation
|
|
521
|
+
n_per_group = math.ceil(((z_a + z_b)**2 * 2 * sd**2) / margin**2)
|
|
522
|
+
n_total = n_per_group * 2
|
|
523
|
+
|
|
524
|
+
n_adj = math.ceil(n_total / (1 - attrition_rate))
|
|
525
|
+
```
|
|
526
|
+
|
|
527
|
+
### R Package
|
|
528
|
+
Base R. Also see `TrialSize`, `PowerTOST` packages.
|
|
529
|
+
|
|
530
|
+
### Key References
|
|
531
|
+
- Julious SA. Sample sizes for clinical trials with normal data. Stat Med. 2004;23(12):1921-1986.
|
|
532
|
+
- Schuirmann DJ. A comparison of the two one-sided tests procedure and the power approach for assessing the equivalence of average bioavailability. J Pharmacokinet Biopharm. 1987;15(6):657-680.
|
|
533
|
+
|
|
534
|
+
---
|
|
535
|
+
|
|
536
|
+
## Test 11: Cox Regression EPV (Events Per Variable)
|
|
537
|
+
|
|
538
|
+
### Formula
|
|
539
|
+
```
|
|
540
|
+
N_events = EPV × k (where k = number of predictor variables)
|
|
541
|
+
N_total = ceil( N_events / event_rate )
|
|
542
|
+
N_adj = ceil( N_total / (1 - attrition_rate) )
|
|
543
|
+
```
|
|
544
|
+
|
|
545
|
+
Where:
|
|
546
|
+
- `EPV` = events per variable (minimum 10, recommended 20)
|
|
547
|
+
- `k` = number of predictors in the Cox model
|
|
548
|
+
- `event_rate` = proportion of subjects experiencing the event
|
|
549
|
+
|
|
550
|
+
### R Implementation
|
|
551
|
+
```r
|
|
552
|
+
n_events <- epv * n_predictors
|
|
553
|
+
n_total <- ceiling(n_events / event_rate)
|
|
554
|
+
n_adj <- ceiling(n_total / (1 - attrition_rate))
|
|
555
|
+
|
|
556
|
+
cat(sprintf("EPV = %d, Predictors = %d\n", epv, n_predictors))
|
|
557
|
+
cat(sprintf("Required events = %d\n", n_events))
|
|
558
|
+
cat(sprintf("Total N = %d (event rate = %.0f%%)\n", n_total, event_rate * 100))
|
|
559
|
+
cat(sprintf("Adjusted N = %d (attrition = %.0f%%)\n", n_adj, attrition_rate * 100))
|
|
560
|
+
```
|
|
561
|
+
|
|
562
|
+
### Python Implementation
|
|
563
|
+
```python
|
|
564
|
+
import math
|
|
565
|
+
|
|
566
|
+
n_events = epv * n_predictors
|
|
567
|
+
n_total = math.ceil(n_events / event_rate)
|
|
568
|
+
n_adj = math.ceil(n_total / (1 - attrition_rate))
|
|
569
|
+
```
|
|
570
|
+
|
|
571
|
+
### R Package
|
|
572
|
+
Base R (no additional packages needed).
|
|
573
|
+
|
|
574
|
+
### Key References
|
|
575
|
+
- Peduzzi P, Concato J, Feinstein AR, Holford TR. Importance of events per independent variable in proportional hazards regression analysis. II. Accuracy and precision of regression estimates. J Clin Epidemiol. 1995;48(12):1503-1510.
|
|
576
|
+
- Vittinghoff E, McCulloch CE. Relaxing the rule of ten events per variable in logistic and Cox regression. Am J Epidemiol. 2007;165(6):710-718.
|
|
577
|
+
|
|
578
|
+
---
|
|
579
|
+
|
|
580
|
+
## Cohen's Effect Size Conventions
|
|
581
|
+
|
|
582
|
+
| Measure | Small | Medium | Large | Context |
|
|
583
|
+
|---------|-------|--------|-------|---------|
|
|
584
|
+
| d (t-test) | 0.20 | 0.50 | 0.80 | Difference in means / pooled SD |
|
|
585
|
+
| f (ANOVA) | 0.10 | 0.25 | 0.40 | SD of group means / within-group SD |
|
|
586
|
+
| h (proportions) | 0.20 | 0.50 | 0.80 | Arcsine-transformed proportion difference |
|
|
587
|
+
| w (chi-square) | 0.10 | 0.30 | 0.50 | Chi-square contingency effect |
|
|
588
|
+
| OR (logistic) | 1.5 | 2.0 | 3.0+ | Odds ratio (approximate equivalence) |
|
|
589
|
+
| HR (survival) | 0.80 | 0.65 | 0.50 | Hazard ratio (values < 1 favor treatment) |
|
|
590
|
+
| ICC | 0.50-0.75 | 0.75-0.90 | > 0.90 | Poor/moderate/good/excellent |
|
|
591
|
+
| Kappa | 0.21-0.40 | 0.41-0.60 | 0.61-0.80 | Fair/moderate/substantial |
|
|
592
|
+
|
|
593
|
+
**Important**: Cohen's conventions are rules of thumb. Always prefer effect sizes estimated from prior literature or pilot data. When conventions are used, explicitly state this limitation in the IRB justification.
|
|
594
|
+
|
|
595
|
+
---
|
|
596
|
+
|
|
597
|
+
## Common Attrition Rates by Study Type
|
|
598
|
+
|
|
599
|
+
| Study Type | Typical Attrition | Recommended Adjustment |
|
|
600
|
+
|------------|-------------------|------------------------|
|
|
601
|
+
| Randomized controlled trial (RCT) | 15-20% | 20% |
|
|
602
|
+
| Prospective observational / cohort | 10-15% | 15% |
|
|
603
|
+
| Cross-sectional / survey | 5-10% | 10% |
|
|
604
|
+
| Retrospective chart review | 3-5% | 5% |
|
|
605
|
+
| Diagnostic accuracy (imaging) | 5-10% | 10% |
|
|
606
|
+
| Inter-rater agreement study | 5-10% | 10% |
|
|
607
|
+
| Survival / long follow-up (> 2 yr) | 15-25% | 20% |
|
|
608
|
+
|
|
609
|
+
**Note**: Attrition rates vary widely by disease, population, and follow-up duration. Use study-specific estimates when available.
|
|
610
|
+
|
|
611
|
+
---
|
|
612
|
+
|
|
613
|
+
## Key References
|
|
614
|
+
|
|
615
|
+
1. **Cohen J.** Statistical Power Analysis for the Behavioral Sciences. 2nd ed. Hillsdale, NJ: Lawrence Erlbaum Associates; 1988.
|
|
616
|
+
- Foundation for effect size conventions (d, f, h, w) and power analysis methodology.
|
|
617
|
+
|
|
618
|
+
2. **Schoenfeld DA.** The asymptotic properties of nonparametric tests for comparing survival distributions. Biometrika. 1981;68(1):316-319.
|
|
619
|
+
- Formula for required number of events in log-rank test.
|
|
620
|
+
|
|
621
|
+
3. **Bonett DG.** Sample size requirements for estimating intraclass correlations with desired precision. Stat Med. 2002;21(9):1331-1335.
|
|
622
|
+
- ICC-based sample size using Fisher z-transformation.
|
|
623
|
+
|
|
624
|
+
4. **Hsieh FY.** Sample size tables for logistic regression. Stat Med. 1989;8(7):795-802.
|
|
625
|
+
- Power-based sample size for detecting a specific odds ratio.
|
|
626
|
+
|
|
627
|
+
5. **Peduzzi P, Concato J, Kemper E, Holford TR, Feinstein AR.** A simulation study of the number of events per variable in logistic regression analysis. J Clin Epidemiol. 1996;49(12):1373-1379.
|
|
628
|
+
- EPV >= 10 rule for logistic regression model stability.
|
|
629
|
+
|
|
630
|
+
6. **Donner A, Eliasziw M.** A goodness-of-fit approach to inference procedures for the kappa statistic: confidence interval construction, significance-testing and sample size estimation. Stat Med. 1992;11(11):1511-1519.
|
|
631
|
+
- Sample size for testing kappa against a null value.
|
|
632
|
+
|
|
633
|
+
7. **Buderer NMF.** Statistical methodology: I. Incorporating the prevalence of disease into the sample size calculation for sensitivity and specificity. Acad Emerg Med. 1996;3(9):895-900.
|
|
634
|
+
- Prevalence-adjusted sample size for diagnostic accuracy.
|
|
635
|
+
|
|
636
|
+
8. **Julious SA.** Sample sizes for clinical trials with normal data. Stat Med. 2004;23(12):1921-1986.
|
|
637
|
+
- Comprehensive non-inferiority and equivalence sample size formulas.
|
|
638
|
+
|
|
639
|
+
9. **Schuirmann DJ.** A comparison of the two one-sided tests procedure and the power approach for assessing the equivalence of average bioavailability. J Pharmacokinet Biopharm. 1987;15(6):657-680.
|
|
640
|
+
- TOST (two one-sided tests) procedure for equivalence testing.
|
|
641
|
+
|
|
642
|
+
10. **Koo TK, Li MY.** A guideline of selecting and reporting intraclass correlation coefficients for reliability research. J Chiropr Med. 2016;15(2):155-163.
|
|
643
|
+
- ICC interpretation benchmarks.
|
|
644
|
+
|
|
645
|
+
11. **Landis JR, Koch GG.** The measurement of observer agreement for categorical data. Biometrics. 1977;33(1):159-174.
|
|
646
|
+
- Kappa interpretation benchmarks.
|
|
647
|
+
|
|
648
|
+
12. **Connor RJ.** Sample size for testing differences in proportions for the paired-sample design. Biometrics. 1987;43(1):207-211.
|
|
649
|
+
- McNemar test sample size formula.
|
|
650
|
+
|
|
651
|
+
13. **Peduzzi P, Concato J, Feinstein AR, Holford TR.** Importance of events per independent variable in proportional hazards regression analysis. II. Accuracy and precision of regression estimates. J Clin Epidemiol. 1995;48(12):1503-1510.
|
|
652
|
+
- EPV >= 10 rule for Cox regression model stability.
|
|
653
|
+
|
|
654
|
+
14. **Vittinghoff E, McCulloch CE.** Relaxing the rule of ten events per variable in logistic and Cox regression. Am J Epidemiol. 2007;165(6):710-718.
|
|
655
|
+
- Evidence that EPV 5-10 may be acceptable with careful validation.
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
# Observational Cohort Sample Size: Precision Branch
|
|
2
|
+
|
|
3
|
+
Use this reference when a cohort study is extraction-constrained or when the goal is precision rather than formal power.
|
|
4
|
+
|
|
5
|
+
## When To Use
|
|
6
|
+
|
|
7
|
+
- Retrospective hospital-based cohort with all eligible records included.
|
|
8
|
+
- National database cohort where the sample is fixed by release permissions.
|
|
9
|
+
- Sparse-event outcome where the real question is whether confidence intervals are narrow enough to support a claim.
|
|
10
|
+
|
|
11
|
+
## Core Checks
|
|
12
|
+
|
|
13
|
+
1. Primary estimand: risk difference, odds ratio, hazard ratio, incidence rate, or mean difference.
|
|
14
|
+
2. Event count: total events and events per modeled parameter.
|
|
15
|
+
3. Precision target: acceptable confidence interval half-width or maximum acceptable upper bound.
|
|
16
|
+
4. Model complexity: covariate count relative to events.
|
|
17
|
+
5. Fragility: subgroup and sensitivity analyses with smaller denominators.
|
|
18
|
+
|
|
19
|
+
## Rule-of-Thumb Gates
|
|
20
|
+
|
|
21
|
+
| Situation | Minimum check |
|
|
22
|
+
|---|---|
|
|
23
|
+
| Logistic or Cox model | Events per parameter and shrinkage/penalization consideration |
|
|
24
|
+
| Sparse binary outcome | Exact or profile-likelihood confidence intervals |
|
|
25
|
+
| Incidence rate | Poisson exact CI around event rate |
|
|
26
|
+
| Null association claim | Upper CI bound must exclude clinically meaningful effect |
|
|
27
|
+
| Subgroup analysis | Interaction test plus event count per subgroup |
|
|
28
|
+
|
|
29
|
+
## Manuscript Phrase
|
|
30
|
+
|
|
31
|
+
"The study size was determined by all eligible participants in the released cohort. We therefore evaluated statistical informativeness by the number of outcome events, events per modeled parameter, and the width of the 95% confidence intervals around the primary estimate rather than by a conventional a priori recruitment target."
|
|
32
|
+
|
|
33
|
+
## Minimal R Sketch
|
|
34
|
+
|
|
35
|
+
```r
|
|
36
|
+
events <- 130
|
|
37
|
+
parameters <- 8
|
|
38
|
+
epv <- events / parameters
|
|
39
|
+
|
|
40
|
+
rate <- 130 / 250000
|
|
41
|
+
poisson.test(130, T = 250000)$conf.int
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
## Reviewer-Safe Interpretation
|
|
45
|
+
|
|
46
|
+
- If events are sparse, do not write "no association" without discussing the upper confidence bound.
|
|
47
|
+
- If EPV is below 10, state that estimates are exploratory or use penalized/sparse models.
|
|
48
|
+
- If a subgroup has few events, report it descriptively even when the p-value looks attractive.
|
|
49
|
+
|