OmniTrader Professional Forum OmniTrader Professional Forum
forums calendars search
today this week
 
register logon control panel Forum Rules
You are currently browsing as a guest.
You should logon to access more features
A Self-Moderated Community - ALL MEMBERS, PLEASE READ!
Vote for Members who contribute the most to your trading, and help us moderate content within the Forums.


  Current location        Thread information  
OmniTrader Pro Resource Forum
OmniTrader Pro Technical Support
Strange behaviour of exits in RT
Last Activity 12/11/2024 2:57 PM
21 replies, 1179 viewings

Jump to page : 1
Now viewing page 1 [25 messages per page]
 
back reply
Printer friendly version

^ Top
Frank Birch

Veteran
1002525
Posts: 171

Joined: 3/25/2006
Location: UK

User Profile
 
Subject : Strange behaviour of exits in RT
Posted : 12/13/2022 11:53 AM
Post #32148

Hi to all,

I've got 2 screen shots of trades placed on the futures in RT.
There seems to odd behaviour on the exits on the 6S its clear the breakeven stop took the trade out for a small gain.
but the 6J is a different matter its clear from the signal generated to the break even stop & trailing profit stop there shows a profit all be it small but clicking on the vote line it shows a loss?
it shouldn't do and in the dialog box its saying trade generated stop?? no mention of either trailing profit stop which got hit and the breakeven stop got hit so there should be a small profit?

I've attached the screen shot and trade plan so all help will be great help.

Regards

Frank Birch
Attached file : 13-Dec-22 17-43-40 6J.png (177KB - 152 downloads)
Attached file : 13-Dec-22 17-44-16 6S.png (170KB - 143 downloads)
Attached file : SysTrade RT TP.ott (96KB - 134 downloads)

^ Top
Frank Birch

Veteran
1002525
Posts: 171

Joined: 3/25/2006
Location: UK

User Profile
 
Subject : RE: Strange behaviour of exits in RT
Posted : 12/14/2022 11:40 AM
Post #32150 - In reply to #32148

Hi to all,

I've just spoken to my trading Partner Jerry Sigalow about this issue and as he trades the same plug-in, he showed a loss on the vote line on the 6J but with omni pilot straight to IB Brokers shows a gain??

The question you have to ask is? this affects all equity curves either end of day and real time??

Regards

Frank Birch

[Edited by Frank Birch on 12/14/2022 11:46 AM]

^ Top
Frank Birch

Veteran
1002525
Posts: 171

Joined: 3/25/2006
Location: UK

User Profile
 
Subject : RE: Strange behaviour of exits in RT
Posted : 12/14/2022 2:39 PM
Post #32151 - In reply to #32150

Hi to all,

its clear that the breakeven stop go hit! and it shows not filled????
there is a clear problem with the trade plan sorry to say?

Regards

Frank Birch





















[Edited by Frank Birch on 12/14/2022 2:41 PM]

Attached file : 14-Dec-22 20-34-35 not filled.png (249KB - 121 downloads)

^ Top
Barry Cohen

Idol
2000100100100
Posts: 2305

Joined: 1/1/1900

User Profile
 
Subject : RE: Strange behaviour of exits in RT
Posted : 12/14/2022 5:33 PM
Post #32153 - In reply to #32148

Frank, look at your trade plan again. It contains a broker stop market order & that's what got hit on 6J. The fact that another stop was hit first in the live market just means that one stop was hit before the the stop loss, but backtesting doesn't have the tick by tick luxury that a live market has. It only has the full bar to work with.


Attached file : FrankStop.jpg (68KB - 542 downloads)

^ Top
Frank Birch

Veteran
1002525
Posts: 171

Joined: 3/25/2006
Location: UK

User Profile
 
Subject : RE: Strange behaviour of exits in RT
Posted : 12/15/2022 11:54 AM
Post #32155 - In reply to #32153

Hi Barry & all,

I am a little lost here sorry to say? I knew it was the broker stop that got hit but price has gone through the trailing profit stop? breakeven stop & fixed loss stop?
and its taken the price of the broker stop to the vote line?
my question is that omni pilot took this trade out on the trailing profit stop tick perfect & correctly and as it should but the vote line didn't?
so to me there is a fault with the trade plan & vote line am I correct?
the other question is that vit doesn't do it all the time?

Regards

Frank Birch

^ Top
Barry Cohen

Idol
2000100100100
Posts: 2305

Joined: 1/1/1900

User Profile
 
Subject : RE: Strange behaviour of exits in RT
Posted : 12/19/2022 11:52 AM
Post #32156 - In reply to #32155

It works on the right edge, because as data is coming in, OT knows which stop is triggered first since the bar is built in real time. But on the voteline it cannot know that since it only has the full bar to work from. There is no way for OT to know in backtesting which stop was triggered first when multiple stops are hit on a single bar.
^ Top
Frank Birch

