calculate_naive_profitability#

API documentation for tradeexecutor.state.statistics.calculate_naive_profitability Python function.

calculate_naive_profitability(total_equity_series, look_back=None, start_at=None, end_at=None)[source]#

Calculate the profitability as value at end - value at start.

Warning

This method assumes there are no deposits or redemptions. See tradeexecutor.visual.equity_curve for more advanced profit calculations.

Parameters:
Returns:

Tuple (Profitability as %, duration of the sample period). (None, None) if we cannot calculate anything yet.

Return type:

Tuple[Optional[float], Optional[Timedelta]]