API documentation for tradeexecutor.visual.equity_curve.calculate_aggregate_returns Python function.
- calculate_aggregate_returns(equity_curve, freq='BM')#
Calculate strategy aggregatd results over different timespans.
Good to calculate
See Aggregate return for more information what this metric represents.
There are multiple ways to calculate aggregated returns and they give a bit different results. See this article for details: https://quantdare.com/calculate-monthly-returns-with-pandas/
The current simplicist method does not calculate returns for the first and last period.
Monthly returns for each month.
The array is keyed by the end date of the period e.g. July is 2021-07-31.
The first month can be incomplete, so its value is NaN.
- Return type: