OmniTrader Forum OmniTrader 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 Archives
OmniTrader 2018 Technical Support
ATS Trade Ranking Issue
Last Activity 5/11/2020 10:43 AM
22 replies, 3454 viewings

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

^ Top
Vinay

Elite
50010025
Posts: 640

Joined: 12/9/2011
Location: Planet Earth

User Profile
 
Subject : ATS Trade Ranking Issue
Posted : 9/18/2018 1:45 AM
Post #45408

If we don't put any formula in the Short Ranking box and keep it blank then we get different results even for Strategies which fire only Long Signals. In other words we get different results depending on whether there is "any" formula in the Short box or not even if the Strategy doesn't fire any Short Signal.

You can put any formula in the Short box and will get the same result but if kept blank then results will be different.







[Edited by Vinay on 9/18/2018 1:48 AM]

Attached file : ShortError.jpg (50KB - 1020 downloads)

^ Top
Jim Dean

Sage
20001000
Posts: 3022

Joined: 9/21/2006
Location: L'ville, GA

User Profile
 
Subject : RE: ATS Trade Ranking Issue
Posted : 9/18/2018 4:05 AM
Post #45409 - In reply to #45408

A blank in the Short box is afaik the same as using “true” or “C=C”. That is, there is no filter and therefore all short signals pass on through.

The reason for the difference in the Long trades is that if a strategy has a short trade active, then during that time (and possibly a short time thereafter based on your System Block settings), Long trades have to wait.

Otoh, if a formula in the Short filter blocks some or all of the short trades, (“false” or “2=3” does this effectively), then all possible Long trades (given the other strategy settings) will be taken.
^ Top
Vinay

Elite
50010025
Posts: 640

Joined: 12/9/2011
Location: Planet Earth

User Profile
 
Subject : RE: ATS Trade Ranking Issue
Posted : 9/18/2018 4:40 AM
Post #45410 - In reply to #45408

Jim...I mentioned in my post that the strategy is firing Long Signals only.

I have configured the Systems block in the strategy to generate Long Signals only, so the question of Short Signals blocking Long Signals doesn't arise.



^ Top
Jim Dean

Sage
20001000
Posts: 3022

Joined: 9/21/2006
Location: L'ville, GA

User Profile
 
Subject : RE: ATS Trade Ranking Issue
Posted : 9/18/2018 5:25 AM
Post #45411 - In reply to #45410

Oops
^ Top
jpb

Veteran
1002525
Posts: 168

Joined: 5/11/2005
Location: Brown Deer, WI

User Profile
 
Subject : RE: ATS Trade Ranking Issue
Posted : 9/18/2018 8:59 AM
Post #45412 - In reply to #45410

Out of curiosity, were you able to verify that even though your strategy should be firing long only that there are no short trades when there is no formula in the short ranker?

I'd expect to not see any, but if some slipped in for some reason, that might point to a problem in a different area.
^ Top
Vinay

Elite
50010025
Posts: 640

Joined: 12/9/2011
Location: Planet Earth

User Profile
 
Subject : RE: ATS Trade Ranking Issue
Posted : 9/24/2018 6:54 AM
Post #45454 - In reply to #45408

Barry...Have you reported this issue for correction?


^ Top
Barry Cohen

Sage
5000100010010010025
Posts: 6338

Joined: 1/19/2004

User Profile
 
Subject : RE: ATS Trade Ranking Issue
Posted : 9/24/2018 12:44 PM
Post #45461 - In reply to #45454

I reproduced & reported. In the meantime make sure you have something listed for the short ranker & not blank.
^ Top
Vinay

Elite
50010025
Posts: 640

Joined: 12/9/2011
Location: Planet Earth

User Profile
 
Subject : RE: ATS Trade Ranking Issue
Posted : 10/10/2018 8:29 AM
Post #45561 - In reply to #45408

Barry...In the change log for OT2018-Release2 there is a mention of:

