Package: softcats 1.0.0

softcats: Regression on Predicted Categories with Calibrated Probabilities
Estimates the association between an outcome and a latent categorical group from calibrated class probabilities instead of predicted labels. Assigning each observation its most likely category or thresholding the probabilities distorts regression estimates (for a binary group it typically attenuates them) and can give confidence intervals whose coverage is far below the nominal level. The estimator partials the controls out of the outcome and the probabilities with cross-fitted machine learning nuisance functions and solves a Neyman-orthogonal moment equation, with heteroskedasticity- or cluster-robust standard errors and optional weights. Further functions report how much information the probabilities carry beyond the controls, test conditional calibration and direct effects of classifier features on labelled data, recalibrate the probabilities on such data, bound the bias from calibration error, and compare the estimate with hard-label regressions, including the distortion and the implied coverage of the cross-fitted hard-label estimate. Methods follow Kurbucz (2026) <doi:10.48550/arXiv.2608.11784> for several categories and coarsening, Kurbucz (2026) <doi:10.48550/arXiv.2605.12780> for confidence thresholding, and the cross-fitting of Chernozhukov et al. (2018) <doi:10.1111/ectj.12097>.
Authors:
softcats_1.0.0.tar.gz
softcats_1.0.0.zip(r-4.7-any)softcats_1.0.0.zip(r-4.6-any)
softcats_1.0.0.tar.gz(r-4.7-any)softcats_1.0.0.tar.gz(r-4.6-any)
softcats_1.0.0.tgz(r-4.6-emscripten)
manual.pdf |manual.html✨
DESCRIPTION |NEWS
card.svg |card.png
softcats/json (API)
| # Install 'softcats' in R: |
| install.packages('softcats', repos = c('https://cran.r-universe.dev', 'https://cloud.r-project.org')) |
Bug tracker:https://github.com/mtkurbucz/softcats/issues
Pkgdown/docs site:https://mtkurbucz.github.io
Last updated from:80b8befe06. Checks:6 OK. Indexed: yes.
| Target | Result | Time | Files | Syslog |
|---|---|---|---|---|
| linux-devel | OK | 215 | ||
| source / vignettes | OK | 250 | ||
| linux-release | OK | 162 | ||
| windows-devel | OK | 93 | ||
| windows-release | OK | 122 | ||
| wasm-release | OK | 97 |
Exports:calibration_checkcompare_harddrift_sensitivityexclusion_testglancekappa_curvelrn_customlrn_glmnetlrn_lmlrn_rangerrecalibratescore_spectrumsim_softcatssoft_checksoft_lmtidy
Readme and manuals
Help Manual
| Help page | Topics |
|---|---|
| Check Conditional Calibration on Labelled Data | calibration_check plot.softcats_calibration print.softcats_calibration |
| Compare with Regressions on Predicted Labels | compare_hard print.softcats_hard |
| Sensitivity of the Estimate to Calibration Error | drift_sensitivity print.softcats_sensitivity |
| Test Whether Classifier Features Affect the Outcome Directly | exclusion_test print.softcats_exclusion |
| Attenuation of Hard Labels Across Confidence Thresholds | kappa_curve plot.softcats_kappa print.softcats_kappa |
| Nuisance Learners | learners lrn_custom lrn_glmnet lrn_lm lrn_ranger print.softcats_learner |
| Recalibrate the Class Probabilities on Labelled Data | predict.softcats_recalibration print.softcats_recalibration recalibrate |
| Information in the Scores Beyond the Controls | print.softcats_spectrum score_spectrum |
| Simulate Data with Calibrated Class Probabilities | sim_softcats |
| Diagnostic Report for a softcats Fit | print.softcats_check soft_check |
| Regression on Predicted Categories with Calibrated Class Probabilities | soft_lm |
| Methods for softcats Fits | coef.softcats confint.softcats fitted.softcats formula.softcats glance.softcats nobs.softcats plot.softcats print.softcats print.summary.softcats residuals.softcats softcats-methods summary.softcats tidy.softcats vcov.softcats |
