Description Usage Arguments Details Value References See Also Examples

This function calculates the inefficiency factor from the MCMC draws
of *(β, δ)* for ordinal quantile model with more than 3 outcomes. The
inefficiency factor is calculated using the batch-means method.

1 | ```
infactor_or1(x, beta, delta, autocorrelationCutoff)
``` |

`x` |
covariate matrix of dimension |

`beta` |
Gibbs draw of coefficients of dimension |

`delta` |
Gibbs draw of cut-points. |

`autocorrelationCutoff` |
cut-off to identify the number of lags. |

Calculates the inefficiency factor of *(β, δ)* using the batch-means
method.

Returns a list with components

`inefficiencyDelta`

: vector with inefficiency factor for each*δ*.`inefficiencyBeta`

: vector with inefficiency factor for each*β*.

Greenberg, E. (2012). “Introduction to Bayesian Econometrics.” Cambridge University Press, Cambridge. DOI: 10.1017/CBO9780511808920

pracma, acf

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 | ```
set.seed(101)
data("data25j4")
x <- data25j4$x
y <- data25j4$y
k <- dim(x)[2]
J <- dim(as.array(unique(y)))[1]
D0 <- 0.25*diag(J - 2)
output <- quantreg_or1(y = y,x = x, B0 = 10*diag(k), D0 = D0,
mcmc = 40, p = 0.25, tune = 1, display = FALSE)
beta <- output$beta
delta <- output$delta
inefficiency <- infactor_or1(x, beta, delta, 0.5)
# Summary of Inefficiency Factor:
# Inefficiency
# beta_0 1.1008
# beta_1 3.0024
# beta_2 2.8543
# delta_1 3.6507
# delta_2 3.1784
``` |

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.