color ohlc

Questions about MultiCharts and user contributed studies.
O66
Posts: 146
Joined: 28 Nov 2006
Location: Netherlands
Has thanked: 2 times
Been thanked: 3 times

color ohlc

Postby O66 » 26 Sep 2011

hi,

i need a colored ohlc (red for down, green for up bar)
as i understand this can be done with a paintbar indicator.
im not a programmer...
who can help me with this?

thanks

User avatar
TJ
Posts: 7740
Joined: 29 Aug 2006
Location: Global Citizen
Has thanked: 1033 times
Been thanked: 2221 times

Re: color ohlc

Postby TJ » 26 Sep 2011

hi,

i need a colored ohlc (red for down, green for up bar)
as i understand this can be done with a paintbar indicator.
im not a programmer...
who can help me with this?

thanks
EasyLanguage Essentials Programmers Guide
Creating a PaintBar Study.......... pg. 77

O66
Posts: 146
Joined: 28 Nov 2006
Location: Netherlands
Has thanked: 2 times
Been thanked: 3 times

Re: color ohlc

Postby O66 » 26 Sep 2011

thanks i was already truying with some code but i vcant make it work

From the guide:

Input: Length(14), OvBought(80), OvSold(20);Vars: SlowKVal(0);SlowKVal = SlowK(Length);if SlowKVal > OvBought then

PlotPB

(High, Low, "SlowK", Red);if SlowKVal < OvSold then

PlotPB

(High, Low, "SlowK", Blue);

this is based on stochatics, i dont use that
all i want is green ohlc bar when its an up bar and red when its a down bar
based on price not on stochastics or whatever


why do you need to be a programmer for doing something simple like this

User avatar
TJ
Posts: 7740
Joined: 29 Aug 2006
Location: Global Citizen
Has thanked: 1033 times
Been thanked: 2221 times

Re: color ohlc

Postby TJ » 26 Sep 2011

thanks i was already truying with some code but i vcant make it work

From the guide:

Code: Select all

Input: Length(14), OvBought(80), OvSold(20);
Vars: SlowKVal(0);

SlowKVal = SlowK(Length);

if SlowKVal > OvBought then
PlotPB(High, Low, "SlowK", Red);
if SlowKVal < OvSold then
PlotPB(High, Low, "SlowK", Blue);
this is based on stochatics, i dont use that
all i want is green ohlc bar when its an up bar and red when its a down bar
based on price not on stochastics or whatever

why do you need to be a programmer for doing something simple like this
Why?
Because everybody's interpretation of "up bar" may be different,
and not everybody wants green for up color.

When you say up bar, do you mean current close higher than previous close?

Easylanguage is an English-like programming language, specifically designed for traders who are non-programmers.

for the book's example,
simply substitute the stochastic with your logic:

Code: Select all

Input:
Up.color(green),
down.color(red);

if CLOSE > CLOSE[1] then
PlotPB(High, Low, Open, Close, "Pricebars", Up.color);

if CLOSE < CLOSE[1] then
PlotPB(High, Low, Open, Close, "Pricebars", down.color);
If you can understand the above code,
you are a defacto EasyLanguage programmer!

MultiCharts is one powerful program; you can ask it to do any analysis you can imagine. Don't let it sit idle in waste.

O66
Posts: 146
Joined: 28 Nov 2006
Location: Netherlands
Has thanked: 2 times
Been thanked: 3 times

Re: color ohlc

Postby O66 » 26 Sep 2011

thanks!

yes i can understand the code.
But writing it myself is another thing.

easylanguage is not so easy if you ask me.
you have to learn a language....

of course it can be done but i want to learn how to trade better not programming.

thanks again.

User avatar
TJ
Posts: 7740
Joined: 29 Aug 2006
Location: Global Citizen
Has thanked: 1033 times
Been thanked: 2221 times

Re: color ohlc

Postby TJ » 26 Sep 2011

thanks!

yes i can understand the code.
But writing it myself is another thing.

easylanguage is not so easy if you ask me.
you have to learn a language....

of course it can be done but i want to learn how to trade better not programming.

thanks again.
I agree, there should be an option like the candlesticks, where you can select the up and down color without programming.


Return to “MultiCharts”