"(ATM) Deleting a short ranker & leaving it blank no longer results in an error running Portfolio Simulation analysis."

I wanted to clarify whether it refers to the issue documented in this thread or it is different. My confusion is due to the fact that I reported this issue in the context of ATS whereas the change log refers to ATM.

^ Top
Barry Cohen

Sage
5000100010010010025
Posts: 6338

Joined: 1/19/2004

User Profile
 
Subject : RE: ATS Trade Ranking Issue
Posted : 10/10/2018 9:57 AM
Post #45562 - In reply to #45561

This was actually 2 issues, one of which resulted in a Port Sim error - that was fixed. The issue you posted about in this thread was not corrected yet. It's still in the developer's queue, he just wasn't able to get to it since it wasn't a simple fix.
^ Top
SJ

Member
25
Posts: 49

Joined: 9/28/2012
Location: Olathe, KS

User Profile
 
Subject : RE: ATS Trade Ranking Issue
Posted : 2/25/2019 3:35 PM
Post #46031 - In reply to #45562

I've wasted the better part of the day on what appears to be some version of the described problem. I wanted to observe the ranking effects of several parameters by testing them individually both ascending and descending. No matter what I do, the results are making no sense.

To troubleshoot, I created a baseline 10% equity, 1 trade per day method and methods using VTY_PRICE ascending and descending. I fully expected the 3 methods to all get different results. But the two ranking methods are producing the exact same equity curves. I've tried recompiling everything, restarting OT, even moved the ITS files from OT2018 to OT2019 and nothing resolves the problem. At one point I somehow managed to get the three methods to give different results, but after trying to apply an RSI ranking, it didn't work. In fact I was unsuccessful in switching back and getting VTY_PRICE to work again.

I've scrutinized every setting in each method to make sure they are the same (except the ranking). I've examined the ITS.txt files to make sure they reflect all the settings. And as mentioned previously in this thread, I do have formulas for the short conditions set even though I am allowing longs only.

Here is the ranking tab for each of the methods. Any one else seeing or able to reproduce this? I can't take any result I am getting as meaningful.



[Edited by SJ on 2/25/2019 3:39 PM]

Attached file : ATM_trouble.JPG (52KB - 771 downloads)

^ Top
EYEGUY

Icon
100050025
Posts: 1543

Joined: 12/12/2003
Location: BALDWINSVILLE, NEW YORK

User Profile
 
Subject : RE: ATS Trade Ranking Issue
Posted : 2/26/2019 9:47 AM
Post #46039 - In reply to #46031

SJ:

I have been struggling with a similar problem concerning VTY_PRICE.

If you look at the ATM Methods issued to date all of them sort both Long and Short in the Conditions Box Descending. And usually with the (10,5) Parameter set like you are using.

