Login Page - Create Account

Support Board


Date/Time: Sun, 24 Nov 2024 19:54:54 +0000



Pending VPOC Shift Alert and VWAP alert

View Count: 818

[2024-01-30 22:42:58]
cesium - Posts: 85
Hello,

Im using the VbP Study.

I attempted to use the following formula to notify when the VPOC on an intraday chart is getting close to migrating. My logic was to calculate the difference between the volume at current price from the volume at the VPOC, and compare to a range:

=[VAP((SG2),0)-VAP(C,0)]<3000

However the alerts log produces the following error:

Error: SYNTAX

I think the error is because logic is breaking down related to the offset, which in this case there is none, or the parameter SG2 inside the first VAP term,

Is there a way to achieve this?

Thank you
Date Time Of Last Edit: 2024-01-30 22:44:41
[2024-01-31 15:21:32]
John - SC Support - Posts: 36238
There are a few issues. First is that you can not use square brackets with an Alert formula, just parentheses. The second is that when you are trying to find the Volume At Price (VAP) for the POC level (SG2) you will get a lot of zeros, as it will be returning the volume of the bar at that level, not the actual Point of Control volume.

If you want to test the Volume of the Point of Control against the volume at the current traded price (for the current bar), then you would need to add the "Numbers Bars Calculated Values" study to get the Point of Control Volume and then your formula would look like the following:
=(ID1.SG20 - VAP(C, 0)) < 3000

Where ID1 is the ID of the Numbers Bars Calculated Values study and SG20 is the Point of Control Volume.
For the most reliable, advanced, and zero cost futures order routing, use the Teton service:
Sierra Chart Teton Futures Order Routing
[2024-01-31 15:28:49]
cesium - Posts: 85
Ok I see that, thank you.

My VPOC is calculated over the 0930-1700 session, so maybe I could use a chart with numbers bars + calculated values study and have the entire day load up into one number bar?

Thank you for the formula

Im applying the above and using the formula provided, however im not hearing any alerts yet, and I see no errors in the Alert manager
Date Time Of Last Edit: 2024-01-31 15:57:48
[2024-01-31 18:03:04]
John - SC Support - Posts: 36238
Sorry, my apologies. I was not thinking correctly about the "Point of Control Volume" from the Numbers Bars. I was just in too much of a hurry. As you point out, this is not the sum of the volumes, just the volume of the individual bar's POC.

Attached is a Study Collection that will give you the volume for the Point of Control for a Daily Volume Profile. Refer to the following for how to use a Study Collection:
Study Collections: Using a Study Collection Provided by Sierra Chart Support

Your alert condition will then need to change to reference the Cumulative Sum of Study study, but will look the same otherwise (so ID1.SG20 needs to change to ID3.SG1 per the given Study Collection), but you may have to change the ID for your purposes depending on what you end up with.
For the most reliable, advanced, and zero cost futures order routing, use the Teton service:
Sierra Chart Teton Futures Order Routing
attachmentVPOC-DailyVolume.StdyCollct - Attached On 2024-01-31 18:03:01 UTC - Size: 53.29 KB - 364 views
[2024-02-01 23:00:25]
cesium - Posts: 85
Hello,

That is fine no worries. Thank you for the study collection, that was a huge help. I applied it late last night and monitored today;

I played around with the boundary range today and never heard an alert for this

=(ID3.SG1 - VAP(C, 0)) < 5000

The symbol is ESH4.cme, and with the boundary of 5k, i should have heard alerts

There are only the 3 studies on a new chart, and the chart is only loading the current RTH day into one full candle

Im not sure what Im doing incorrect
Date Time Of Last Edit: 2024-02-02 13:18:32
[2024-02-02 15:28:14]
John - SC Support - Posts: 36238
Keep in mind that as the day goes on the Volume of the Point of Control is only going to get larger, whereas the volume at the close of the current bar is going to be relatively static (it will not fluctuate that much, particularly in reference to the volume of the POC). So depending on the Bar Period you are using, and the time of day, it would not be surprising to not get an alert.

What we would do is to add a "Spreadsheet Formula" to your chart and enter the given formula into the Spreadsheet Formula. Then you can scroll back and see when/if there was an alert, as the Spreadsheet Formula will be 1 at that point instead of 0, so you will see a quick spike in the line.
For the most reliable, advanced, and zero cost futures order routing, use the Teton service:
Sierra Chart Teton Futures Order Routing
[2024-02-05 17:46:59]
cesium - Posts: 85
Hello John,

Okay thank you.

Very interesting issue ive observed today,

The alerts both triggers and audibly sounds when using teton order routing, but it does neither trigger not alert audibly on rithmic data feed.

So far I cannot figure out the reason or a fix

=(ID3.SG1 - VAP(C, 0)) < 1000

Enabled yes

Reset alerts condition on new bar Yes

All others no
Date Time Of Last Edit: 2024-02-05 17:49:55
[2024-02-05 18:13:28]
John - SC Support - Posts: 36238
You would have to look at the underlying data and take apart each piece. We do not know for sure, but we are not fans of the Rithmic data in general.
For the most reliable, advanced, and zero cost futures order routing, use the Teton service:
Sierra Chart Teton Futures Order Routing
[2024-02-06 15:02:23]
cesium - Posts: 85
Back again, my apologies, thank you, I am now seeing the issues with rithmic data.

Im attempting to code in logic that excludes the case when price equals vpoc from triggering this alert

