betaDelta: Example Using the BetaDelta Function
Ivan Jacob Agaloos Pesigan
Source:vignettes/example-beta-delta.Rmd
example-beta-delta.Rmd
In this example, a multiple regression model is fitted using program
quality ratings (QUALITY
) as the regressand/outcome
variable and number of published articles attributed to the program
faculty members (NARTIC
), percent of faculty members
holding research grants (PCTGRT
), and percentage of program
graduates who received support (PCTSUPP
) as
regressor/predictor variables using a data set from 1982 ratings of 46
doctoral programs in psychology in the USA (National Research Council, 1982). Confidence
intervals for the standardized regression coefficients are generated
using the BetaDelta()
function from the
betaDelta
package following Yuan
& Chan (2011) and Jones & Waller
(2015).
df <- betaDelta::nas1982
Fit the regression model using the lm()
function.
object <- lm(QUALITY ~ NARTIC + PCTGRT + PCTSUPP, data = df)
Estimate the standardized regression slopes and the corresponding sampling covariance matrix.
Multivariate Normal-Theory Approach
BetaDelta(object, type = "mvn", alpha = 0.05)
#> Call:
#> BetaDelta(object = object, type = "mvn", alpha = 0.05)
#>
#> Standardized regression slopes with MVN standard errors:
#> est se t df p 2.5% 97.5%
#> NARTIC 0.4951 0.0759 6.5272 42 0.000 0.3421 0.6482
#> PCTGRT 0.3915 0.0770 5.0824 42 0.000 0.2360 0.5469
#> PCTSUPP 0.2632 0.0747 3.5224 42 0.001 0.1124 0.4141
Asymptotic Distribution-Free Approach
BetaDelta(object, type = "adf", alpha = 0.05)
#> Call:
#> BetaDelta(object = object, type = "adf", alpha = 0.05)
#>
#> Standardized regression slopes with ADF standard errors:
#> est se t df p 2.5% 97.5%
#> NARTIC 0.4951 0.0674 7.3490 42 0.0000 0.3592 0.6311
#> PCTGRT 0.3915 0.0710 5.5164 42 0.0000 0.2483 0.5347
#> PCTSUPP 0.2632 0.0769 3.4231 42 0.0014 0.1081 0.4184
Methods
summary
Summary of the results of BetaDelta()
.
summary(mvn)
#> Call:
#> BetaDelta(object = object, type = "mvn")
#>
#> Standardized regression slopes with MVN standard errors:
#> est se t df p 0.05% 0.5% 2.5% 97.5% 99.5%
#> NARTIC 0.4951 0.0759 6.5272 42 0.000 0.2268 0.2905 0.3421 0.6482 0.6998
#> PCTGRT 0.3915 0.0770 5.0824 42 0.000 0.1190 0.1837 0.2360 0.5469 0.5993
#> PCTSUPP 0.2632 0.0747 3.5224 42 0.001 -0.0011 0.0616 0.1124 0.4141 0.4649
#> 99.95%
#> NARTIC 0.7635
#> PCTGRT 0.6640
#> PCTSUPP 0.5276
summary(adf)
#> Call:
#> BetaDelta(object = object, type = "adf")
#>
#> Standardized regression slopes with ADF standard errors:
#> est se t df p 0.05% 0.5% 2.5% 97.5% 99.5%
#> NARTIC 0.4951 0.0674 7.3490 42 0.0000 0.2568 0.3134 0.3592 0.6311 0.6769
#> PCTGRT 0.3915 0.0710 5.5164 42 0.0000 0.1404 0.2000 0.2483 0.5347 0.5830
#> PCTSUPP 0.2632 0.0769 3.4231 42 0.0014 -0.0088 0.0558 0.1081 0.4184 0.4707
#> 99.95%
#> NARTIC 0.7335
#> PCTGRT 0.6426
#> PCTSUPP 0.5353
vcov
Calculate the sampling covariance matrix of the standardized regression slopes.
vcov(mvn)
#> NARTIC PCTGRT PCTSUPP
#> NARTIC 0.005754524 -0.003360334 -0.002166127
#> PCTGRT -0.003360334 0.005933462 -0.001769723
#> PCTSUPP -0.002166127 -0.001769723 0.005585256
vcov(adf)
#> NARTIC PCTGRT PCTSUPP
#> NARTIC 0.004539472 -0.002552698 -0.001742698
#> PCTGRT -0.002552698 0.005036538 -0.001906216
#> PCTSUPP -0.001742698 -0.001906216 0.005914088