View source: R/calc_functions.R
calc_sigma_scaling | R Documentation |
Calculates the sigma scaling of the chain, and optionally plots the result.
calc_sigma_scaling(chain, plot = FALSE)
chain |
Vector of n length, where n is the number of trials or sampler iterations |
plot |
Boolean. Whether to additionally plot the result. |
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.
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.
set.seed(1)
chain1 <- sampler_mh(1, "norm", c(0,1), diag(1))
calc_sigma_scaling(chain1[[1]], plot = TRUE)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.