pfhedge.nn.functional.realized_volatility¶
- pfhedge.nn.functional.realized_volatility(input, dt)[source]¶
Returns the realized volatility of the price. It is square root of
realized_variance()
.- Parameters
input (torch.Tensor) – The input tensor.
dt (torch.Tensor or float) – The intervals of the time steps.
- Shape:
input: \((*, T)\) where \(T\) stands for the number of time steps and \(*\) means any number of additional dimensions.
output: \((*)\)
- Returns
torch.Tensor