Volume colored bars and Divergence

If you need an Indicator or Signal developed or translated from other language, please post all Indicator development REQUESTS to this section here.

Moderator: admin

Volume colored bars and Divergence

Postby isamegrelo » Mon Nov 13, 2017 9:45 am

Formula:


if(High>High[1] and Low>=Low[1]) then //made higher high and higher low -> high bar
upvol = Volume
downvol = 0
neutralvol = 0
elsif(High>High[1] and Low<Low[1]) then //made higher high and lower low -> neutral bar or outside bar
upvol = 0
downvol = 0
neutralvol = Volume
elsif(High<=High[1] and Low<Low[1]) then //made lower high and lower low -> low bar
upvol = 0
downvol = Volume
neutralvol = 0
elsif(High<=High[1] and Low>=Low[1]) then //made lower high and higher low -> inside bar
upvol = 0
downvol = 0
neutralvol = 0
endif

RETURN upvol coloured(0,0,255) as "up volume", downvol coloured(255,0,0) as "down volume", neutralvol coloured(128,128,128) as "neutral volume"
isamegrelo
FXCodeBase: Initiate
 
Posts: 114
Joined: Mon May 29, 2017 3:36 pm



Return to Indicator and Signal Requests

Who is online

Users browsing this forum: Google [Bot] and 40 guests