Skip to content

pubh

A Toolbox for Public Health and Epidemiology

v3.0.0 · Oct 21, 2025 · GPL-2

Description

A toolbox for making R functions and capabilities more accessible to students and professionals from Epidemiology and Public Health related disciplines. Includes a function to report coefficients and confidence intervals from models using robust standard errors (when available), functions that expand 'ggplot2' plots and functions relevant for introductory papers in Epidemiology or Public Health. Please note that use of the provided data sets is for educational purposes only.

Downloads

450

Last 30 days

8500th

1.3K

Last 90 days

5.8K

Last year

Trend: -0.7% (30d vs prior 30d)

CRAN Check Status

1 ERROR
13 OK
Show all 14 flavors
Flavor Status
r-devel-linux-x86_64-debian-clang OK
r-devel-linux-x86_64-debian-gcc OK
r-devel-linux-x86_64-fedora-clang OK
r-devel-linux-x86_64-fedora-gcc OK
r-devel-macos-arm64 OK
r-devel-windows-x86_64 OK
r-oldrel-macos-arm64 OK
r-oldrel-macos-x86_64 OK
r-oldrel-windows-x86_64 ERROR
r-patched-linux-x86_64 OK
r-release-linux-x86_64 OK
r-release-macos-arm64 OK
r-release-macos-x86_64 OK
r-release-windows-x86_64 OK
Check details (1 non-OK)
ERROR r-oldrel-windows-x86_64

examples

Running examples in 'pubh-Ex.R' failed
The error most likely occurred in:

> ### Name: axis_labs
> ### Title: Apply labels from variables to axis-labels in plots.
> ### Aliases: axis_labs
> 
> ### ** Examples
> 
> data(kfm, package = "ISwR")
> require(sjlabelled, quietly = TRUE)

Attaching package: 'sjlabelled'

The following object is masked from 'package:ggplot2':

    as_label

> kfm <- kfm |>
+   var_labels(
+     dl.milk = "Breast-milk intake (dl/day)",
+     sex = "Sex",
+     weight = "Child weight (kg)",
+     ml.suppl = "Milk substitute (ml/day)",
+     mat.weight = "Maternal weight (kg)",
+     mat.height = "Maternal height (cm)"
+   )
> 
> kfm |>
+   gf_point(weight ~ dl.milk) |>
+   gf_lm(col = 2, interval = "confidence", col = 2) |>
+   axis_labs()
Warning in rep(yes, length.out = len) :
  'x' is NULL so the result will be NULL
Error in ans[ypos] <- rep(yes, length.out = len)[ypos] : 
  replacement has length zero
Calls: axis_labs -> ifelse
Execution halted

Check History

ERROR 13 OK · 0 NOTE · 0 WARNING · 1 ERROR · 0 FAILURE Mar 10, 2026
ERROR r-oldrel-windows-x86_64

examples

Running examples in 'pubh-Ex.R' failed
The error most likely occurred in:

> ### Name: axis_labs
> ### Title: Apply labels from variables to axis-labels in plots.
> ### Aliases: axis_labs
> 
> ### ** Examples
> 
> data(kfm, package = "ISwR")
> requir
...[truncated]...
fidence", col = 2) |>
+   axis_labs()
Warning in rep(yes, length.out = len) :
  'x' is NULL so the result will be NULL
Error in ans[ypos] <- rep(yes, length.out = len)[ypos] : 
  replacement has length zero
Calls: axis_labs -> ifelse
Execution halted

Dependency Network

Dependencies Reverse dependencies emmeans ggplot2 gtsummary huxtable car dplyr Epi epitools jtools lmtest performance sandwich sjlabelled sjmisc survival +2 more dependencies pubh

Version History

new 3.0.0 Mar 10, 2026
updated 3.0.0 ← 2.0.0 diff Oct 20, 2025
updated 2.0.0 ← 1.3.7 diff Oct 7, 2024
updated 1.3.7 ← 1.3.2 diff Aug 16, 2024
updated 1.3.2 ← 1.3.1 diff Jan 10, 2024
updated 1.3.1 ← 1.2.7 diff Nov 13, 2023
updated 1.2.7 ← 1.2.5 diff Apr 3, 2022
updated 1.2.5 ← 1.1.20 diff Oct 10, 2021
updated 1.1.20 ← 1.1.19 diff Feb 15, 2021
updated 1.1.19 ← 1.1.18 diff Dec 2, 2020
updated 1.1.18 ← 1.1.16 diff Nov 9, 2020
updated 1.1.16 ← 1.1.14 diff Jul 6, 2020
updated 1.1.14 ← 1.1.12 diff Jun 1, 2020
updated 1.1.12 ← 1.1.6 diff Apr 25, 2020
updated 1.1.6 ← 1.1.5 diff Mar 1, 2020
updated 1.1.5 ← 1.1.3 diff Feb 2, 2020
updated 1.1.3 ← 1.1.2 diff Dec 9, 2019
updated 1.1.2 ← 0.4.3 diff Dec 6, 2019
updated 0.4.3 ← 0.4.2 diff Nov 1, 2018
updated 0.4.2 ← 0.4.1 diff Aug 29, 2018