SmartQuant Discussion

Automated Quantitative Strategy Development, SmartQuant Product Discussion and Technical Support Forums
It is currently Sun Apr 05, 2020 10:42 pm

All times are UTC + 3 hours




Post new topic Reply to topic  [ 6 posts ] 
Author Message
PostPosted: Tue Sep 22, 2009 1:23 am 
Offline

Joined: Mon Jan 07, 2008 6:18 am
Posts: 58
I'm adding range bars to a new strategy... the data is YM tick data, I'm electing to build them from Trades, the range size is 10... so I go through all the appropriate clicks to do that and in the Solution Explorer it says "Bars 0.001 range"... if I want it to say 10 range I have to enter 100,000... what do I enter to get my strategy to be running on range bars of ten YM points? if I enter 100,000 the charts look ok but that leaves me wondering if the rest of the test is done on range =10 or some bogus thing...


I also notice that bars are built differently than in Ninjatrader... in Ninja there is always a one tick difference between the close of one bar and the open of the next one.. in Openquant they are the same... it seems a little more logical to make the open of bar[0] one tick from the close of bar[1] because that first tick outside the range of the bar is the first instant in time when you know that the previous bar is completed and the new one started....


Top
 Profile  
 
 Post subject:
PostPosted: Tue Sep 22, 2009 4:45 am 
Offline

Joined: Mon Jan 07, 2008 6:18 am
Posts: 58
I imported some tick data from a CSV file... also YM. I then tried to compress it using the data utilities into range bars.. there too I get the odd choices for bar interval, 1, .5, .1, .01, and .001... so I went ahead and compressed into each of those to see what I get... It doesn't come out right, the High = the Low in all cases nearly... in fact it appears that all the different compressions result in the same data series after compression... I did a compression into one second intervals and that data looks ok...


Top
 Profile  
 
 Post subject:
PostPosted: Tue Sep 22, 2009 6:00 pm 
Offline

Joined: Thu Jun 08, 2006 3:56 pm
Posts: 537
Location: BC Canada
Regarding the concept of "that first tick outside the range of the bar is the first instant in time when you know that the previous bar is completed and the new one started", it might be the case that this is not true.

It has to with how range bars are defined. (Without saying how they are defined, I'm just proposing an alternate theory that is consistent with the results that I've seen.)

If range bars are defined to say "given a series of same-price ticks at the very edge of a range bar, all those ticks are defined to be inside the range bar that contains the first of those ticks", then the next range bar open price (by definition) must be outside the bar.

But if range bars are defined to say "given a series of same-price ticks at the very edge of a range bar, the first tick in that series fulfills the range definition of the range bar, and completes the range bar", then the next range bar open price (by definition) can be less than, equal to, or greater than the tick that completed the previous range bar.

I could be wrong, but it seems to me that the second definition agrees more with the data that I've seen from my strategies. I suppose one of the SQ guys could comment on exact definition of a range bar from the code of the bar factory.


Top
 Profile  
 
 Post subject:
PostPosted: Tue Sep 22, 2009 6:01 pm 
Offline

Joined: Thu Jun 08, 2006 3:56 pm
Posts: 537
Location: BC Canada
PS. Range bar size 10 does show up as 0.001 in the explorer. So you should enter 10, not 100,000.


Top
 Profile  
 
 Post subject:
PostPosted: Wed Sep 23, 2009 10:52 am 
Offline

Joined: Mon Jan 07, 2008 6:18 am
Posts: 58
You don't know when a range bar is completed until you get a tick outside the range..... splitting that tick or a set of ticks between contiguous bars doesn't make a lot of sense to me, in fact it doesn't make any sense to me.. how do you assign the volume?

What is the significance of the .001? I don't understand what the term is about... a thousandth of what?

I do indeed get a range value of 10 and I think I specified 100,000 and the chart is displaying Openquant version of range 10 bars and in fact, I can live with it and work with it, what I do is not rocket surgery, but technically speaking, it seems not quite right...


Top
 Profile  
 
 Post subject:
PostPosted: Thu Oct 01, 2009 7:54 pm 
Offline

Joined: Mon Jan 07, 2008 6:18 am
Posts: 58
I get it now, there are two ways that range bars are formed, one is upon the first tick that completes the range, Openquant's way, the other is upon the first tick that exceeds the range... I like the latter because I'm used to it in Ninjatrader...

Now if somebody could tell me why I have to put in 100,000 for the range value to get 10 range on a chart and what all the .001, .01 stuff is about I might want to consider using Openquant for testing but meanwhile, how do I know what I'm getting, I'm not sure what Openquant does with what I tell it for range size...


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 6 posts ] 

All times are UTC + 3 hours


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Group