Skip to content
This package was removed from CRAN on 2025-10-25. Its history is shown below.
Reason: issues were not corrected despite reminders
Details below reflect version 1.0.1, its last release before removal.

planningML

1.0.1

A Sample Size Calculator for Machine Learning Applications in Healthcare

0packages depend
downloads / year
test coverage
checks pass

Overview

About
Maintained by Xinying Fang2 releasesCRAN page ↗

Advances in automated document classification has led to identifying massive numbers of clinical concepts from handwritten clinical notes. These high dimensional clinical concepts can serve as highly informative predictors in building classification algorithms for identifying patients with different clinical conditions, commonly referred to as patient phenotyping. However, from a planning perspective, it is critical to ensure that enough data is available for the phenotyping algorithm to obtain a desired classification performance. This challenge in sample size planning is further exacerbated by the high dimension of the feature space and the inherent imbalance of the response class. Currently available sample size planning methods can be categorized into: (i) model-based approaches that predict the sample size required for achieving a desired accuracy using a linear machine learning classifier and (ii) learning curve-based approaches (Figueroa et al. (2012) doi:10.1186/1472-6947-12-8) that fit an inverse power law curve to pilot data to extrapolate performance. We develop model-based approaches for imbalanced data with correlated features, deriving sample size formulas for performance metrics that are sensitive to class imbalance such as Area Under the receiver operating characteristic Curve (AUC) and Matthews Correlation Coefficient (MCC). This is done using a two-step approach where we first perform feature selection using the innovated High Criticism thresholding method (Hall and Jin (2010) doi:10.1214/09-AOS764), then determine the sample size by optimizing the two performance metrics. Further, we develop software in the form of an R package named 'planningML' and an 'R' 'Shiny' app to facilitate the convenient implementation of the developed model-based approaches and learning curve approaches for imbalanced data. We apply our methods to the problem of phenotyping rare outcomes using the MIMIC-III electronic health record database. We show that our developed methods which relate training data size and performance on AUC and MCC, can predict the true or observed performance from linear ML classifiers such as LASSO and SVM at different training data sizes. Therefore, in high-dimensional classification analysis with imbalanced data and correlated features, our approach can efficiently and accurately determine the sample size needed for machine-learning based classification.

Install

Health

CRAN checks

CRAN check results are not tracked yet.

Code health
None
Tests · ratio 0.00
not tracked
Coverage
100%
Documentation · exports
8
Dependencies · direct

Documentation

Documentation
READMENoVignettesYes · dynamicpkgdown siteNoNEWSNoCode of conductNoContributing guideNo
Examples that run
100%
Documented parameters
100%
Return-value docs
100%
References docs
0%

Downloads

planningML
Daily download trend is not available in this view yet.
Also on111 r2u

Dependencies

Declared dependencies
8 external dependencies (excludes base and recommended)
Depends (1)
R >= 3.5.0
Imports (8)
LinkingTo (0)
none
Suggests (2)
Enhances (0)
none
Reverse dependencies
0direct
indirect (not tracked)

Nothing depends on this yet.

Code & Tests

People & History

People (4)
Maintainer (1)
Author, Maintainer
Authors (4)
Author, Maintainer
Package Timeline

2 releases. Pick two to compare their code metrics. R releases are shown for context.

  • R
    R 4.6.0 released · 2026-04-24
  • archivedRemoved from CRAN
    2025-10-25
    issues were not corrected despite reminders
  • R
    R 4.5.0 released · 2025-04-11
  • R
    R 4.4.0 released · 2024-04-24
  • 1.0.1
    2023-06-23 · diff ↗
  • R
    R 4.3.0 released · 2023-04-21
  • 1.0.0
    2022-11-08
  • R
    R 4.2.0 released · 2022-04-22

Package metadata

Total releases
2
License
GPL-2 OSI
Minimum R
≥ 3.5.0
Download size
not tracked yet
Installed size
not tracked yet
With dependencies
not tracked yet

Cite

Cite this package

Run in R for the authors' preferred citation:

citation("planningML")
Fang, X., Saha, S., Song, J., & Dharmarajan, S. (n.d.). planningML: A Sample Size Calculator for Machine Learning Applications in Healthcare (Version 1.0.1) [Computer software]. Retrieved August 13, 2026, from https://CRAN.R-project.org/package=planningML

This is what citation() produces when a package has no citation file of its own. If it prints something else, use that.

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 planningML version 1.0.1 [Data set]. HJJB, LLC. Data release v2026-08-11. https://doi.org/10.5281/zenodo.21843040

From data release v2026-08-11, 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