Login Page - Create Account

Support Board


Date/Time: Sat, 23 Nov 2024 19:54:53 +0000



Post From: Set Volume-by-Price "Ticks per volume bar" by setting exact number of VbP bars on chart?

[2023-08-08 07:48:23]
funbun - Posts: 90
Amazing work here Tony, I will definitely use this code to replace my endless CB buttons...

But, I was referring to something else.. A way to completely remove the need to change the VbP ticks parameter, here's how -

Instead of adjusting the tick size for each new stock, set a fixed number of horizontal VbP bars on a chart.

Example - Set VbP bars to 40 horizontal VbP bars per chart

For a high range stock
If the stock has a chart range from $20 to $30, the VbP ticks parameter will set itself
automatically to (30-20)/40 = 25 ticks per VbP bar

For a low range stock
If the stock has a chart range from $2 to $2.80, the VbP ticks parameter will set itself
automatically to (2.8 - 2)/40 = 2 ticks per VbP bar

This automation removed the need to adjust the VbP ticks parameter when switching from a high range stock to a low range stock and vice versa.
The number 40 represents the exact VbP bars "density" that's not too fine and not too thick, but it can be any number.

Does it make sense?
Date Time Of Last Edit: 2023-08-08 07:51:18