pharmhand 0.4.3.9000
- Safety hierarchy tables now retain treatment groups with zero events using
names_expand = TRUE. - Improved robustness in AE comparisons by short-circuiting when denominators are zero.
- Efficacy baseline calculations now use accessor helpers (
get_filtered_data,get_trt_var) instead of direct slot access. - Added input validation for treatment variables in laboratory tables to prevent unsafe glue syntax.
- Bayesian meta-analysis
warmupparameter now requires a positive integer (>= 1) for consistency with brms. - Standardized on
rlang::symacross all table creator functions. - Added
footnotesproperty toClinicalTableclass and updated reporting engine to populate it. - Fixed
ph_abort()to properly concatenate multiple arguments before passing torlang::abort(). - Documentation and test suite improvements, including explicit skip guards for
mmrmandcmdstanrdependencies.
pharmhand 0.4.2.9000
- Validation helpers now reject NA consistently across assertion functions.
- Reporting engine refactor: title/footnotes helper, ADaMData coercion, empty gt styling.
- Export improvements: preserve ClinicalTable styling, HTML title handling.
- Safety/efficacy robustness: NNH bounds ordering, warnings on empty filters, Treatment column guard, case-insensitive DISCONTINUED matching.
- Added .format_n_over_n formatting helper for n/N display.
- Test refactors for clarity and maintainability.
pharmhand 0.4.1.9000
Code Quality Improvements
Validation Utilities
- Added comprehensive assertion functions for input validation:
-
assert_all_positive(),assert_positive(),assert_non_negative() -
assert_positive_integer(),assert_non_negative_integer() -
assert_character_scalar(),assert_character_vector() -
assert_numeric_scalar(),assert_numeric_vector() -
assert_integer_scalar(),assert_logical_scalar() -
assert_data_frame(),assert_column_exists() -
assert_lengths_match(),assert_no_na(),assert_in_range()
-
Messaging and Helpers
- Added
ph_abort()for consistent error handling with abort messaging - Added
ph_inform()for informational messages - Added
ph_warn()for warning messages - Added
get_subject_n()for extracting subject counts from ADaM datasets - Added
get_summary_label()for generating standardized summary labels - Added
||operator (grapes-or-or-grapes) for flexible default value handling
Documentation Improvements
- Added man pages for internal helper functions:
- Added man pages for utility functions:
ph_abort(),ph_inform(),ph_warn() - Added man pages for new helpers:
get_subject_n(),get_summary_label(),||
Cleanup and Maintenance
- Removed
.tldr/directory and cache files (TLDR code analysis cache) - Deprecated
safe_pct()function (removed man page) - Removed 11 old imputation test problem files from
tests/testthat/_problems/ - Added
.tldr/andvignettes/safety-tables_files/to.gitignore - Updated README files and pkgdown configuration
- Updated vignettes for baseline, efficacy, and safety tables
pharmhand 0.4.0.9000
Phase 3: Quality Assessment
Risk of Bias Assessment (RoB 2)
- Added
RoB2ResultS7 class for storing RoB 2 assessment results. - Added
assess_rob2()for single-study risk of bias assessment using Cochrane RoB 2 tool. - Added
assess_rob2_batch()for batch processing multiple studies from a data frame. - Added
rob2_summary()for creating summary tables of RoB 2 assessments. - Implements all 5 RoB 2 domains: randomization, deviations, missing data, measurement, selection.
- Automatic overall judgment calculation following RoB 2 algorithm.
- Reference: IQWiG Allgemeine Methoden Section 10.1.4.
Risk of Bias Assessment (ROBINS-I)
- Added
ROBINSIResultS7 class for storing ROBINS-I assessment results. - Added
assess_robins_i()for single-study risk of bias assessment using ROBINS-I tool. - Added
assess_robins_i_batch()for batch processing multiple studies from a data frame. - Added
robins_i_summary()for creating summary tables of ROBINS-I assessments. - Implements all 7 ROBINS-I domains: confounding, participant selection, classification of interventions, deviations, missing data, outcome measurement, selection of reported result.
- Supports 5-level judgments: Low, Moderate, Serious, Critical, No information.
- Reference: IQWiG Allgemeine Methoden Section 10.1.4.
Risk of Bias Visualization
- Added
create_rob_traffic_light_plot()for traffic light visualization of domain-level judgments. - Added
create_rob_summary_plot()for stacked bar plot summaries of bias assessments. - Added
save_rob_plot()for exporting plots to PNG, SVG, PDF and other formats. - Added
rob_data_to_tidy()for converting assessment results to tidy data frames. - Supports both RoB 2 and ROBINS-I assessment results.
- Uses standard risk of bias color scheme (green/yellow/red/gray).
Bias-Adjusted Meta-Analysis
- Added
bias_adjusted_meta()for meta-analysis with risk of bias adjustments. - Added
rob_sensitivity_analysis()for sensitivity analysis across RoB scenarios. - Added
calculate_rob_weights()for computing RoB-adjusted study weights. - Added
summarize_bias_adjusted()for comparing original and adjusted estimates. - Supports three adjustment methods: weight_downgrade, exclude_high, selection_model.
- Integrates with RoB 2 and ROBINS-I assessment results.
IQWiG Evidence Grading
- Added
grade_evidence()for assessing evidence certainty using IQWiG methodology. - Added
assess_evidence_domains()for evaluating individual evidence domains. - Added
format_evidence_grade()for German (Beleg/Hinweis/Anhaltspunkt) or English output. - Implements IQWiG 3.1.4 evidence grading: Beleg (Proof), Hinweis (Indication), Anhaltspunkt (Hint), Kein Beleg (No proof).
- Evaluates: study limitations, inconsistency, imprecision, indirectness, publication bias.
- Integrates with RoB 2 assessments for study quality evaluation.
Evidence Summary Tables
- Added
create_evidence_summary_table()for IQWiG-formatted evidence summary tables. - Added
create_study_characteristics_table()for G-BA Module 4 study characteristics. - Added
export_evidence_table()for multi-format export (Word, HTML, Excel). - Includes: endpoint, N studies, effect estimate, CI, p-value, I², RoB summary, evidence grade.
- Supports German/English bilingual output with IQWiG-compliant formatting.
pharmhand 0.3.4.9000
Fixes and maintenance
- Fixed
create_clinical_table()to acceptAnalysisResultsobjects (uses@stats). - Improved Bayesian meta-analysis test performance and stability.
- Cleaned up documentation/signature mismatches and
R CMD checkissues.
Major Architecture Improvements
Package-Wide Defaults System
-
New defaults infrastructure: Added centralized default parameter system via
ph_default()function- Default values for common parameters (e.g.,
trt_var = "TRT01P",autofit = TRUE,conf_level = 0.95) - Users can override via options:
options(pharmhand.trt_var = "ARM") - Reduces boilerplate across 40+ functions
- Improves consistency and maintainability
- Default values for common parameters (e.g.,
Code Reusability Improvements
-
New
create_clinical_table()factory function: Reduces boilerplate for table creation- Consolidates repeated pattern of creating flextable + wrapping in ClinicalTable
- Used across 25+ table creation functions
- ~200 lines of duplicate code eliminated
-
Extracted
estimate_tau2()helper: Eliminates duplication in meta-analysis functions- Single implementation of DerSimonian-Laird, Paule-Mandel, and REML methods
- Used by both
meta_analysis()andcalculate_heterogeneity() - ~100 lines of duplicate code eliminated
Enhanced User Experience
-
Automatic data.frame coercion: User-facing functions now accept data.frames directly
-
create_demographics_table()automatically wraps data.frames in ADaMData - Eliminates need for users to manually create S7 objects
- Backward compatible with existing ADaMData inputs
-
-
Improved error messages: Context-rich error reporting throughout
- Error messages now show what was received vs. what was expected
- Available values suggested when appropriate (e.g., treatment arms)
- Missing column errors show available columns for easier debugging
-
New workflow helpers: High-level convenience functions for common tasks
-
quick_demographics_report(): Generate demographics report in one call -
quick_safety_report(): Generate multi-table safety report in one call - Ideal for quick analyses and prototyping
-
API Consistency
-
Standardized parameter names: Using
ph_default()across the package-
trt_var(nottreatment_var) for treatment variable -
conf_level(notci_levelorconfidence_level) for confidence level -
autofitconsistently for table formatting - Reduces cognitive load for users
-
-
Consistent return types: All
create_*_table()functions return ClinicalTable objects- Fixed inconsistencies where some returned bare flextables
- Enables consistent downstream processing
Breaking Changes
Source File Reorganization
-
Efficacy module split:
R/efficacy_tables.Rhas been split into focused modules:-
R/efficacy_primary.R- Primary endpoint tables (create_primary_endpoint_table()) -
R/efficacy_cfb.R- Change from baseline tables -
R/efficacy_lab.R- Laboratory tables -
R/efficacy_tte.R- Time-to-event tables -
R/efficacy_responder.R- Responder analysis tables -
R/efficacy_subgroup.R- Subgroup analysis tables
-
-
Safety module split:
R/safety_tables.Rhas been split into focused modules:-
R/safety_summary.R- AE summary tables (create_ae_summary_table()) -
R/safety_comparison.R- AE comparison tables -
R/safety_hierarchy.R- SOC/PT hierarchy tables -
R/safety_tte.R- Safety time-to-event analysis -
R/safety_exposure.R- Exposure-adjusted analysis
-
-
Migration guidance: Users who previously sourced these files directly should:
- Use the package namespace (e.g.,
pharmhand::create_primary_endpoint_table()) - Or source the new module files (e.g.,
source('R/efficacy_primary.R')) - Update any direct imports to reference the new module names
- Use the package namespace (e.g.,
Bug Fixes
Robustness Improvements
- Fixed
create_primary_endpoint_table()to handle empty data or all-NA values gracefully, returning “-” instead of NaN/Inf - Fixed
create_responder_analysis_table()to compute response rate in separate mutate step, avoiding fragile self-reference in summarise - Fixed
create_tte_summary_table()to correctly extract landmark survival estimates for each treatment stratum instead of using first stratum for all - Fixed
create_tte_summary_table()to use dynamic CI column names based on conf_level instead of hardcoded “lower .95”/“upper .95” - Fixed
create_league_table()to use NMA result’s stored confidence level when available - Fixed
leave_one_out()to read ci_level from correct slot (meta_result@ci_level instead of @metadata$conf_level)
Input Validation
- Require positive, non-missing standard errors in
eggers_test(),trim_and_fill(),meta_analysis(), andcalculate_heterogeneity() - Added
length(yi) == length(sei)validation ineggers_test()andtrim_and_fill() - Added
anyNA(yi)check ineggers_test()returning NA-filled result with clear interpretation - Added
anyNA(yi)check intrim_and_fill()with error listing invalid indices
Code Quality
- Changed
stop()toph_abort()in example script for consistent error handling - Fixed vignette code fence indentation mismatch in efficacy-tables.Rmd
- Added
:=import from rlang to fix undefined global function warning - Fixed
create_mean_plot()n calculation to count non-missing values - Added guards for CI computation when n <= 1 to avoid Inf values
Plotting Fixes
- Fixed
create_efficacy_waterfall_plot()to compute category counts in separate mutate step, avoiding fragile self-reference in summarise - Fixed
create_forest_plot()Cox model CI column extraction to use positional indexing instead of fragile name construction - Fixed
create_km_plot()risk table grid background by explicitly setting panel.grid.major/minor to element_blank() - Fixed
safe_pct()division by zero insafety_summary.Rby adding helper function applied to 9 locations
Bayesian Meta-Analysis Fixes
- Fixed
bayesian_meta_analysis()to usebrms::neff_ratio()instead of non-exportedbrms::ess_bulk()/brms::ess_tail() - Fixed
bayesian_meta_analysis()to compute BFMI from nuts_params energy values - Fixed
bayesian_meta_analysis()to usebrms::nuts_params()for divergent transitions instead of accessing internalfit$fit@sim$divergent__ - Added
tryCatchwrapper aroundbrms::brm()calls for better error handling - Changed all brms tests to use
cores = 1to avoid parallel rstan issues in CI - Added
bayesplotto Suggests, removed directrstandependency - Fixed roxygen documentation to avoid
\describe{}block Rd parsing issues - Added brms test caching helper to speed up test suite
Documentation
- Added @title tags and completed @return documentation in
meta_bias.R - Added within-study variation warning documentation in
assess_transitivity() - Split long @return lines in
safety_tte.R - Added description field to meta-analysis vignette
- Updated brms section in meta-analysis vignette with installation guidance
Test Improvements
- Refactored test-plotting_forest.R, test-efficacy_tte.R, and test-efficacy_subgroup.R to use shared test fixtures
- Included documentation examples to exported functions in efficacy and safety modules
- Updated
test-meta_bayesian.Rwith 8-study test data andadapt_delta = 0.99to prevent divergent transitions - Seeded RNG in 11 tests in
test-pro-analysis.R - Applied
set.seed()totest-efficacy_tte.Rbefore sample() call - Removed duplicate tests in
test-efficacy_responder.Randtest-efficacy_subgroup.R
pharmhand 0.3.0.9000
Major Changes
Test Suite Reorganization
-
One-test-file-per-source-file convention: Reorganized test files to follow R testing best practices.
- Split
test-efficacy_tables.Rintotest-efficacy_cfb.R,test-efficacy_lab.R,test-efficacy_primary.R,test-efficacy_responder.R,test-efficacy_subgroup.R, andtest-efficacy_tte.R - Split
test-meta-analysis.Rintotest-meta_core.R,test-meta_bayesian.R,test-meta_bias.R,test-meta_indirect.R,test-meta_network.R, andtest-meta_plots.R - Split
test-plotting.Rintotest-plotting_survival.R,test-plotting_efficacy.R, andtest-plotting_forest.R - Renamed
test-safety_tables.Rtotest-safety_summary.Rand extractedtest-safety_comparison.Randtest-safety_hierarchy.R
- Split
Bug Fixes
Test Data Improvements
- Fixed test data in safety TTE tests to use larger sample sizes (20+ subjects per arm) to avoid Cox model convergence issues
- Fixed test data to avoid duplicate landmark timepoints in TTE summary tests
- Fixed test data for subgroup analysis to have adequate subjects per subgroup (25+)
- Fixed S7 class checks from
expect_s3_class()toS7::S7_inherits()for proper S7 class validation - Fixed error message regex patterns to match actual function outputs
Source Code Fixes
- Fixed
km_summarymatrix conversion inefficacy_tte.Rto preserve column names for single treatment arms - Fixed
pctcolumn warning insafety_summary.Rby using properdplyr::mutate()instead of for-loop assignment - Fixed
survfitn.censormatrix handling inplotting_survival.Rby converting to vector - Fixed
min()returning-Infinpro_analysis.Rwhen no events present - Fixed S7 class checking in
config_api.Rto useS7::S7_inherits()instead ofinherits()
Test Cleanup
- Removed tests for unimplemented
maic()andstc()functions - Fixed missing
registryvariable in config API tests - Changed REML tests to use DerSimonian-Laird method to avoid convergence warnings
- Replaced
any(is.na())withanyNA()per jarl recommendations
pharmhand 0.2.3.9000
Documentation
- Added runnable examples for all meta-analysis and network meta-analysis functions including
meta_analysis(),indirect_comparison(),network_meta(),create_network_plot(),assess_transitivity(),node_splitting(),calculate_sucra(), andcreate_league_table().
pharmhand 0.2.2.9000
Phase 2: Evidence Synthesis
Meta-Analysis Functions
Added
meta_analysis()for fixed-effect and random-effects meta-analysis with support for multiple tau² estimators (DerSimonian-Laird, REML, Paule-Mandel, ML) and optional Knapp-Hartung adjustment.Added
calculate_heterogeneity()for comprehensive heterogeneity assessment including Q, I², τ², and H² statistics with interpretation.Added
leave_one_out()for sensitivity analysis identifying influential studies.Added
create_meta_forest_plot()for meta-analysis forest plots with study weights, heterogeneity statistics, and prediction intervals.Added
create_funnel_plot()for publication bias visualization.Added
eggers_test()for statistical assessment of funnel plot asymmetry.Added
trim_and_fill()for Duval & Tweedie publication bias adjustment.
Indirect Comparison
Added
indirect_comparison()using the Bucher method for anchored indirect treatment comparisons.Added
compare_direct_indirect()for consistency testing between direct and indirect evidence.
Network Meta-Analysis
Added
network_meta()for network meta-analysis comparing multiple treatments.Added
create_network_plot()for network geometry visualization.Added
assess_transitivity()for evaluating the transitivity assumption.Added
node_splitting()for testing inconsistency between direct and indirect evidence.Added
calculate_sucra()for treatment ranking with SUCRA/P-scores.Added
create_league_table()for pairwise comparison tables.
Bayesian Analysis
- Added
bayesian_meta_analysis()interface for Bayesian meta-analysis using brms when available, with automatic fallback to frequentist methods.
Phase 1 Completion
PRO Analysis
Added
calculate_mcid_anchor()for anchor-based MCID calculation.Added
calculate_mcid_distribution()for distribution-based MCID (0.5 SD, 1 SEM, etc.).Added
calculate_mcid()wrapper combining both MCID approaches.Added
create_ttd_analysis()for time-to-deterioration analysis with Kaplan-Meier estimation.
Visualization
Added
create_mean_plot()for longitudinal mean plots with confidence intervals.Added
create_spider_plot()for individual patient trajectory visualization.
Safety Analysis
- Added
create_ae_hierarchy_table()for full MedDRA hierarchy analysis (SOC → HLGT → HLT → PT).
Subgroup Analysis
- Added
assess_iceman()for ICEMAN criteria assessment of subgroup credibility.
pharmhand 0.2.1.9000
Improvements
- Added
conf_levelparameter tocreate_ae_cumulative_incidence_plot()(was hard-coded at 0.95). - Exposed
subgroup_countsandmin_subgroup_sizeincreate_subgroup_analysis_table()metadata for programmatic access. - Wrapped
test_ph_assumption()call increate_tte_summary_table()with tryCatch for robustness with sparse Cox models.
Plotting
- Created
.pharmhand_theme()internal helper for consistent white backgrounds across all plots. - Refactored all plotting functions to use
.pharmhand_theme()withbase_sizeparameter. - Added
conf_levelparameter tocreate_loglog_plot(). - Added
base_sizeparameter tocreate_ae_cumulative_incidence_plot()andcreate_forest_plot(). - Updated
build_schoenfeld_plot()to use.pharmhand_theme()for consistent styling.
Documentation
- Clarified that
methodparameter intest_non_inferiority()applies only to binary endpoints. - Added
@examplestodetect_floor_ceiling(),test_non_inferiority(),ancova_adjust_continuous(),create_loglog_plot(), andcreate_ae_cumulative_incidence_plot(). - Added Time-to-Event Safety Analysis section to safety-tables vignette.
- Added NNH (Number Needed to Harm) documentation to safety-tables vignette.
- Added Non-Inferiority Testing section to efficacy-tables vignette.
- Added ANCOVA Adjustment section to efficacy-tables vignette.
- Added Floor/Ceiling Detection section to efficacy-tables and baseline-tables vignettes.
- Improved documentation for
test_non_inferiority()with clarified conf_level, decision logic, and higher_better parameter. - Improved documentation for
ancova_adjust_continuous()with edge case behavior and runnable simulated example.
pharmhand 0.2.0.9000
Code Quality
- Refactored duplicated palette resolution logic into
.resolve_palette()helper. - Added warning when log-log plot drops data points with non-finite values.
- Expanded PH assumption disable comment with rationale for time-to-first AE.
- Added clarifying comments in floor/ceiling detection and event conversion.
- Added documentation note about CI construction methods for non-inferiority binary endpoints.
- Removed redundant
@keywords internalfrom exportedancova_adjust_continuous().
Tests
- Made color palette test assertions order-agnostic with
expect_setequal(). - Added edge case tests for
calculate_exposure_adjusted_rate()(zero events, small exposure, large counts).
pharmhand 0.1.21.9000
Bug Fixes
- Fixed ComparisonResult defaults from
integer(0)tonumeric(0)for consistency with S7 class. - Fixed line length lint errors in
test_non_inferiority()documentation.
Documentation
- Updated pkgdown Utilities section description to include “statistical diagnostics”.
- Added missing topics to pkgdown reference index:
calculate_exposure_adjusted_rate(),create_ae_exposure_table(),create_time_to_first_ae(), andtest_non_inferiority(). - Cleaned up duplicate NEWS.md heading.
- Added explanatory comment for PH assumption check disable in time-to-first AE function.
Plotting
- Added
show_censorsupport tocreate_loglog_plot()and passed through fromcreate_km_plot(type = "loglog"). - Updated documentation to clarify that censor marks are supported on log-log plots while median lines, CI bands, risk tables, and landmarks are intentionally omitted.
- Added test for log-log plot censor marks.
pharmhand 0.1.20.9000
Improvements
- Added AE cumulative incidence plots via
create_ae_cumulative_incidence_plot().
pharmhand 0.1.19.9000
Improvements
- Added ANCOVA adjustment for continuous endpoints via
ancova_adjust_continuous().
pharmhand 0.1.18.9000
Improvements
- Added non-inferiority testing for continuous and binary endpoints via
test_non_inferiority().
pharmhand 0.1.17.9000
Improvements
- Added time-to-first adverse event analysis with KM tables, plots, and Cox HRs via
create_time_to_first_ae().
pharmhand 0.1.16.9000
Improvements
- Added exposure-adjusted incidence rate tables with Poisson confidence intervals via
calculate_exposure_adjusted_rate()andcreate_ae_exposure_table().
pharmhand 0.1.15.9000
Improvements
- Added configurable warnings for small subgroups in
create_subgroup_table()andcreate_subgroup_analysis_table()viamin_subgroup_size(default: 20).
pharmhand 0.1.14.9000
Documentation
- Documented the complete proportional hazards assumption testing suite for Cox models: Schoenfeld residual tests via
test_ph_assumption(), log-log survival plots viacreate_loglog_plot(), and automatic warnings increate_tte_summary_table().
pharmhand 0.1.13.9000
Improvements
- Added automatic PH violation warnings in
create_tte_summary_table()with guidance on stratified or alternative survival models.
pharmhand 0.1.12.9000
Improvements
- Added log-log survival plots for PH diagnostics via
create_loglog_plot()andcreate_km_plot(type = "loglog").
pharmhand 0.1.11.9000
Improvements
- Added
test_ph_assumption()to run Schoenfeld residual tests with optional diagnostic plots.
pharmhand 0.1.10.9000
Improvements
- Added
detect_floor_ceiling()to flag floor/ceiling effects in PRO scores by visit and treatment arm.
pharmhand 0.1.3.9000
Documentation
- Clarified palette resolution for
create_km_plot()and CI formatting guidance. - Added a note on comparison-table entry points in the safety tables vignette.
- Fixed the pkgdown badge URL in the README.
pharmhand 0.1.1.9000
Bug Fixes
- Fixed redundant null check in
check_gba_compliance()title validation. - Fixed
to_gba_template()list handling that would overwrite same file path. - Fixed list handling in
check_gba_compliance()for unnamed elements.
Improvements
-
theme_iqwig()andtheme_gba()now apply thedecimal_separatorparameter to numeric columns (was declared but unused). -
SingleArmStudynow has atreatment_varproperty for consistency withTwoArmStudyandMultiArmStudy.
pharmhand 0.1.0.9000
Breaking Changes
- Renamed
create_ae_table()tocreate_ae_summary_table()for clarity.
Improvements
-
format_pvalue()andformat_ci()now accepttrimandna_stringparameters for more flexible output formatting.
Documentation
- Added README.Rmd with rendered demo table and KM plot figures.
- Improved pkgdown site with sandstone theme and dark mode support.
- Simplified Articles dropdown to flat list.
- Added description to baseline-tables vignette.
- Fixed dev status badges visibility with
development: mode: unreleased.
pharmhand 0.0.18.9000
New Features
- Add
to_gba_template()to export ClinicalTable/ClinicalReport objects in G-BA Module 4 format.
pharmhand 0.0.17.9000
New Features
- Add
create_hta_module4_table()for standardized G-BA Module 4 tables.
pharmhand 0.0.16.9000
New Features
- Add
check_gba_compliance()for pre-export validation of G-BA Module 4 tables. - Mark IQWiG and G-BA flextable themes with a
pharmhand_themeattribute.
pharmhand 0.0.15.9000
Breaking Changes
- Remove
fmt_pvalue()format preset. Useformat_pvalue()for IQWiG-compliant p-value formatting.
New Features
- IQWiG-compliant formatting functions:
format_pvalue()andformat_ci(). - Locale-aware helpers:
format_number()andformat_percentage(). - New flextable themes:
theme_iqwig()andtheme_gba().
pharmhand 0.0.14.9000
Breaking Changes
Endpoint classes unified:
PrimaryEndpoint,SecondaryEndpoint, andSafetyEndpointhave been replaced with a singleEndpointclass. Use thecategoryproperty (“primary”, “secondary”, “safety”, “exploratory”) instead.Study class renamed:
OneArmStudyis nowSingleArmStudyfor clarity.New property name:
TwoArmStudy@group_varis nowTwoArmStudy@treatment_var.
New Features
Study base class: New abstract
Studyclass provides common properties for all study types.MultiArmStudy: New class for studies with 3+ treatment arms.
StudySet: New class for collections of studies (meta-analysis, NMA).
Statistical result classes: New
StatResulthierarchy withComparisonResult,MetaResult, andEvidenceGradefor type-safe results.
pharmhand 0.0.13.9000
pharmhand 0.0.11.9000
Documentation
- Simplify LayeredTable usage default to
data.frame()
Maintenance
- Relax R version requirement to >= 4.1.0
- Consolidate development artifacts under
notes/and exclude the directory in.Rbuildignore - Use
paste0()for missing-translation warnings
pharmhand 0.0.10.9000
Fixes
- Enforce unique ADSL USUBJID when joining subgroup variables
- Standardize data frame validation in lab summary, shift, and subgroup tables
pharmhand 0.0.9.9000
pharmhand 0.0.8.9000
pharmhand 0.0.6.9000
New features
- Added multiplicity adjustment for p-values:
-
adjust_pvalues(): Apply Bonferroni, Holm, BH, or Hochberg corrections -
create_subgroup_table()now supportsadjust_methodparameter
-
- Added
calculate_nnt()for Number Needed to Treat calculation with confidence intervals
pharmhand 0.0.5.9000
New features
- Added comprehensive localization support for German HTA (G-BA/AMNOG) dossiers:
-
set_locale()/get_locale(): Set and retrieve current locale (“en” or “de”) -
tr(): Translate keys to current locale -
tr_col(): Translate data frame column names -
get_translations(): Get all translations for a locale -
add_translation(): Add custom translations -
reset_custom_translations(): Clear custom translations -
list_translation_keys(): List all available translation keys - Built-in German translations for common clinical trial terms (demographics, AEs, efficacy endpoints, populations)
-
pharmhand 0.0.4.9000
New features
- Unified treatment variable API across safety and efficacy tables:
- All table functions now consistently use
trt_var = "TRT01P"as default -
create_primary_endpoint_table(),create_cfb_summary_table(),create_vs_by_visit_table()now accepttrt_varparameter - Safety tables (
create_ae_table()) default changed from “TRT01A” to “TRT01P” for consistency
- All table functions now consistently use
- Added
create_ae_comparison_table()for adverse event comparisons with risk metrics:- Accessible via
create_ae_table(type = "comparison") - Calculates risk difference (RD) and risk ratio (RR) with confidence intervals
- Supports grouping by SOC, PT, or overall
- Configurable reference group and incidence threshold filtering
- Chi-square or Fisher’s exact test for p-values
- Accessible via
pharmhand 0.0.3.9000
New features
- Added standardized mean difference (SMD) functions for GBA baseline balance assessment:
-
calculate_smd(): Cohen’s d and Hedges’ g for continuous variables -
calculate_smd_binary(): Arcsine/logit methods for binary variables -
calculate_smd_from_data(): Auto-detect variable type from data -
add_smd_to_table(): Add SMD column to demographics tables -
assess_baseline_balance(): Comprehensive multi-variable assessment -
create_love_plot(): Covariate balance visualization (Love plot) -
BalanceAssessmentS7 class for storing assessment results
-
- Updated baseline-tables vignette with SMD examples
pharmhand 0.0.2.9000
Documentation
Vignettes now display all generated tables using flextable rendering
Large tables (SOC/PT, lab shift, medical history, conmeds) are collapsible with
<details>tagsAdded dark mode support for pkgdown site tables via CSS overrides for flextable compatibility
Fixed
format_spec()roxygen documentation
pharmhand 0.0.1.9000
New features
S7 classes:
ADaMData,ClinicalTable,ClinicalPlot,ClinicalReport,StudyResultADaMDatawraps ADaM datasets with automatic population filteringcreate_ae_table()generates AE tables withtypeargumentcreate_tte_summary_table()for time-to-event analysiscreate_responder_table()for response rates with CI and comparisonscreate_subgroup_table()andcreate_forest_plot()for subgroupscreate_km_plot()for Kaplan-Meier curvescreate_cfb_summary_table()for change-from-baselinecreate_lab_shift_table()for lab shiftscreate_demographics_table(),create_disposition_table(),create_population_summary_table()
Reporting
ClinicalReportcollects tables and plots for Word exportgenerate_word()andwrite_docx()export to.docx
Formatting
format_pvalue(),format_ci(),format_percentage(),format_number()FormatSpecandCompositeFormatclasses
pharmhand 0.0.0.9000
New features
- Initial package release
- S7 class system for clinical content (
ADaMData,ClinicalTable,ClinicalPlot,ClinicalReport,StudyResult) - ADaM dataset handling with population filters
- Safety tables: AE overview, SOC/PT summaries, severity, relationship, SAEs, deaths
- Efficacy tables: primary endpoints, subgroup analyses
- Word document generation via officer/flextable
- Integration with chef package for HTA/AMNOG analyses