In my situation using a custom Market State I developed I was trying to optimize the value of the Ranker Default. Every time I did so though whether sorting Long and Short both Descending or Long Ascending and Short Descending (which I thought to be the better choice and I'll show why in a second) the Optimization returned a value of zero (0). But that may have had to do with the trades taken in my Market State although I thought the result a bit strange.

So, what is the description of VTY_PRICE? From the OT Help File:



Note that it is true that high values of the Volatility Price Ratio does indeed seem to portend a reversal - but mainly a reversal that taking a Long position in might benefit from. Contrarily a Short position might be seen to benefit from a low value of the Volatility Price Ratio.

Here it is on LLY - I just happened to be looking at it today for a trade. Note the similarity in respect to my analysis above:



So, here is what I would suggest - try the Sort with Long Ascending and Short Descending with those boxes checked in the Conditions interface even though you are only trading Long only and see what happens.

Note - I haven't tried this but it should be a simple test.

Tom Helget

[Edited by EYEGUY on 2/26/2019 9:54 AM]

Attached file : Volatility Price Ratio Definition.jpg (56KB - 733 downloads)
Attached file : VTY_PRICE.jpg (75KB - 709 downloads)

^ Top
SJ

Member
25
Posts: 49

Joined: 9/28/2012
Location: Olathe, KS

User Profile
 
Subject : RE: ATS Trade Ranking Issue
Posted : 2/26/2019 3:45 PM
Post #46043 - In reply to #46039

Hey Tom,

Thanks for the reply. Appreciate your observations on the behavior of VTY_PRICE. AT this point, it is not the behavior of how any given ranker affects performance, it is simply that if applying a ranker that has a known effect and we throttle down the number of trades allowed to 1 per day, there should be a detectable difference in the equity curves when trades are based on ascending vs descending ranker value. They should not be exactly the same. I don't know if this means the ascending/descending radio buttons are not working or what is happening. I can see from the log files that the same trades are being taken and the others rejected. BTW, although the thread is for ATS, I am using ATM for this test with just a Default market state.

Ran today, long only. Test 0 is baseline. Test is VTY_PRICE descending, Test2 is ascending. This looks correct!


Switched to RSI(2) ranker. Strategy is a variation of XLS-19, so RSI level should be predictive varying between 0 and 10 (10 is the signal cutoff level).
Test 0 is baseline. Test 3 is RSI(2) ascending, Test 4 is descending. There is no difference in Test 3 vs 4. Also, I would have expected a lower RSI value to be more profitable on average, but the baseline performed better. So what sort is happening?


Edited Test 3 & 4 to switch back to VTY_PRICE like Test & Test2 were. Much to my surprise, the 3 curves presented as before. So I edited 3 & 4 so that 3 was VTY_PRICE ascending and 4 was descending. If ranking is working, 3 & 4 should have reversed, but they did not change at all. I even exited back to Real Mode and back to Port Sim to be sure – no change.
So just to cover every base, I made sure to my ascending/descending were reversed for long/short as suggested by Tom. This made no difference, but when I put it back to original, my three curves became two! Now Test 3 & Test 4 produce the same equity curve despite having opposite direction rankings. I’ve broken it. WTF?


Shut down OT and restarted. Port Sim still producing only two curves. This is madness! This is Sparta!

Steve Johnson

[Edited by SJ on 2/26/2019 4:23 PM]

Attached file : Trouble1.png (27KB - 694 downloads)
Attached file : Trouble2.png (26KB - 635 downloads)
Attached file : Trouble3.png (25KB - 699 downloads)

^ Top
EYEGUY

Icon
100050025
Posts: 1543

Joined: 12/12/2003
Location: BALDWINSVILLE, NEW YORK

User Profile
 
Subject : RE: ATS Trade Ranking Issue
Posted : 2/26/2019 4:12 PM
Post #46044 - In reply to #46043

Steve:

I have to admit that playing with the Rankers is, for me too, at best a wonky experience.

One other thing I noted reviewing this thread is that for your VTY_PRICE Rank Ascending and Rank Descending Tests you didn't have the "Scale Indicator Values" box checked. What this does is to scale the indicator you are investigating from 0 to 100 and, in the case of VTY_PRICE that would be helpful if you eventually decided to enable both RSI and VTY_PRICE in your testing paradigm. Early on working with ATM I was reluctant to do that since I didn't know what effect checking the box would have, but found that it was helpful when I did check it. Just a thought....

Tom Helget
^ Top
SJ

Member
25
Posts: 49

Joined: 9/28/2012
Location: Olathe, KS

User Profile
 
Subject : RE: ATS Trade Ranking Issue
Posted : 2/26/2019 5:00 PM
Post #46045 - In reply to #46044

I was in the ATM Master Class, so I got most of the skinny on this. I think I've tried with and without checking the scaling box. With a single ranker, it should make no difference. Incidentally, The scaling feature looks at the lowest and highest occurrence of the parameter over the lookback period and scales them to between 0 and 100. If you look into the xml file for each method (XYZ.ITS.txt), you can see those min and max values used for the calculation.

In my file, here are the max and min values for VTY_PRICE:
RangeMaxLong="0.1029571" RangeMinLong="0.0018801" RangeMaxShort="0.1029571" RangeMinShort="0.0018801"

And here are the max and min values for RSI2:
RangeMaxLong="100" RangeMinLong="0" RangeMaxShort="100" RangeMinShort="0"

What is curious here is that I am a little surprised that RSI(2) hit both 0 and 100 in the data set. But here is the more important point. RSI varies between 0 and 100, but on any given signal day, by definition, RSI(2) was below 10 or there would be no signal generated.

So to mix scaled VTY_PRICE and scaled RSI equally in a weighting scheme is not going to be effective as trades are more likely to be spread across the VTY_PRICE range, but will be concentrated in the lower 10% of the RSI range. If your goal is to give both an approximate equal contributing value, you need to scale up RSI by a factor of ten (IMHO). Not to say equal weight is ideal. That is where optimization can help solve the puzzle and I would guess it also resolves the imbalance discrepancy I just outlined.

Unfortunately, all that is moot if I can't even get the most basic of ranking functions to act consistent and repeatable. It really looks like it sometimes gets stuck and can't properly distinguish which is the correct sort direction. I would appreciate if anyone else could attempt to recreate my scenario(s).
^ Top
Jim Dean

Sage
20001000
Posts: 3022

Joined: 9/21/2006
Location: L'ville, GA

User Profile
 
Subject : RE: ATS Trade Ranking Issue
Posted : 2/26/2019 5:25 PM
Post #46046 - In reply to #46045

Checking the scaling box is supposed to solve the problem of two indicators that have entirely different numeric ranges. However, how that happens is a black box. So it’s possible that some combinations or circumstances may evoke a weakness in the normalization code behind the feature. It should be eminently fixable, but N would need to dig into it. I’d suggest posting or emailing them very specific examples with all telated files so that they can either verify the issue or explain what’s happening.

Another sure fire solution is to create a custom OLang indicator that does everything transparently, creating and combining normalized versions of each indicator that’s to be used. The advantage of this is that there’s no mystery, and that you can do all kinds of interesting things re weighting the indicators or whatever.
^ Top
EYEGUY

Icon
100050025
Posts: 1543

Joined: 12/12/2003
Location: BALDWINSVILLE, NEW YORK

User Profile
 
Subject : RE: ATS Trade Ranking Issue
Posted : 2/26/2019 5:31 PM
Post #46047 - In reply to #46045

Steve:

You should not be surprised about the RSI(2) value being either 0 or 100 - as a matter of fact it is rarely anything but:



If you are a Nirvana Club member you might also want to check out my woes with the ATM Ranker tab here:

http://forum.thenirvanaclub.com/thread-view.asp?threadid=7955&posts=1

One thing I would suggest if you are not already doing it is to not just assume that once you have made a change in your ATM Method that you can just go on working with it in OT. I would advise you to shut OT down and then upon re-invoking it double check everything in the ATM Method for accuracy and then, and only then, do your run.

Tom Helget


[Edited by EYEGUY on 2/26/2019 5:32 PM]

Attached file : RSI(2) on SPY.jpg (199KB - 658 downloads)

^ Top
SJ

Member
25
Posts: 49

Joined: 9/28/2012
Location: Olathe, KS

User Profile
 
Subject : RE: ATS Trade Ranking Issue
Posted : 2/26/2019 7:57 PM
Post #46048 - In reply to #46047

Tom, Good point on the RSI(2). When dealing with short period RSI, I always go (ok, didn't here) to the standard formula exactly because of how extreme the N version gets. Forgot that it actually goes to 100 & 0 frequently, unlike "standard" RSI which rarely goes under 1 (did hit a remarkable .054 this December).

Jim, good points on alternatives to testing combined rankers.

Frankly, the weighting and multiple ranker discussion, while interesting, was straying from the original issue. Taking Tom's advise and some extra measures, I verified my method settings, shut down OT, purged the results folder and the VBA/Temp folder, restarted OT, downloaded data and then analysis. I go to Port Sim and find the two methods (Rank by VTY_PRICE ascending/descending) are still giving the exact same equity curve, both higher than with no sort. As we have generally observed that sort descending (long only) is the beneficial configuration, the conclusion is that both are sorting descending despite the settings. Why I was apparently getting "correct" results earlier today, but cannot replicate that now remains an utter mystery.

Tom, I am in N-club and read your post. I will try to add my woes there as well. Our issues are not identical, but similar.
^ Top
EYEGUY

Icon
100050025
Posts: 1543

Joined: 12/12/2003
Location: BALDWINSVILLE, NEW YORK

User Profile
 
Subject : RE: ATS Trade Ranking Issue
Posted : 2/26/2019 8:21 PM
Post #46049 - In reply to #46048

Steve:

Thanks I appreciate that!

I too believe there is something wrong with the ATM Ranker function.

One other thing - I gave a friend the ATM Method I concocted and he couldn't load it up on his OT although I am using it on two of my computers with no problems - loading-wise, at least.

I only hope that these threads will encourage Nirvana Support to take a look into the Ranker problem and suggest how one might take better advantage of this wonderful tool they have supplied us with.

Tom Helget
^ Top
jpb

Veteran
1002525
Posts: 168

Joined: 5/11/2005
Location: Brown Deer, WI

User Profile
 
Subject : RE: ATS Trade Ranking Issue
Posted : 2/26/2019 9:33 PM
Post #46050 - In reply to #46043

Steve,
What's the sequence of your actions after applying a change to your rankers?

By this, I mean, are you just clicking Run Analysis in Port Sim or do you switch to real mode and run a full analysis or something else.

And if you just click, Run Analysis, do you run it just once or twice between changes to the ranker?

Reason I ask is I've had the equity curve and many of the statistics change between the first and second run when I made no change in between. Usually after the second run, the stats stay consistent. I've sent info to Barry along with strategies, profiles, ATM methods, and VBA files. I don't think he's been able to reproduce on his system yet after multiple examples. We keep working at it.

It would be helpful if you could post the files and the process/actions you do so we could try and reproduce. One consistently reproducible example helps significantly if we can get it on a Nirvana desktop.

I personally haven't seen the sort order fail with my testing and have seen results change when I flip the order. But I haven't run one of those tests recently in my methods.
^ Top
SJ

Member
25
Posts: 49

Joined: 9/28/2012
Location: Olathe, KS

User Profile
 
Subject : RE: ATS Trade Ranking Issue
Posted : 2/28/2019 5:20 AM
Post #46059 - In reply to #46050

I went back yesterday and decided to purge the methods I had been playing with and do a fresh start with new baseline, ascending and descending methods built from scratch. 10% equity allocation, 1 long trade per day. First tried ranking on RSI - all looked good. Added a VTY_PRICE ranker and selected only that - all looked good. Added "Room to Move" ranker and selected only that - all looked good. Finally tried a combination ranking with RSI and VTY_PRICE - also got three distinct equity curves - all good!

And in every case, I didn't have to leave the Port Sim page to see my changes process properly. So, I am trying to document as I play and I am now trying to break the thing and hopefully figure out what causes the trouble I outlined in previous posts.

I tried using a file compare app to see if there were notable differences in the ITS files I was having the discrepancies in prior and did not see any red flags. Will probably pick this up over the weekend to test some more. I've been archiving off copies of the files as I test so that when things misbehave, I can compare the two ITS file versions for any discrepancies.
^ Top
EYEGUY

Icon
100050025
Posts: 1543

Joined: 12/12/2003
Location: BALDWINSVILLE, NEW YORK

User Profile
 
Subject : RE: ATS Trade Ranking Issue
Posted : 2/28/2019 3:11 PM
Post #46060 - In reply to #46059

Steve:

Nice, scientific approach.

Tom Helget
^ Top
SJ

Member
25
Posts: 49

Joined: 9/28/2012
Location: Olathe, KS

User Profile
 
Subject : RE: ATS Trade Ranking Issue
Posted : 3/3/2019 8:29 PM
Post #46069 - In reply to #46059

Completed experiments last night. I know that I originally stated the problem was observed in OT 2018 and that when trying in OT 2019 all was the same. My last post stated that I started over in OT 2018 and all was mysteriously working. It turned out the same could not be said for OT 2019.
In diagnosing the problem, I suspect I had an error in my initial work in OT 2018, but I finally came to the conclusion there is a real issue in OT 2019.
When you create a method (by New or Save As) a filename.ITS.txt (ITS) file is created. It is in XML format and contains all the parameter settings for the method.
Here is the ATM\ folder. The “Test ascend (descend)” and “Test 2018” files (4) were created in OT2018. The “Test 2019” files (2) were created in OT 2019. I brought all files over to OT 2019



Compiler status in Omnilanguage window after a forced compile. The 4 methods ported over from OT 2018 are compiling. None of the 2019 created methods are compiling.



After compilation, a folder is created with OL style code that represents the filters and rankers within the method.
Here is the VBA\ITS\ folder in OT 2019. Note there are folders for methods from ported from OT 2018, none for the two created in OT 2019.



Within these ITS folders are a folder for Filters (if any) and Ranks (if any). I was only playing with rankers, so I had no Filters folder. After compiling, subRanker and filter files are generated. For ranking, these represent the individual ranking functions.
After you Run Analysis, OT determines the highest and lowest values for each ranking function and does two things. First, it creates a long and short Ranker file in the Ranks folder. These represent the composite ranking function inclusive of weights and direction. Without them, no ranking takes place.



Second, after Run Analysis completes, the ITS file in the ATM folder (or ATS folder if you don’t have ATM) is modified with this information. Below is a comparison of the ITS files after they are compiled and run. The one on the left is on OT2018 and the difference is the subRanker min and max values are calculated. In the one on the right, OT2019 refused to calculate the values.



Without those subRanker values, a composite Ranker formula is not generated and no ranking takes place. With that knowledge, I processed a method in OT2018 and ran it (Run Analysis) so that the ITS file was modified with ranking min/max information and then copied it into OT2019. When OT 2019 is launched, it seems to properly recognize it, does compile and does rank trades. I even modified this ported over method within OT 2019 by adding a second ranker function and it appears to properly integrate that second ranker.

I verified the OT 2019 behavior on a second computer. One of the two is updated to 2L.

So, specifically what I found after starting over was the following:
- Methods created and or modified in OT 2018 are working (I can’t explain what was going wrong initially in my original post.)

- Methods created in OT 2019 are not working for Ranker functions.

- Methods created and executed in OT 2018 do work if copied to OT 2019.

- Subsequent modifications to methods in OT 2019 appear to work.

As a side note, I raised some thoughts on how the ranking function works in one of my earlier posts on this topic. I've expanded those thoughts, especially with respect to use of multiple rankers and posted them here.

[Edited by SJ on 3/3/2019 9:03 PM]

Attached file : ATM_Folder.png (27KB - 540 downloads)
Attached file : Build_Window.png (7KB - 538 downloads)
Attached file : ITS_Folder.png (15KB - 515 downloads)
Attached file : Ranks_Folder.png (15KB - 553 downloads)
Attached file : File_Compare.png (51KB - 532 downloads)

^ Top
Vinay

Elite
50010025
Posts: 640

Joined: 12/9/2011
Location: Planet Earth

User Profile
 
Subject : RE: ATS Trade Ranking Issue
Posted : 4/20/2020 9:15 AM
Post #46981 - In reply to #45408

Barry,

The change-log for PR-2I mentions that "(ATM) Using Trade Rankings no longer requires entering formulas for both Long & Short conditions."

Please clarify whether the Trade Ranking issue in ATS as reported in this post is also fixed?

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.