SmartQuant Discussion

Automated Quantitative Strategy Development, SmartQuant Product Discussion and Technical Support Forums
It is currently Sun May 20, 2018 1:15 pm

All times are UTC + 3 hours




Post new topic Reply to topic  [ 3 posts ] 
Author Message
PostPosted: Tue May 24, 2011 7:34 pm 
Offline

Joined: Tue May 10, 2011 2:14 am
Posts: 23
How is the SMA (or any other indicator) calculated if the data has gaps.

suppose you have:

1) 1 min bars based off trade data
2) some 1 minute intervals have no bars because there were no trades (gaps)
3) a 60 minute SMA of the 1 min bars.
4) Now over the past 60 minutes there are only 40 bars because the product is currently not very active.
5) but over the past 90 minutes there are 60 bars.

Will the SMA use 60 minutes of data(40 bars) or use 90 minutes of data (60 bars)?

Thank you!


Top
 Profile  
 
PostPosted: Tue May 24, 2011 7:39 pm 
Offline

Joined: Tue Aug 05, 2003 3:43 pm
Posts: 6802
It's calculated bar by bar, i.e. it doesn't take holes (for example holidays for daily bars) into account.

Regards,
Anton


Top
 Profile  
 
PostPosted: Tue May 24, 2011 7:43 pm 
Offline

Joined: Tue May 10, 2011 2:14 am
Posts: 23
Thank you. Is there any way to add bars where a missing bar occurs?

either by having the OHLC be the same as the last traded price? or using middle if last trade doesn't exist?

That way if the market is open, 60 bars will always be 60 min...


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 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:  
Powered by phpBB® Forum Software © phpBB Group