Repository navigation
PowerBridge 0.9.0
About the version history. 0.1 to 0.9 were the first public releases of a tool developed privately, cut over a few days as each batch of verified features landed. From here, releases are spaced out and made when there is enough new content. See the CHANGELOG.
Highlights:
--max-bars-back autoworks out the strategy's lookback for you (#163).- Series functions such as
Averagetake arithmetic, offset and nested-call price arguments and give the correct result (#165, #167). crosses above/crosses belowcompare the right bars when MaxBarsBack skips bars (#161).- Several programs that the native kernel ran differently from Python now fall back to Python (#153, #155).
- Some programs give different, correct results; see the behaviour changes under Fixed (#159, #161, #167).
Fixed
- Behaviour change. A series function whose price argument is arithmetic or a nested call now uses that argument's own per-bar history; before,
Average(Value1 * 2, 5)andAverage(Value1 + Value1, 5)silently gave wrong values andAverage(Average(Close - 1, 3), 5)raisedTypeError. Results change for price arguments that add two series or variables (High + Low,Close + Value1) or multiply one by a whole number (Close * 2,2 * MyVar); plain arguments are unchanged, and an argument that reads a variable inside anIf, loop,Once,Switch,IFForand/orstops with an error (exit 2) (#167). - Indicator calls that crashed at run time now run or stop with a one-line error (exit 2):
Average((High + Low) / 2, 10),Highest(Close[5], 10),Average(Range, 5),Range[2],TrueRange[2]andVariance(Price, Length, DataType)run on the Python path. A negative TgtBar inLinearRegValuestops with an error; programs that ran before are unchanged (#165). - Behaviour change.
crosses above/crosses belowbetween a variable and a price series or function result (AvgC crosses Close) compared the wrong bars under MaxBarsBack above 0 on both paths and now gives a different, correct result. It no longer raisesIndexErroron the Python path; crosses between two series, two variables or two functions, and all runs with MaxBarsBack 0, are unchanged (#161). - Behaviour change (Python path). A variable declared with a negative initial value (
Vars: TLID(-1);) is now numeric, so drawing ids compared or passed to getters no longer raiseTypeError. Programs that compared such a variable to its initial value or relied on its full double precision now give a different result, matching the native kernel;Date[n]/Time[n]before the start of the tape read 0 instead of raising (#159). - A drawing anchor that is not a bar on the tape (e.g.
TL_New(Date[1], Time[1], ...)on bar 1) no longer fails; both paths record it with a nullbnand the drawing dumps match.--explain-nativenow says it is a compile-time check (#157). - The native kernel runs
EntryName(n)/ExitName(n)and the bracket form of an input (Len[1]), so inputs such asExitTime(1555)no longer refuse with "bar_ref series" (#153). - The native kernel refuses a program that reads an input named like a per-bar runtime key (
Inputs: MaxShares(2)) and falls back to Python, which gave different trades before;--explain-nativenames the collision (#153). - The native kernel refuses a program that reads an
OutPathinput outside a file path and falls back to Python, which gave different results before;Print(File(OutPath), ...)still runs natively (#155).
Added
--max-bars-back autoonpl_oracleandpl_run(andmax_bars_back="auto"inrun_oracle/run_el) uses the lookback inferred from the source, shows it on the status line (max-bars-back 11 (auto)) and stops with an error naming the construct when it cannot be inferred. Without the flag results are unchanged; only the stderr warm-up note's wording changes (#163).