Package: rwa 1.0.1

rwa: Perform a Relative Weights Analysis

Perform a Relative Weights Analysis (RWA) (a.k.a. Key Drivers Analysis) as per the method described in Tonidandel & LeBreton (2015) <doi:10.1007/s10869-014-9351-z>, with its original roots in Johnson (2000) <doi:10.1207/S15327906MBR3501_1>. In essence, RWA decomposes the total variance predicted in a regression model into weights that accurately reflect the proportional contribution of the predictor variables, which addresses the issue of multi-collinearity. In typical scenarios, RWA returns similar results to Shapley regression, but with a significant advantage on computational performance.

Authors:Martin Chan [aut, cre]

rwa_1.0.1.tar.gz
rwa_1.0.1.zip(r-4.7-any)rwa_1.0.1.zip(r-4.6-any)rwa_1.0.1.zip(r-4.5-any)
rwa_1.0.1.tgz(r-4.6-any)rwa_1.0.1.tgz(r-4.5-any)
rwa_1.0.1.tar.gz(r-4.7-any)rwa_1.0.1.tar.gz(r-4.6-any)
rwa_1.0.1.tgz(r-4.6-emscripten)
manual.pdf |manual.html✨
DESCRIPTION |NEWS
card.svg |card.png
rwa/json (API)

# Install 'rwa' in R:
install.packages('rwa', repos = c('https://martinctc.r-universe.dev', 'https://cloud.r-project.org'))

Bug tracker:https://github.com/martinctc/rwa/issues

Pkgdown/docs site:https://martinctc.github.io

On CRAN:

Conda:

relative-weightsrwa

6.90 score 16 stars 25 scripts 793 downloads 1 mentions 6 exports 30 dependencies

Last updated from:cb869cfea9. Checks:9 OK. Indexed: yes.

TargetResultTimeFilesSyslog
linux-develOK163
source / vignettesOK232
linux-releaseOK158
macos-releaseOK132
macos-oldrelOK168
windows-develOK105
windows-releaseOK114
windows-oldrelOK108
wasm-releaseOK116

Exports:%>%plot_rwaremove_all_na_colsrwarwa_logitrwa_multiregress

Dependencies:bootclicpp11dplyrfarvergenericsggplot2gluegtableisobandlabelinglifecyclemagrittrpillarpkgconfigpurrrR6RColorBrewerrlangS7scalesstringistringrtibbletidyrtidyselectutf8vctrsviridisLitewithr

Bootstrap Confidence Intervals for Relative Weights Analysis
Introduction | Why Bootstrap for RWA? | The Statistical Challenge | Bootstrap Solution | How significance is assessed | Basic Bootstrap Analysis | Sampling scope | Simple Bootstrap Example | Understanding Bootstrap Output | Advanced Bootstrap Features | Comprehensive Bootstrap Analysis | Bootstrap Parameters | Rescaled Weight Confidence Intervals | Important Considerations | Why Rescaled CIs Are Problematic | Real-World Applications | Diamond Price Analysis | Interpreting Results | Best Practices | 1. Sample Size Guidelines | 2. Confidence Interval Interpretation | 3. Bootstrap Method Selection | Performance Considerations | Bootstrap Speed Tips | Memory Usage | Troubleshooting | Common Bootstrap Issues | Reporting Bootstrap Results | Standard Reporting Format | Example Report | References | Conclusion

Last update: 2026-09-17
Started: 2025-07-14

Introduction to Relative Weights Analysis with the rwa Package
Introduction | Background and Methodology | What is Relative Weights Analysis? | How RWA Works | When to Use RWA | Theoretical Foundation and Methodological Evaluation | Core Methodological Insight | Demonstrating RWA's Theoretical Properties | Current Validity: Why RWA Remains Relevant | Basic Usage | Simple Example with mtcars | Understanding the Output | Interpreting the Results Table | Controlling Output Sorting | Advanced Features | Adding Signs to Weights | Visualization | Survey and Observation Weights | Bootstrap Confidence Intervals | Quick Bootstrap Example | Real-World Example: Diamond Price Analysis | Comparison with Traditional Regression | Methodological Advantages of RWA | 1. Superior to Standard Regression Under Multicollinearity | 2. Avoids Stepwise Selection Problems | 3. More Interpretable than Principal Components | 4. Computational Efficiency vs. Dominance Analysis | Critical Limitations and When to Exercise Caution | 1. Not a Replacement for Theory | 2. The Redundancy Problem | 3. Sample Size and Stability | Best Practices and Recommendations | 1. Sample Size Considerations | 2. Variable Selection and Model Specification | 3. When to Use RWA vs. Alternatives | 4. Reporting Results | Troubleshooting Common Issues | Multicollinearity Warnings | Missing Data | References | Conclusion | Key Takeaways | The Bottom Line

Last update: 2026-09-14
Started: 2025-07-14

Observation weights and missing data
Weighted point estimates | Missing-data contract | Counts and effective sample size | Bootstrap scope and failure policy | Matrix diagnostics

Last update: 2026-09-14
Started: 2026-09-14

Regression Methods: Multiple and Logistic RWA
Introduction | When to Use Each Method | Multiple Regression with rwa_multiregress() | Basic Example with mtcars | Interpreting Multiple Regression Results | Using the applysigns Parameter | Examining Correlation Structures | Logistic Regression with rwa_logit() | Creating a Binary Outcome | Basic Logistic RWA | Interpreting Logistic RWA Results | Logistic RWA with Signs | Using the rwa() Wrapper Function | Auto-Detection of Binary Outcomes | Explicit Method Selection | Additional Features in rwa() | Real-World Example: Iris Dataset | Multiple Regression: Predicting Petal Length | Logistic Regression: Predicting Species | Comparing Methods | Best Practices | 1. Choose the Right Method | 2. Check Your Data | 3. Consider Bootstrap for Inference | Summary | References

Last update: 2026-09-14
Started: 2026-01-22

Evaluating the Tonidandel & LeBreton Relative Weights Analysis Method
Evaluation of the Tonidandel & LeBreton Relative Weights Analysis Method | What is Relative Weights Analysis and How Does it Address Multicollinearity? | Why is this useful for multicollinearity? | Is RWA still a valid approach for evaluating predictor power under multicollinearity? | Strengths of RWA Relative to Other Methods | 1. Superior to Standard Regression Coefficients (under multicollinearity) | 2. Better than Stepwise or Bivariate Ranking | 3. Advantages over Principal Component or Factor Approaches | 4. Comparable Outcome to Dominance Analysis, with Greater Speed and Extras | 5. Proven in Practice and Accessible | Limitations and Comparisons: Where RWA Falls Short or Other Methods Prevail | 1. Not a Replacement for Theory or Causal Insight | 2. Dominance Analysis vs. RWA – a matter of precision vs. practicality: | 3. Multicollinearity still matters if it means redundancy | 4. Sample Size and Sampling Error | 5. Interpretation of Weights – Communication Challenges | 6. When other methods might be considered "superior" | Considerations and Best Practices for Using RWA | 1. Ensure the Model is Well-Specified: | 2. Check Data and Assumptions: | 3. Adequate Sample Size: | 4. Interpreting the Output (Weights): | 5. Comparing Weights and Groups | 6. Use Case Scenarios – when to use RWA | 7. Presenting and Reporting Results: | 8. Be Mindful of Audience: | Summary | References

Last update: 2026-01-20
Started: 2025-07-16