Login Page - Create Account

Support Board


Date/Time: Fri, 26 Apr 2024 16:00:06 +0000



Maximum Ask & Minimum Bid within a Bar

View Count: 902

[2018-01-17 10:50:37]
Pinger - Posts: 33
Hi

I'm a bit confused as to how to determine the maximum ask or minimum bid within a bar. I'm understand how to use sc.Ask and sc.Bid to get the ask and bid price at the chart refresh interval, and how to use sc.BaseDate[SC_ASK_PRICE or SC_BID_PRICE][sc.Index] to get the ask and bid prices at the last trade of the bar. But how do I determine if there are different values from ticks received in between the chart refresh times and not the last trade?

Kind regards
[2018-01-17 22:57:57]
Sierra Chart Engineering - Posts: 104368
The only way to do this is by accessing the individual file records within the chart bar with this function:
sc.ReadIntradayFileRecordForBarIndexAndSubIndex()

For tick by tick data, the High and Low fields of the data record contain the Ask and Bid prices respectively. We will make sure the documentation explains this.
Sierra Chart Support - Engineering Level

Your definitive source for support. Other responses are from users. Try to keep your questions brief and to the point. Be aware of support policy:
https://www.sierrachart.com/index.php?l=PostingInformation.php#GeneralInformation

For the most reliable, advanced, and zero cost futures order routing, *change* to the Teton service:
Sierra Chart Teton Futures Order Routing
Date Time Of Last Edit: 2018-01-17 23:01:02
[2018-01-21 17:23:28]
Pinger - Posts: 33
Thanks for the reply.

I've look at the documentation and examples for ReadIntradayFileRecordForBarIndexAndSubIndex(). It all makes sense except for the file locking side of things...

At the commencement of a new bar I want to read the file records for the previous bar. Can I do this without interrupting new records being written to the current bar? i.e. can the data file be written to by the SierraChart data writer process/thread, while my study is reading records? Which file locking, or not, should I use in my study?

Kind regards
[2018-01-22 01:08:15]
Sierra Chart Engineering - Posts: 104368
This has now been documented here:
sc.ReadIntradayFileRecordForBarIndexAndSubIndex()
Sierra Chart Support - Engineering Level

Your definitive source for support. Other responses are from users. Try to keep your questions brief and to the point. Be aware of support policy:
https://www.sierrachart.com/index.php?l=PostingInformation.php#GeneralInformation

For the most reliable, advanced, and zero cost futures order routing, *change* to the Teton service:
Sierra Chart Teton Futures Order Routing

To post a message in this thread, you need to log in with your Sierra Chart account:

Login

Login Page - Create Account