Login Page - Create Account

Support Board


Date/Time: Tue, 16 Apr 2024 04:46:45 +0000



[User Discussion] - Klinger volume oscillator

View Count: 2890

[2015-07-11 22:40:13]
Shane - Posts: 31
Does Sierra Chart have the equivalent of the Klinger Volume Oscillator?

If not, can I get one of you code geniuses to convert the EasyLanguage for me?

regards,
shane

EasyLanguage code follows:

Type: Function Name: VForce
Vars: TSum(0), Trend(0), DM(0), CM(0);
TSum = High + Low + Close; IF TSum > TSum[1] Then
Trend = 1 Else
Trend = -1;
IF Trend = Trend[1] Then
CM = CM + Range Else
CM = Range + Range[1]; IF CM <> 0 Then
VForce = Volume * AbsValue(2 * (DM/CM) -1) * Trend * 100;

Type: Function Name: KVO
Inputs: FastX(Numeric), SlowX(Numeric); Vars: FXAvg(0), SXAvg(0);
FXAvg = XAverage(VForce, FastX); SXAvg = XAverage(VForce, SlowX); KVO = FXAvg - SXAvg;


Type: Indicator
Name: Klinger Volume Osc
Inputs: FastX(34), SlowX(55), TrigLen(13), Smooth(1); Vars: Trigger(0);
Trigger = XAverage(KVO(FastX, SlowX), TrigLen); IF Smooth <= 1 Then Begin
Plot1(KVO(FastX, SlowX), “KVO”);
Plot2(Trigger, “KVO Trigger”); End Else Begin
Plot1(Summation(KVO(FastX, SlowX), Smooth), “KVO”);
Plot2(Summation(Trigger, Smooth), “KVO Trigger”); End;
Plot3(0, “Zero”);
[2015-07-13 04:08:12]
bjohnson777 (Brett Johnson) - Posts: 284
Shane:

Consider yourself lucky that I've been studying volume based indicators the past few weeks and found KVO interesting.

On the flip side, this has been the most PITA project I've ever done... or at least close to it... Why?

Everyone has the implementation wrong.

Most web sites have the wrong formula and multiple versions of the wrong implementation.

Even the few web sites that have the right formula have the wrong code several lines down.

The code you posted is also wrong and probably won't run. The Scaling Factor is definitely wrong. There's nothing "easy" about EasyLanguage. It's nothing but a big mess that's hard to decode with missing pieces. It's also why I don't do mickey mouse class languages. I don't blame you for that, though. I'm just frustrated with all the previous problems.

It's amazing how so many people have so much trouble with a simple 20 year old algorithm. :-/

Well, now Sierra Chart has THE ONLY PROPERLY WORKING VERSION ON THE PLANET! Fully Featured and Fully Documented! Histogram Included!

Now I'm back to finishing the next indicator in my standard tool box. I've found some interesting things modifying it and will post it later this week.

Offering To The Community: Klinger Volume Oscillator With Filters
[2015-07-14 02:31:49]
Shane - Posts: 31
Brett;

Lucky indeed.

Your comments are dead-on. When I looked at the logic described in the original article and compared it the posted EasyLanguage I noticed discrepancies. I started writing a spec for it anticipating that I was on my own.

I very much appreciate your response and even more, your hard work creating the study. I will download it now and start putting it through its paces.

regards,
shane

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

Login

Login Page - Create Account