Veteran
1002525
Posts: 171

Joined: 3/25/2006
Location: UK

User Profile
 
Subject : RE: Strange behaviour of exits in RT
Posted : 12/19/2022 5:08 PM
Post #32158 - In reply to #32156

Hi Barry & all,

so in depth to this the vote line lies in real time??

Regards

Frank Birch
^ Top
Frank Birch

Veteran
1002525
Posts: 171

Joined: 3/25/2006
Location: UK

User Profile
 
Subject : RE: Strange behaviour of exits in RT
Posted : 12/19/2022 5:19 PM
Post #32159 - In reply to #32158

Hi Barry & all,

on any given signal fired by the vote line it is on Close of Bar? using the
trade plan we have the ability to use MARKET meaning when price has met the exit criteria we close the trade intra bar to the vote line?
so in theory we should use close of bar like the entry signal?
ive attached the same trade with in the test profile and same its at a loss but a test profile isnt tick by tick i am lost here to why the market order doesnt close a profitable trade?

Regards

Frank Birch


[Edited by Frank Birch on 12/20/2022 12:48 AM]

Attached file : 20-Dec-22 06-43-51 6J test.png (233KB - 125 downloads)

^ Top
Barry Cohen

Idol
2000100100100
Posts: 2305

Joined: 1/1/1900

User Profile
 
Subject : RE: Strange behaviour of exits in RT
Posted : 12/22/2022 10:14 AM
Post #32161 - In reply to #32159

Not exactly. Some stops work different than others, & it also depends on the order type.
^ Top
Frank Birch

Veteran
1002525
Posts: 171

Joined: 3/25/2006
Location: UK

User Profile
 
Subject : RE: Strange behaviour of exits in RT
Posted : 12/22/2022 11:33 AM
Post #32162 - In reply to #32161

Hi Barry & all,

All the exits are @ Market.
The big question is? the broker stop is what got hit, isn't that meant to be a last result just for the broker?
so it went through trailing profit stop(active) breakeven stop (active) fixed loss stop (hit) yet it still went further.
What would of happened if I didn't have the broker stop in place?? could of gone even further perhaps?
I understand your very busy and all help is good help but at the end of the day a said trade that should be in profit shows a loss I ask questions?
The trade plan is on point with exits and order types so there must be a bug because its random.

Regards

Frank Birch

^ Top
Barry Cohen

Idol
2000100100100
Posts: 2305

Joined: 1/1/1900

User Profile
 
Subject : RE: Strange behaviour of exits in RT
Posted : 12/22/2022 5:10 PM
Post #32163 - In reply to #32162

Again, when multiple stops are triggered on the same bar, there's no current possible way for OT to know which stop was hit first on the voteline.

In real trading, on a single bar, price could hit your profit stop first then go back the other way & breach your loss stop, or vice versa. In backtesting (aka Voteline, aka Port Sim) OT has no knowledge of price movement within a single bar, so it has to follow some kind of rule for when those cases occur.

In OT, the rule is that when multiple stops are breached on a single bar, backtesting always chooses the stop nearest to the entry price.

That being said, it doesn't look like that rule was followed in your example. If you look at the last screenshot showing the price it was hit, it shows price of 0.01 while it calculates the Gain/Loss at the actual price of 0.007372929. Most likely there's a bug with the 0.01 being rounded when it shouldn't be, which would you would see in cases like this. I bet that's what it is & I can report that.

^ Top
Frank Birch

Veteran
1002525
Posts: 171

Joined: 3/25/2006
Location: UK

User Profile
 
Subject : RE: Strange behaviour of exits in RT
Posted : 12/26/2022 3:41 AM
Post #32165 - In reply to #32163

Hi Barry & all,

Again, when multiple stops are triggered on the same bar, there's no current possible way for OT to know which stop was hit first on the vote line.

Ok Barry I full understand this now, at least omni pilot takes us out.

In real trading, on a single bar, price could hit your profit stop first then go back the other way & breach your loss stop, or vice versa. In back testing (aka Voteline, aka Port Sim) OT has no knowledge of price movement within a single bar, so it has to follow some kind of rule for when those cases occur.

in the screen shots attached i have noticed that when price has advanced or declined and its just the tail of the the wick touching any exit and close is above or below any exit then the vote line works correctly its the full body price bar it cant handle.

In OT, the rule is that when multiple stops are breached on a single bar, backtesting always chooses the stop nearest to the entry price.

Here is where it gets interesting, I have gone through multiple charts in RT and found out of 61 trades over 2 months the THE TRADE PLAN GENERATED STOP has been activated? out of 61 trades 11 trades have used the trade plan generated stop? now then I then went over to the test profile and retested the same time period and its exactly the same in the test profile so where you say it takes the nearest stop activated it doesn't?? in the test profile its still using a trade plan generated stop? clearly when its a profitable trade.

