PyPortfolioOpt will calculate historical return information and can generate a covariance matrix given prices or returns. It can also generate a covariance matrix given a correlation matrix and stdevs. But what about the stdevs? Is there a function to calculate stdevs from historical returns? I don't see this?
You could derive the stdevs taking the square root of the diagonal elements of the covariance matrix, but why not provide a direct function to calculate stdevs? It could be useful to generate a report for a bunch of assets showing the historical return and the stdev (aka volatility) for each asset.
PyPortfolioOpt will calculate historical return information and can generate a covariance matrix given prices or returns. It can also generate a covariance matrix given a correlation matrix and stdevs. But what about the stdevs? Is there a function to calculate stdevs from historical returns? I don't see this?
You could derive the stdevs taking the square root of the diagonal elements of the covariance matrix, but why not provide a direct function to calculate stdevs? It could be useful to generate a report for a bunch of assets showing the historical return and the stdev (aka volatility) for each asset.