Login Page - Create Account

Support Board


Date/Time: Sat, 23 Nov 2024 22:49:38 +0000



Post From: sc.IsSwingLow not working in Replay Backtest

[2024-07-27 01:12:54]
User725043 - Posts: 35
Appreciate the comments, and yes have tried the IndexToEvaluate method in Studies6.cpp. Trying to understand the at current bar method, or perhaps this has been deprecated by SC?

The documentation shows 2 types of calls:
int IsSwingLow(SCFloatArrayRef FloatArrayIn, int Index, int Length);

int IsSwingLow(SCFloatArrayRef FloatArrayIn, int Length); Auto-looping only.

My study is set in sc.SetDefaults to:
  sc.AutoLoop = 1;

In the Replay backtest, after the initial calculation, sc.IsSwingLow just remains at 0. This makes results of the Bar(which works) vs Replay backtests significantly divergent.