Skip to content

Commit

Permalink
Update for CRAN release.
Browse files Browse the repository at this point in the history
  • Loading branch information
jbryer committed Oct 23, 2023
1 parent 65f25a1 commit ca8dbc9
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 9 deletions.
1 change: 1 addition & 0 deletions .Rbuildignore
Original file line number Diff line number Diff line change
Expand Up @@ -20,3 +20,4 @@ build.R
^CRAN-SUBMISSION$
README.Rmd
Poster/
doc/
16 changes: 8 additions & 8 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,21 +1,21 @@
Type: Package
Package: PSAboot
Title: Bootstrapping for Propensity Score Analysis
Version: 1.3.7
Date: 2023-04-15
Version: 1.3.8
Date: 2023-10-23
Authors@R:
person("Jason", "Bryer", , "jason@bryer.org", role = c("aut", "cre"),
comment = c(ORCID = "0000-0002-2454-0402"))
Maintainer: Jason Bryer <jason@bryer.org>
Description: It is often advantageous to test a hypothesis more than once
in the context of propensity score analysis (Rosenbaum, 2012)
<doi:10.1093/biomet/ass032>. The functions in this package facilitate
bootstrapping for propensity score analysis (PSA). By default, bootstrapping
using two classification tree methods (using 'rpart' and 'ctree'
functions), two matching methods (using 'Matching' and 'MatchIt'
packages), and stratification with logistic regression. A framework
is described for users to implement additional propensity score
methods. Visualizations are emphasized for diagnosing balance;
bootstrapping for propensity score analysis (PSA). By default,
bootstrapping using two classification tree methods (using 'rpart' and
'ctree' functions), two matching methods (using 'Matching' and
'MatchIt' packages), and stratification with logistic regression. A
framework is described for users to implement additional propensity
score methods. Visualizations are emphasized for diagnosing balance;
exploring the correlation relationships between bootstrap samples and
methods; and to summarize results.
License: GPL
Expand Down
4 changes: 4 additions & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# PSAboot 1.3.8

* Fix for change in t.test with paired data to not use the formula notation.

# PSAboot 1.3.7

* Added propensity score weighting.
Expand Down
3 changes: 2 additions & 1 deletion R/balance.R
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,8 @@ balance <- function(psaboot, na.rm = TRUE, pool.fun = mean) {

bal.unadj <- c()
for(i in names(X.trans)) {
ttest <- t.test(cov ~ treat, data=cbind(treat=Tr, cov=X.trans[,i]), paired=FALSE)
# ttest <- t.test(cov ~ treat, data=cbind(treat=Tr, cov=X.trans[,i]), paired=FALSE)
ttest <- t.test(X.trans[,i,drop=TRUE], Tr, paired = FALSE)
bal.unadj[i] <- abs(diff(ttest$estimate) / sd(X.trans[,i]))
}

Expand Down

0 comments on commit ca8dbc9

Please sign in to comment.