ProRealCode Studio is on its way. As soon as it is published, this button will take you straight to its Chrome Web Store page.
Bar replay stops your chart on a bar of the past and hides what came after. Step forward, or let it play, and watch your codes react as if each bar had just closed. On the way, practise buying and selling with paper trades.
1
2
3
4
5
6
7
The list adapts to the chart. On an intraday chart, speed is a multiple of market time: at 1×, a 5-minute bar takes 5 minutes. Nights and weekends are skipped at once. On a daily chart or longer, and on tick or range charts, speed is in bars per second.
| Chart | Speeds offered |
|---|---|
| Intraday | 0.5×, 1×, 2×, 5×, 10×, 60×, 300× |
| Daily and longer, tick, range | 0.5, 1, 2, 5, 20 bars/s |
“1d bars · 1 bar/s · 24 ticks/bar”: daily bars, one per second, each formed in 24 steps. At high speed it reads “closes only (no room for ticks)” and bars appear closed. “off screen” on the readout: the replay bar left the view; scroll the chart yourself.
| You see | Why |
|---|---|
| A dark curtain over the right of the chart | The bars after the replay bar are still on the platform's chart; Studio covers them. The platform's own indicators are covered with them. |
| Your codes stop at the replay bar | They are computed on the bars up to that one only. Walking forward gives the same values as if that history had been computed in one go. |
| Playback stops at the right edge | “reached the last loaded bar”. “Live” takes you back to the present. |
| “instrument or timeframe changed — replay stopped” | You switched the chart. Replay belongs to one instrument and one timeframe. |
1
2
3
4
5
6
7
8
| Question | Answer |
|---|---|
| Opening balance | 10,000. “Reset” brings it back and empties the list. |
| In which unit? | In money when the platform gives the instrument's point value; otherwise in points, marked “pts”. |
| Does “Sell” close my long? | No. “Sell” opens a separate short. To exit a long, use “Close” on its row or “Close all”. |
| When do I lose the book? | When you click “Reset”, or reload the page. Leaving replay, or switching instrument, keeps it; trades on different instruments then show their symbol. |
| Can I trade on the live chart? | No. “Buy”, “Sell” and “Close all” are greyed outside replay. |
| Is it a backtest? | No. Your codes do not trade here; you do, by hand. To test a strategy written in code, see chapter 18. |
“Equity (marked to market)” moves on every bar a position is open: it shows the heat a trade put you through. “Balance (realised)” stays flat while you hold and steps at each exit: it is what you actually banked. Between trades the two lines coincide.
Reopen the strip on the same instrument and timeframe and replay resumes where you were, as long as that bar is on screen: “resumed the saved replay session for this chart”. The paper book does not survive a reload.
The strip takes one chart into the past and covers the bars to come. Your codes see only what was known on the replay bar, and their alerts stay quiet. Paper trades open at the replay price and live in this tab until “Reset” or a reload.
| While replaying | Does |
|---|---|
| Shift + ↓ | Play / pause |
| Shift + → | One bar forward |
| Shift + ← | One bar back |
The replay bar is off screen to the left, or the curtain covers what you look at. Click the arrow and pick a bar in view, or scroll the chart.
Replay is not running: after “Live”, click ▶ to go back in. Or the cursor is in a text field, the editor for instance.
Inside a forming bar the ticks are synthetic, so a mid-bar crossing can appear that the market never made. Look at the bar once it has closed.
The instrument or the timeframe changed, or the chart you replayed stopped being the target chart (chapter 04).
The page was reloaded, or “Reset” was clicked. The book is kept for the life of the tab only.
No. Replay runs on one chart at a time; the others keep their live prices.
Chapter 16 · Alerts from your codes