Announcement
Collapse
No announcement yet.
Partner 728x90
Collapse
NinjaTrader
Chart doesnt show trade
Collapse
X
-
Chart doesnt show trade
I loaded my strategy and it took the trade when it should ...sent to my broker... also same strategy is loaded on tradingview.. it also took the trade... the log file shows it took the trade.. however later on when i reload the strategy it doesnt show it anymore on the chart.. even the candles etc are the same? Why would it disappear from screen now when strategy is enabled later on or screen was refreshed.. out put still shows it i believeLast edited by SevanKambel; 03-30-2023, 06:33 PM.Tags: None
-
-
Hello SevanKambel,
You need to leave the strategy enabled to be able to view its performance, if you reload the strategy that will clear the previous trades it made and then it has to re process the historical data again. If the strategy doesn't work exactly the same historically as it did in realtime then it may not re produce the same trade on the chart. The live trade it originally made would now be considered a historical trade when the strategy processes that time again, if it does not place a historical trade during processing then nothing will appear on the chart.
Comment
-
can i go back and see these historical trades on the chart? Its weird some stay but some disappear when i re enable the strategy ..almost makes me afraid its not working properly as now its saying it wouldnt have taken that trade.. or atleast thats how that appears
Comment
-
So realistically your back-test are not accurate??Originally posted by NinjaTrader_Jesse View PostHello SevanKambel,
You need to leave the strategy enabled to be able to view its performance, if you reload the strategy that will clear the previous trades it made and then it has to re process the historical data again. If the strategy doesn't work exactly the same historically as it did in realtime then it may not re produce the same trade on the chart. The live trade it originally made would now be considered a historical trade when the strategy processes that time again, if it does not place a historical trade during processing then nothing will appear on the chart.
Comment
-
Of course, it is not accurate. Does that surprise you?Originally posted by SevanKambel View PostSo realistically your back-test are not accurate??
But now you have to define what you mean by 'accurate'?
If you want 100% accuracy, forget it. Live markets have too many
movements where sitting orders are left behind. Consider when
market price changes direction, some sitting orders may get filled
at the 'turning' price and some may not -- some may partially fill.
The point is, you may see live market price 'touch' your limit order
or stop order price, but yet your order does not fill.
How should back-testing software mimic that?
Back-testing should always be taken with a grain of salt.
Comment
-
Hello SevanKambel,
You can use the New -> Trade Performance to view the actual live trades your strategy made, that view will contain all execution data.
That can happen based on what you coded and what settings you are using. A very simple example would be running a strategy that uses OnEachTick calculation in realtime. Historically that property is not available because historical data is less granular than realtime, that would result in the strategies OnBarUpdate code being run differently for historical bars and realtime bars. That would produce the result that you are seeing where in realtime the condition becomes true at a certain time but when you re run the strategy it no longer places a trade at that time. The problem is not that the backtest is not accurate the problem is that the code was executed differently based on the settings of the strategy. That is very likely what you are seeing based on either the settings you are using or the condition/code in the script.Its weird some stay but some disappear when i re enable the strategy ..almost makes me afraid its not working properly as now its saying it wouldnt have taken that trade.. or atleast thats how that appears
Here is a good post about the differences that you would see between historical and live modes which includes details on how you can debug your code to better understand the differences that you see: https://ninjatrader.com/support/foru...ay-performance
You can also find some common discrepancies that you would run into here: https://ninjatrader.com/support/help...lightsub=discr
Comment
Latest Posts
Collapse
| Topics | Statistics | Last Post | ||
|---|---|---|---|---|
|
Started by NullPointStrategies, Today, 05:17 AM
|
0 responses
25 views
0 likes
|
Last Post
|
||
|
Started by argusthome, 03-08-2026, 10:06 AM
|
0 responses
121 views
0 likes
|
Last Post
by argusthome
03-08-2026, 10:06 AM
|
||
|
Started by NabilKhattabi, 03-06-2026, 11:18 AM
|
0 responses
64 views
0 likes
|
Last Post
|
||
|
Started by Deep42, 03-06-2026, 12:28 AM
|
0 responses
41 views
0 likes
|
Last Post
by Deep42
03-06-2026, 12:28 AM
|
||
|
Started by TheRealMorford, 03-05-2026, 06:15 PM
|
0 responses
46 views
0 likes
|
Last Post
|

Comment