Package: heaping 0.2.0
heaping: Correction of Heaping on Individual Level
Provides methods for correcting heaping (digit preference) in survey data at the individual record level. Age heaping, where respondents disproportionately report ages ending in 0 or 5, is a common phenomenon that can distort demographic analyses. Unlike traditional smoothing methods that only correct aggregated statistics, this package corrects individual values by replacing a calculated proportion of heaped observations with draws from fitted truncated distributions (log-normal, normal, or uniform). Supports 5-year and 10-year heaping patterns, single heap correction, survey weights, and optional covariate-conditional (model-based) correction via quantile regression forests or linear models to preserve relationships. A multiple-imputation wrapper repeats the correction to propagate the added uncertainty into downstream inference.
Authors:
heaping_0.2.0.tar.gz
heaping_0.2.0.zip(r-4.7)heaping_0.2.0.zip(r-4.6)heaping_0.2.0.zip(r-4.5)
heaping_0.2.0.tgz(r-4.6-any)heaping_0.2.0.tgz(r-4.5-any)
heaping_0.2.0.tar.gz(r-4.7-any)heaping_0.2.0.tar.gz(r-4.6-any)
heaping_0.2.0.tgz(r-4.6-emscripten)
manual.pdf |manual.html✨
DESCRIPTION |NEWS
card.svg |card.png
heaping/json (API)
| # Install 'heaping' in R: |
| install.packages('heaping', repos = c('https://matthias-da.r-universe.dev', 'https://cloud.r-project.org')) |
Bug tracker:https://github.com/matthias-da/heaping/issues
- samp - Sample Data for Heaping Correction Examples
Last updated from:d291de5041. Checks:7 WARNING, 2 OK. Indexed: yes.
| Target | Result | Time | Files | Syslog |
|---|---|---|---|---|
| linux-devel-x86_64 | WARNING | 204 | ||
| source / vignettes | OK | 292 | ||
| linux-release-x86_64 | WARNING | 222 | ||
| macos-release-arm64 | WARNING | 126 | ||
| macos-oldrel-arm64 | WARNING | 127 | ||
| windows-devel | WARNING | 141 | ||
| windows-release | WARNING | 101 | ||
| windows-oldrel | WARNING | 136 | ||
| wasm-release | OK | 190 |
Exports:bachicoale_licorrectHeapscorrectHeaps2correctHeapsMIcorrectSingleHeapheaping_indicesjdanovkannistomyersnoumbissispoorenbergspraguewhipple
Dependencies:clicpp11EnvStatsfarverfitdistrplusggplot2gluegtableisobandlabelinglatticelifecycleMASSMatrixnortestR6RColorBrewerrlangS7scalessurvivalvctrsviridisLitewithr
Readme and manuals
Help Manual
| Help page | Topics |
|---|---|
| heaping: Correction of Heaping on Individual Level | heaping-package heaping |
| Bachi's Index of Age Heaping | bachi |
| Coale-Li Age Heaping Index | coale_li |
| Correct Age Heaping | correctHeaps correctHeaps2 |
| Multiple-Imputation Heaping Correction | correctHeapsMI print.heapingMI |
| Correct a Single Age Heap | correctSingleHeap |
| Calculate All Heaping Indices | heaping_indices |
| Jdanov's Old-Age Heaping Index | jdanov |
| Kannisto's Age Heaping Index | kannisto |
| Myers' Blended Index of Age Heaping | myers |
| Noumbissi's Digit Heaping Index | noumbissi |
| Sample Data for Heaping Correction Examples | samp |
| Spoorenberg's Total Modified Whipple Index | spoorenberg |
| Sprague Index (Multipliers) | sprague |
| Whipple Index (Original and Modified) | whipple |
