Description Usage Arguments Details Author(s) See Also Examples
This function calculates the simple volatility estimate of asset returns over a rolling window.
1 |
R |
xts or zoo object of asset returns |
width |
width of rolling window |
The simple volatility of x is defined as
σ = √{\frac{1}{n} ∑_{i=1}^n x_i^2}
Ross Bennett
1 2 3 | data(crsp_weekly)
R <- largecap_weekly[,1:2]
tail(rollSimpleVolatility(R, 10))
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.