calc_sigma_scaling {samplr} | R Documentation |
Sigma Scaling Calculator
Description
Calculates the sigma scaling of the chain, and optionally plots the result.
Usage
calc_sigma_scaling(chain, plot = FALSE)
Arguments
chain |
Vector of n length, where n is the number of trials or sampler iterations |
plot |
Boolean. Whether to additionally plot the result. |
Details
Sigma scaling is defined as the slope of the regression connecting log time lags and the standard deviation of value changes across time lags. Markets show values of 0.5.
Value
A list containing the vector of possible lags, the sd of the distances at each lag, their log10 counterparts, and the calculated intercept and slope.
Examples
set.seed(1)
chain1 <- sampler_mh(1, "norm", c(0,1), diag(1))
calc_sigma_scaling(chain1[[1]], plot = TRUE)
[Package samplr version 1.0.1 Index]