That being said, it doesn't look like that rule was followed in your example. If you look at the last screenshot showing the price it was hit, it shows price of 0.01 while it calculates the Gain/Loss at the actual price of 0.007372929. Most likely there's a bug with the 0.01 being rounded when it shouldn't be, which would you would see in cases like this. I bet that's what it is & I can report that.

Ok that's one fault found great news.

So this problem with the trade generated stop exists in both a real time profile and test profile now meaning the port folio simulation report is in correct by over 15% on any winning or losing trade that has a full bar?
I've attached a screen shot for the same trade in a real time profile and test profile its clearly a winning trade.

So in theory the equity curve attached should be 15% better on ROI and with less drawdown?

I know I am a pain and I know your busy but there is a problem here I know.

Regards

Frank Birch
Attached file : 26-Dec-22 08-46-53 WICK.png (290KB - 123 downloads)
Attached file : 26-Dec-22 08-48-45 FULL BODY.png (300KB - 135 downloads)
Attached file : 26-Dec-22 09-07-31 same trade same result.png (324KB - 120 downloads)
Attached file : 26-Dec-22 09-08-37 port sim.png (377KB - 120 downloads)
Attached file : 26-Dec-22 09-18-56 2 months.png (376KB - 125 downloads)

^ Top
Frank Birch

Veteran
1002525
Posts: 171

Joined: 3/25/2006
Location: UK

User Profile
 
Subject : RE: Strange behaviour of exits in RT
Posted : 1/4/2023 1:32 PM
Post #32166 - In reply to #32165

Hi Barry & all,

I know I am a pain but new year new start!
As mentioned in the previous post this Trade plan generated stop isn't going away to soon.
Not only in a RT profile but also over in into the test profile making back test results invalid.
I see this as a serious fault of the vote line.

Regards

Frank Birch

[Edited by Frank Birch on 1/4/2023 1:34 PM]

Attached file : 04-Jan-23 19-29-12 trade plan generated stop.png (65KB - 122 downloads)

^ Top
Frank Birch

Veteran
1002525
Posts: 171

Joined: 3/25/2006
Location: UK

User Profile
 
Subject : RE: Strange behaviour of exits in RT
Posted : 2/20/2023 1:20 PM
Post #32201 - In reply to #32163

Hi Barry,
is there any update on exit fault to vote line?

Regards

Frank Birch
^ Top
Frank Birch

Veteran
1002525
Posts: 171

Joined: 3/25/2006
Location: UK

User Profile
 
Subject : RE: Strange behaviour of exits in RT
Posted : 2/21/2023 1:41 PM
Post #32204 - In reply to #32201

Hi to all,

I've attached a chart of the ES today trading a mechanical strategy using omni pilot.

If you look at the chart you will see that the fixed loss stop is a tick or 2 off the omni pilot fixed loss stop.
Then take a look at the breakeven stop which replicates a tick or 2 off like the fixed loss stop (horizontal lines)

Now here is the crunch! look at the trailing profit stop it doesn't replicate the vote line trailing profit stop to omni pilot profit stop!!
How can we build strategies to use in real time when the vote line doesn't replicate the omni pilot???
if it was a tick or 2 off but look at the trailing profit stop (vote line) its on a different planet omni pilots marker order???

so the question I ask is how can we near replicate each stops against the vote line to omni pilot other so we can match our back test results to a real trade??

Regards

Frank Birch
Attached file : 21-Feb-23 19-25-06 ES exits.png (179KB - 125 downloads)

^ Top
mholstius

Regular
252525
Posts: 76

Joined: 6/15/2011

User Profile
 
Subject : RE: Strange behaviour of exits in RT
Posted : 2/21/2023 5:08 PM
Post #32205 - In reply to #32204

Hi, Frank...
Don't know if this helps, but it looks like the trail is based on the close of the previous bar - but I don't know what omnipilot is using for the trail.
See attachment.
Mark
Attached file : Trail.jpg (365KB - 131 downloads)

^ Top
Frank Birch

Veteran
1002525
Posts: 171

Joined: 3/25/2006
Location: UK

User Profile
 
Subject : RE: Strange behaviour of exits in RT
Posted : 2/22/2023 12:44 AM
Post #32206 - In reply to #32205

Hi Mark and all,

ive doubled checked the trade plan and its the market order all the way!
if you get a big move from the off and keeps going then the trailing profit is in tune with omnipilot to vote line its only when you get a meandering trade like the example?

Regards

Frank
^ Top
Barry Cohen

Idol
2000100100100
Posts: 2305

Joined: 1/1/1900

User Profile
 
Subject : RE: Strange behaviour of exits in RT
Posted : 3/1/2023 2:00 PM
Post #32212 - In reply to #32201

