gammaToBeta {WALS} | R Documentation |
Internal function: Transform gammas back to betas
Description
Transforms posterior means and variances corresponding
to transformed auxiliary regressors
back to regression coefficients
of original regressors
and
.
Usage
gammaToBeta(
posterior,
y,
Z1,
Z2,
Delta1,
D2,
sigma,
Z1inv,
method = "original",
svdZ1
)
Arguments
posterior |
Object returned from |
y |
Response |
Z1 |
Transformed focus regressors |
Z2 |
Transformed auxiliary regressors |
Delta1 |
|
D2 |
From |
sigma |
Prespecified or estimated standard deviation of the error term. |
Z1inv |
|
method |
Character. |
svdZ1 |
Optional, only needed if |
Details
The same transformations also work for GLMs, where we replace ,
,
and
with
,
,
and
, respectively. Generally, we need to
replace all variables with their corresponding "bar" version. Further,
for GLMs
sigma
is always 1.
See Magnus and De Luca (2016), De Luca et al. (2018) and Huynh (2024b) for the definitions of the variables.
References
De Luca G, Magnus JR, Peracchi F (2018).
“Weighted-average least squares estimation of generalized linear models.”
Journal of Econometrics, 204(1), 1–17.
doi:10.1016/j.jeconom.2017.12.007.
Huynh K (2024b).
“WALS: Weighted-Average Least Squares Model Averaging in R.”
University of Basel.
Mimeo.
Magnus JR, De Luca G (2016).
“Weighted-average least squares (WALS): A survey.”
Journal of Economic Surveys, 30(1), 117-148.
doi:10.1111/joes.12094.