Skip to content

BMisc

1.4.10Package record

Miscellaneous Functions for Panel Data, Quantiles, and Printing Results

8packages depend
110.2Kdownloads / year
62.0%test coverage
13/13flavors OK

Overview

About

These are miscellaneous functions for working with panel data, quantiles, and printing results. For panel data, the package includes functions for making a panel data balanced (that is, dropping missing individuals that have missing observations in any time period), converting id numbers to row numbers, and to treat repeated cross sections as panel data under the assumption of rank invariance. For quantiles, there are functions to make distribution functions from a set of data points (this is particularly useful when a distribution function is created in several steps), to combine distribution functions based on some external weights, and to invert distribution functions. Finally, there are several other miscellaneous functions for obtaining weighted means, weighted distribution functions, and weighted quantiles; to generate summary statistics and their differences for two groups; and to add or drop covariates from formulas. Additional utilities support staggered treatment adoption settings, including functions for identifying treatment groups, recovering pre-treatment outcomes and covariate averages, and computing lagged outcomes and first differences in panel data.

Changes in 1.4.10
  • Smaller footprint and improved performance.
  • Removed the dplyr and tidyr dependencies. The affected functions are now implemented with data.table, which was already a dependency, leading to a total reduction of ~20 packages (incl. strong recursive deps).
  • The workhorse panel "getter" functions (get_group(), get_Yit(), check_staggered(), etc.) have also been vectorized, yielding substantial performance improvements. On a simulated 200k row / 20k unit panel dataset, we observe 150-1400x speed gains, combined with an order of magnitude smaller memory allocation(s).
  • Bug fixes:
  • check_staggered() no longer (automatically) returns FALSE for panels with any treatment adoption. Previously, this function only returned TRUE when no unit ever changed treatment status.
Show all changes in 1.4.10Hide the rest of the changes in 1.4.10
  • get_Yit() now returns NA for units that are not observed in period tp. Previously such units contributed nothing to the result, so the returned vector was shorter than the number of rows in the data.
  • New features:
  • check_staggered() and check_staggered_inner() gain an optional tname argument. The check compares consecutive rows, so it is only meaningful when a unit's rows are in time order; supplying tname sorts them first. The default (NULL) keeps the previous assumption that the data is already ordered.
  • Other changes:
  • get_principal_components() now returns units in sorted id order. This is only a change for data that is not already sorted by id, where it previously used order of first appearance, and it makes the function consistent with the other panel data getters.
  • get_first_difference() no longer adds a temporary .lag column to a copy of the input data, and now works when passed a data.table.
  • Fixed silent row misalignment in several vectorized panel getters (get_group(), get_Yit(), get_principal_components(), etc.) when units were not sorted by id; added sort_panel() and set_balanced_panel(), and make_balanced_panel() now preserves its input's class instead of taking a return_data.table argument.

From NEWS.md in the release

Install

Health

CRAN checks
13OK
Slowest check: 3.0 min · r-devel-windows-x86_64
Status changes
  • OK13 OK2026-08-05
  • NOTE12 OK, 1 NOTE2026-08-01
  • OK13 OK2026-06-09
  • ERROR12 OK, 1 ERROR2026-06-08
  • OK13 OK2026-05-02
Show 6 earlier changesHide 6 earlier changes
  • ERROR11 OK, 1 ERROR2026-04-25
  • OK14 OK2026-04-22
  • ERROR13 OK, 1 ERROR2026-04-18
  • OK14 OK2026-04-08
  • ERROR13 OK, 1 ERROR2026-04-07
  • OK14 OK2026-03-10
Advisories

none known

Documentation

In release 1.4.10
READMEYes · 213 wordsVignettesNoNEWSYes · 100% structured · mentions 1.4.10Citation fileYes · software entry onlyWebsiteYes · pkgdown
Help pages
73 (28 internal)includes a package overview page
Examples that run
98%41 run in a plain check · 1 only when donttest examples are enabled (R CMD check --as-cran)
Exported functions with examples
58%
Documented parameters
96%
Return-value docs
53%
Help pages citing references
0%

Downloads

110.2K
CRAN downloads in the past year
Rank #1,224 · ~302/day · ~9.2K/mo
Daily download trend is not available in this view yet.
10K30 days
26.2K90 days
110.2K1 year
Compare downloads with other packages →
Also on1.4K r2u46 autocran5.5K conda_forge115 c2d4u

Repository

7Stars
3Forks
0Open issues
1Open PRs
2Releases
191Commits
5Commit identities
191 commits · Last activity 2026-08-22
Responsiveness
How these are sampled
PRs merged (all time)
67%
Median days to close, 50 most recently updated closed issues
1,124
Median days to close, 50 most recently updated closed PRs
1

Stars over time

2024-12-09 · 72026-07-07 · 7
PracticesBeta

10 development-tooling and community-health practices detected across 5 families in the upstream repository

Checks run against github.com/bcallaway11/bmisc on 2026-10-21.

Continuous integration (2)
GitHub ActionsR CMD check workflow

The R CMD check workflow runs on Linux, macOS and Windows, and on R-devel

Docs source (3)
README.qmdpkgdown

GitHub Pages site last deployed 2026-08-22

pkgdown site last built 2026-08-21, before release 1.4.10 (2026-08-22)

CRAN release process (2)
cran-comments.mdrevdep/
Research and citation (1)
CITATION.cff
Show all practicesHide 1 practice
Lint, format, editor (2)
lintrRStudio project
How this is detected·Detection ruleset v4 (2026-10-20)
AI coding toolsBeta

