Package: twang 2.5

twang: Toolkit for Weighting and Analysis of Nonequivalent Groups

Provides functions for propensity score estimating and weighting, nonresponse weighting, and diagnosis of the weights.

Authors:Matthew Cefalu <[email protected]>, Greg Ridgeway, Dan McCaffrey, Andrew Morral, Beth Ann Griffin, and Lane Burgette

twang_2.5.tar.gz
twang_2.5.zip(r-4.5)twang_2.5.zip(r-4.4)twang_2.5.zip(r-4.3)
twang_2.5.tgz(r-4.4-x86_64)twang_2.5.tgz(r-4.4-arm64)twang_2.5.tgz(r-4.3-x86_64)twang_2.5.tgz(r-4.3-arm64)
twang_2.5.tar.gz(r-4.5-noble)twang_2.5.tar.gz(r-4.4-noble)
twang_2.5.tgz(r-4.4-emscripten)twang_2.5.tgz(r-4.3-emscripten)
twang.pdf |twang.html
twang/json (API)

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

Peer review:

Bug tracker:https://github.com/mattcefalu/twang/issues

Datasets:
  • AOD - Subset of Alcohol and Other Drug treatment data
  • egsingle - US Sustaining Effects study
  • iptwExLong - Example data for iptw function
  • iptwExWide - Example data for iptw function
  • lalonde - Lalonde's National Supported Work Demonstration data
  • lindner - Lindner Center data on 996 PCI patients analyzed by Kereiakes et al.
  • mnIptwExLong - Example data for iptw function (long version, more than two treatments).
  • mnIptwExWide - Example data for iptw function
  • raceprofiling - Traffic stop data

On CRAN:

6.90 score 6 stars 10 packages 159 scripts 2.8k downloads 18 mentions 13 exports 48 dependencies

Last updated 3 years agofrom:9aec6360a4. Checks:ERROR: 1 WARNING: 8. Indexed: yes.

TargetResultDate
Doc / VignettesFAILNov 21 2024
R-4.5-win-x86_64WARNINGNov 21 2024
R-4.5-linux-x86_64WARNINGNov 21 2024
R-4.4-win-x86_64WARNINGNov 21 2024
R-4.4-mac-x86_64WARNINGNov 21 2024
R-4.4-mac-aarch64WARNINGNov 21 2024
R-4.3-win-x86_64WARNINGNov 21 2024
R-4.3-mac-x86_64WARNINGNov 21 2024
R-4.3-mac-aarch64WARNINGNov 21 2024

Exports:bal.statbal.tabledisplayPlotsdx.wtsget.weightsget.weights.numget.weights.unstabiptwmeans.tablemnpspssensitivitystop.methods

Dependencies:clicolorspacedata.tableDBIdeldirfansifarvergbmggplot2gluegtableinterpisobandjpegjsonlitelabelinglatticelatticeExtralifecyclemagrittrMASSMatrixMatrixModelsmgcvminqamitoolsmunsellnlmenumDerivpillarpkgconfigpngR6RColorBrewerRcppRcppArmadilloRcppEigenrlangscalessurveysurvivaltibbleutf8vctrsviridisLitewithrxgboostxtable

Readme and manuals

Help Manual

Help pageTopics
twang: Toolkit for Weighting and Analysis of Nonequivalent Groupstwang-package twang
Subset of Alcohol and Other Drug treatment dataAOD
Calculate weighted balance statisticsbal.stat
Compute the balance table.bal.table
Boxplot for `mnps` objectsboxplot.mnps
Boxplot for `ps` objectsboxplot.ps
Diagnosis of weightsdesc.wts
Display plotsdisplayPlots
Compute diagnostics assessing covariates balance.dx.wts
US Sustaining Effects studyegsingle
Extract propensity score weights.get.weights
Get numerators to stabilize propensity score weights for `iptw` fits.get.weights.num
Extract unstabilized propensity score weights for `iptw` fitsget.weights.unstab
Inverse probability of treatment weighting for marginal structural models.iptw
Example data for iptw function (long version)iptwExLong
Example data for iptw function (wide version)iptwExWide
Lalonde's National Supported Work Demonstration datalalonde
Lindner Center data on 996 PCI patients analyzed by Kereiakes et al. (2000)lindner
Extract table of means from an`mnps` objectmeans.table
Example data for iptw function (long version, more than two treatments).mnIptwExLong
Example data for iptw function (wide version, more than two treatments)mnIptwExWide
Propensity score estimation for multiple treatmentsmnps
Plot 'dxwts'plot.dxwts
Plots for 'iptw' objectsplot.iptw
Plot 'mniptw'plot.mniptw
Plots for 'mnps' objectsplot.mnps
Plots for 'ps' objectsplot.ps
Default print statement for 'dxwts' classprint.dxwts
Default print statement for 'iptw' classprint.iptw
Default print statement for 'mniptw' classprint.mniptw
Default print statement for 'mnps' classprint.mnps
Default print statement for 'ps' classprint.ps
Produces a summary table for 'iptw' objectprint.summary.iptw
Produces a summary table for 'mniptw' objectprint.summary.mniptw
Produces a summary table for 'mnps' objectprint.summary.mnps
Produces a summary table for 'ps' objectprint.summary.ps
Gradient boosted propensity score estimationps
Traffic stop dataraceprofiling
Function to run sensitivity analysis described in Ridgeway's paper; currently works only for ATT.sensitivity
Stop methods (e.g. "es.mean", "ks.mean", etc.) object, used only for backward compatibilitystop.methods
Summarize a 'iptw' objectsummary.iptw
Summarize a 'mniptw' objectsummary.mniptw
Summarize a 'mnps' objectsummary.mnps
Summarize a 'ps' objectsummary.ps