=(ID3.SG1 - VAP(C, 0)) < 1000 AND !(ID1.SG2 = C)

, where ID1.SG2 is Vbp.POC subgraph

Does this appear correct?

Thank you
Date Time Of Last Edit: 2024-02-06 15:34:26
[2024-02-06 19:05:42]
John - SC Support - Posts: 36238
The Alerts syntax does not do "AND" in that fashion. You would need to have the following formula:
=AND((ID3.SG1 - VAP(C, 0)) < 1000, !(ID1.SG2 = C))
For the most reliable, advanced, and zero cost futures order routing, use the Teton service:
Sierra Chart Teton Futures Order Routing
[2024-02-20 14:11:25]
cesium - Posts: 85
Hello John just wanted to say thanks, I dont want to bump threads to say thank you so I always click the TY Button. :-)

I have an idea id like to implement:

Is there a way to add arguments to the alert so it only is enabled after the first 30 seconds, for example? The alert is working great by the way.

=AND((ID3.SG1 - VAP(C, 0)) < 200, !(ID1.SG2 = C))

Thank you
[2024-02-20 17:02:54]
John - SC Support - Posts: 36238
You can add requirements relative to time. What exactly is the 30 seconds counting from (i.e. first 30 seconds after what)?
For the most reliable, advanced, and zero cost futures order routing, use the Teton service:
Sierra Chart Teton Futures Order Routing
[2024-02-20 17:09:16]
cesium - Posts: 85
It would be counting from the session start time of 0930EST

Thank you
[2024-02-20 17:36:11]
John - SC Support - Posts: 36238
If you only want the alert to work after 09:30:30 (and run until Midnight that night - i.e. no alerts between midnight and 09:30:30) then the following will do this:

=AND((ID3.SG1 - VAP(C, 0)) < 200, !(ID1.SG2 = C), FRACTIME(NOW()) > TIME(09, 30, 30))
For the most reliable, advanced, and zero cost futures order routing, use the Teton service:
Sierra Chart Teton Futures Order Routing
Date Time Of Last Edit: 2024-02-20 17:36:30
[2024-02-23 20:21:56]
cesium - Posts: 85
Hello John,

And for VPOC Shift alert, I attempted to do

=AND(FRACTIME(NOW()) > TIME(09, 30, 30)), SG2[-1] <> SG2[0]

But I couldnt get it working properly, I recieved syntax errors
[2024-02-23 21:15:37]
John - SC Support - Posts: 36238
You have an extra parentheses after the TIME() and no closing parentheses for the end of the entire AND statement. So it should be the following:
=AND(FRACTIME(NOW()) > TIME(09, 30, 30), SG2[-1] <> SG2[0])
For the most reliable, advanced, and zero cost futures order routing, use the Teton service:
Sierra Chart Teton Futures Order Routing
[2024-03-20 23:56:36]
cesium - Posts: 85
Hey John back again, this formula is working great.

How would I go about combining these two into one entry?

=AND((ID3.SG1 - VAP(C, 0)) < 300, !(ID1.SG2 = C), FRACTIME(NOW()) > TIME(09, 31, 00))

and

=AND(FRACTIME(NOW()) > TIME(09, 31, 00), SG2[-1] <> SG2[0])

to help, what I would want this to do is to alert when a VPOC migration is imminent, and also alert when VPOC has shifted

Thank you Sir
Date Time Of Last Edit: 2024-03-21 12:49:39
[2024-03-21 14:57:47]
John - SC Support - Posts: 36238
You can have more than 2 items in an AND() function - they are each separated by a comma, so you would just need to add the one part to the first condition. So you would have the following:
=AND((ID3.SG1 - VAP(C, 0)) < 300, !(ID1.SG2 = C), FRACTIME(NOW()) > TIME(09, 31, 00), FRACTIME(NOW()) > TIME(09, 31, 00), SG2[-1] <> SG2[0])
For the most reliable, advanced, and zero cost futures order routing, use the Teton service:
Sierra Chart Teton Futures Order Routing
[2024-05-06 17:11:26]
cesium - Posts: 85
Last Price x ticks away from vwap from svp

=AND(FRACTIME(NOW()) > TIME(09, 31, 00), (OR(C >= SG5 + (3 * TICKSIZE)), (C <= SG5 - (3 * TICKSIZE)))

is there something obvious im missing in this formula?
[2024-05-06 22:33:41]
John - SC Support - Posts: 36238
One item that we see is that you have an OR() that isn't doing anything, and your parentheses are not properly located. This section in particular, which is what to do if the time is greater than 0931:

(OR(C >= SG5 + (3 * TICKSIZE))

You have 3 opening parentheses, but only two closing. And the OR() only has 1 parameter, so there is no need for it.
For the most reliable, advanced, and zero cost futures order routing, use the Teton service:
Sierra Chart Teton Futures Order Routing
[2024-05-09 18:27:40]
cesium - Posts: 85
The inclusion of the OR statement is to evaluate the case of price being either higher than or lower than vwap

If I dont need this that would make this easier

i fixed the parenthesis but still having syntax error

=AND((FRACTIME(NOW()) > TIME(09, 31, 00)), (OR(C >= SG5 + (2 * TICKSIZE)), (C <= SG5 - (2 * TICKSIZE))))
[2024-05-09 18:30:04]
John - SC Support - Posts: 36238
You have an OR() with a single parameter. So there is nothing else to compare, so this is not correct.
For the most reliable, advanced, and zero cost futures order routing, use 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