Run your first Algo Lab baseline
This path starts from the New Strategy Pine tab created for a clean account. Your done state is one completed baseline that you can add to a case study.
Before you start
Section titled “Before you start”- Algo Lab requires a Basic or Professional subscription. An active trial counts when it grants Professional access.
- Connect Alpaca in Account Integrations so the lab can request historical bars. If the app explicitly shows platform market data as available, you can use that instead.
- The starter code is a
strategy()script. If you replace it, use another strategy, not an indicator-only script.
Run the baseline
Section titled “Run the baseline”-
Open Algo Lab and select the New Strategy tab.
-
In the test scope, choose the connected data source, a symbol it supports, a timeframe, and a short date range. Record these choices; they define the baseline.
-
Select Refresh to load bars for that scope. Confirm that the chart or data status shows bars before continuing.
-
Select Run. After a code or scope change, the same control may read Re-run.
-
Review the trade count, warnings, date range, and strategy settings before interpreting return or risk metrics. A completed run only proves that this code executed on this data and configuration.
-
Select Add to Case Study and either create a case study or choose an existing one. Give the baseline a name that includes the symbol and timeframe.
-
When you preserve a later candidate, use Load into tab name to return it to its linked Pine tab. The final words change to the actual tab name.
If the run does not start
Section titled “If the run does not start”| Symptom | Check |
|---|---|
| Refresh cannot load bars | Confirm the Alpaca connection, symbol entitlement, timeframe, and date range |
| Run is disabled | Confirm bars are loaded and the active code declares strategy() |
| No trades appear | Expand the date range and inspect whether the entry conditions occur; zero trades is still evidence |
| Results differ from TradingView | Align symbol, timeframe, session, date range, commission, slippage, and strategy settings |
Next step
Section titled “Next step”Use the baseline as a fixed reference before changing code or parameters. When TradingView alert data exists, compare the backtest with alerts to investigate whether live signal generation agrees with historical intent.