This repository shows signs of AI coding tools.

  • Claude Codefirst seen 2026-05-21
    Named in .Rbuildignore: .claude
    Commits: at least 22 crediting it in the message
Models named in its commits
  • Claude Sonnet 4.618 commits · May 2026
  • Claude Sonnet 54 commits · Aug 2026
Counts are commits, not lines of code. Commits by a tool's accounts count once across all of its accounts. Commits crediting it are the largest count among its credit lines, a minimum.How this is detected·Detection ruleset v4 (updated 2026-09-27)

Dependencies

Declared dependencies
8 external dependencies (excludes base and recommended)

Installing BMisc adds 3 packages (3 with compiled code, 8.5 MB of source tarballs). Heaviest: data.table 5.7 MB, Rcpp 1.8 MB, RcppArmadillo 1.0 MB.

Depends (1)
R >= 4.1.0
Imports (2)
LinkingTo (2)
Enhances (0)
none
Reverse dependencies
8direct
3indirect
Imports 8
Depends, Imports or LinkingTo, most downloaded first

People & History

People (2)
Author, Maintainer since 1.0.0 (2017)
Contributor · added in 1.4.10
Releases (16)

Pick two releases to compare their code metrics.

  • 1.4.10Latest
    record
    2026-08-22 · current release · diff ↗ ·
    added 2 exports
    set_balanced_panel, sort_panel
  • 1.4.9
    record
    2026-06-11 · diff ↗
  • R
    R 4.6.0 released · 2026-04-24
  • R
    R 4.5.0 released · 2025-04-11
  • 1.4.8
    record
    2025-02-04 · diff ↗ ·
    added 19 exports
    add_cov_to_formula, block_boot_sample, combine_ecdfs, compare_binary, compare_binary_inner, drop_cov_from_formula, get_list_element, id2rownum, invert_ecdf, lhs_vars, make_balanced_panel, make_dist, rhs_vars, weighted_checkfun, weighted_combine_list, weighted_ecdf, weighted_mean, weighted_quantile, weighted_quantile_inner
  • 1.4.7
    record
    2025-01-10 · diff ↗ ·
    added 10 exports
    check_staggered, check_staggered_inner, drop_collinear, get_principal_components, mv_mult, orig2t, orig2t_inner, t2orig, t2orig_inner, time_invariant_to_panel
  • R
    R 4.4.0 released · 2024-04-24
  • 1.4.6
    record
    2024-03-09 · diff ↗ ·
    added 15 exports
    element_wise_mult, get_Yi1, get_Yi1_inner, get_YiGmin1, get_YiGmin1_inner, get_Yibar, get_Yibar_inner, get_Yibar_pre, get_Yibar_pre_inner, get_Yit, get_Yit_inner, get_first_difference, get_group, get_group_inner, get_lagYi
  • R
    R 4.3.0 released · 2023-04-21
  • unarchivedReturned to CRAN
    2022-07-11
  • 1.4.5
    record
    2022-07-11 · diff ↗
  • archivedRemoved from CRAN
    2022-07-09
    check problems were not corrected in time , Does not use 'plm' conditionally, and that was for a time uninstallable
  • R
    R 4.2.0 released · 2022-04-22
  • 1.4.4
    record
    2022-01-26 · diff ↗
  • 1.4.3
    record
    2021-12-09 · diff ↗ ·
    added 3 exports
    TorF, multiplier_bootstrap, source_all
  • R
    R 4.1.0 released · 2021-05-18
Show 12 earlier eventsHide 12 earlier events
  • 1.4.2
    record
    2020-12-18 · diff ↗ ·
    added 1 export
    panel2cs2
  • R
    R 4.0.0 released · 2020-04-24
  • 1.4.1
    record
    2020-04-01 · diff ↗ ·
    added 2 exports
    blockBootSample, getListElement
  • R
    R 3.6.0 released · 2019-04-26
  • 1.3.1
    record
    2018-08-15 · diff ↗
  • 1.3.0
    record
    2018-07-17 · diff ↗ ·
    added 5 exports
    invertEcdf, lhs.vars, rhs, rhs.vars, toformula
  • R
    R 3.5.0 released · 2018-04-23
  • 1.2.0
    record
    2018-02-27 · diff ↗ ·
    added 1 export
    subsample
  • 1.1.1
    record
    2017-11-06 · diff ↗ ·
    added 1 export
    addCovToFormla
  • 1.0.1
    record
    2017-06-15 · diff ↗
  • 1.0.0
    record
    2017-06-14
  • R
    R 3.4.0 released · 2017-04-21

Package metadata

First published
2017-06-14
Total releases
16 / 9 yrs
License
GPL-3 OSI
Minimum R
≥ 4.1.0
Download size
91 KB

Cite

Cite this package

Run in R for the authors' entry:

citation("BMisc")

The package provides a citation file, so citation() returns the authors' own entry.

The repository also keeps a CITATION.cff.

Cite the R Observatory

For a number measured here: a download total, a coverage figure, an archival date.

APA

Balamuta, J. J. (2026). R Observatory: Metrics for BMisc version 1.4.10 [Data set]. HJJB, LLC. Data release v2026-10-23. https://doi.org/10.5281/zenodo.21843040

From data release v2026-10-23, which the citation names so these numbers can be found later. More on citing and the projects behind them.

Report a problem with this page →

Privacy choices

These apply to this browser and are stored on this device only. Nothing about your choice is sent to us.

Read the privacy policy