is there any update on exit fault to vote line?


I do not have any updates on that issue at this time.
^ Top
Frank Birch

Veteran
1002525
Posts: 171

Joined: 3/25/2006
Location: UK

User Profile
 
Subject : RE: Strange behaviour of exits in RT
Posted : 3/8/2023 11:50 AM
Post #32214 - In reply to #32212

Hi Barry & all,
I understand your all busy over there but don't you think this is a major issue in every way?

I've found another issue with the vote line now its taken trades out to early but still calculating the fixed loss stop @ price of exit even thou the short trades HIGH didn't even touch the fixed loss stop??

Chart attached.

on the 2nd chart I have a port sim, now it doses make big money I agree but it could show a lot more.
say out of 1000 trades, we show a 75% hit rate? meaning 250 trades lose? now if the fixed loss stop is hit that would mean 250 * 4 ATR,s (fixed loss stop) but the vote line is showing the broker stop which is 5 ATR,s away meaning this equity curve is giving away an extra 250*1 +250 ATR,s of extra loss period!!

Is this bug isolated to just real time or end of day as well?

This exit problem should be classed as priority?
Entry is the easy bit exits where the money is at.

Regards

Frank Birch

Attached file : 08-Mar-23 16-41-06 New exit issue.png (370KB - 126 downloads)
Attached file : 08-Mar-23 17-30-36 bug.png (473KB - 121 downloads)

^ Top
Barry Cohen

Idol
2000100100100
Posts: 2305

Joined: 1/1/1900

User Profile
 
Subject : RE: Strange behaviour of exits in RT
Posted : 3/9/2023 10:14 AM
Post #32216 - In reply to #32214

I would describe a major issue as one that affects a large percentage of users using the software, or one that negatively affects right edge trading, or some kind of cheat that affects a large group of users too.

Is this bug isolated to just real time or end of day as well?


I'm not sure the timeframe matters here, it's a backtest issue with voting in a very particular scenario.

I've found another issue with the vote line now its taken trades out to early but still calculating the fixed loss stop @ price of exit even thou the short trades HIGH didn't even touch the fixed loss stop??


Your Fixed Loss stop was not touched in this example. What was triggered was a stop market order that isn't set to a particular stop. This is what was triggered & this type of order is NOT displayed in the chart.


Attached file : FrankStop2.jpg (86KB - 293 downloads)

^ Top
Frank Birch

Veteran
1002525
Posts: 171

Joined: 3/25/2006
Location: UK

User Profile
 
Subject : RE: Strange behaviour of exits in RT
Posted : 4/10/2023 4:52 AM
Post #32226 - In reply to #32216

Hi Barry & all,

I thought it would be an advantage to those that trade real time on my findings on this issue.
Firstly Barry made the call on the broker stop having no name? that got me thinking.
So instead of just a line of orders to send to the broker I then changed this to another fixed loss stop! (Chart attached)
so the first stop from entry is the vote line stop set @ 4 ATR,s away.
The 2nd stop is set to 5 ATR,s away (an extra 1 ATR away this now becomes your broker stop)
Then this stop has been enabled as broker stop added to it! (has a name now)(trade plan screen shot attached).

Now if you are using the old way as I was (screen attached) and you trade real time to your broker I highly advise the change in your trade plan.
With this fix in place your vote line will marry up with your broker price with in a tick or 2 and show true calculations in your testing in your port sim.
I don't know if this problem exists in end of day but certainly in real time.
This revised trade plan is being used to trade real time to IB Brokers and is seamless and the vote line problem fixed.
Thanks Barry on naming the problem.

Regards

Frank Birch


[Edited by Frank Birch on 4/10/2023 4:55 AM]

Attached file : 10-Apr-23 10-26-12 Broker stop.png (90KB - 121 downloads)
Attached file : 10-Apr-23 10-32-12 broker stop 2.png (468KB - 125 downloads)
Attached file : 10-Apr-23 10-47-36 broker stop 3.png (420KB - 123 downloads)

^ Top
jsigalow

Member
25
Posts: 34

Joined: 3/4/2006
Location: Poughkeepsie,N.Y.

User Profile
 
Subject : RE: Strange behaviour of exits in RT
Posted : 4/10/2023 6:59 AM
Post #32227 - In reply to #32148

the new tradeplan works seamlessly. now if the vote line repplicates the trae plan and doesnt use end of bar we can see a true equity curve
Jerry Sigalow



Jump to page : 1
Now viewing page 1 [25 messages per page]
back reply

Legend    Action      Notification  
Administrator
Forum Moderator
Registered User
Unregistered User
E-Mail this thread to a friend
Toggle e-mail notification


Nirvana Systems
For any problems or issues please contact our Webmaster at webmaster@nirvsys.com.