Help with Formula

#1
hi,
I need help with two things

I want write an indicator of volume that make volume in Negative value in days that close < ref(close,-1). In the bull price days the volume mantain equal to original.


Another thing is to separate the values of volume in if the close is bull or bear in two indicators. I trie write but i do not obtain anything.

Thanks in advance
 

oxusmorouz

Well-Known Member
#2
hi,
I need help with two things

I want write an indicator of volume that make volume in Negative value in days that close < ref(close,-1). In the bull price days the volume mantain equal to original.


Another thing is to separate the values of volume in if the close is bull or bear in two indicators. I trie write but i do not obtain anything.

Thanks in advance
From what I have understood from the first statement, I have coded the formula...
Try this:
a:= V ;
b:= C < Ref(C,-1);
If(b, -a, a);

Interpretation: when Close < Ref(C,-1) , plot volume in negetive value and when C > ref(c,-1) plot volume in positive value.
Correct me if I have misunderstood.

Regarding your 2nd statement, could you please be more explanatory?
 
#3
hi oxusmorouz
Many thanks for the first formula. Is exactly this. Sorry for the quality of my English

The secon indicator i try to build is the difference between the positive and negative volume.
What i need?
A Formula to isolate the volume of the Bull and Bear days, i think is anything like this:

Positivevolume:= close > Ref(Close,-1) "it lacks to me part to it of the volume "

Negativevolume:= close < Ref(Close,-1) "it lacks to me part to it of the volume "

positivevolume-negativevolume

thanks in advance
 

oxusmorouz

Well-Known Member
#4
hi oxusmorouz
Many thanks for the first formula. Is exactly this. Sorry for the quality of my English

The secon indicator i try to build is the difference between the positive and negative volume.
What i need?
A Formula to isolate the volume of the Bull and Bear days, i think is anything like this:

Positivevolume:= close > Ref(Close,-1) "it lacks to me part to it of the volume "

Negativevolume:= close < Ref(Close,-1) "it lacks to me part to it of the volume "

positivevolume-negativevolume

thanks in advance
Try this:
a:= Ref(V,-1);
b:= Ref(C,-1);

If(C > b, If( V > a, V - a, 0), If( V < a, V - a ,0))

It plots the difference in today's volume and yesterday's volume as positive when C > Ref(C,-1) And V > Ref(V,-1)
and difference in volumes as negetive when C < Ref(C,-1) And V < Ref(V,-1).

Tell me if there is any correction to be made.
Glad to be of assistance.

Oxymoron
 

Similar threads