multi data series

Questions about MultiCharts and user contributed studies.
lawrence124
Posts: 23
Joined: 11 Oct 2012
Has thanked: 1 time

multi data series

Postby lawrence124 » 01 Nov 2012

hi, i added a 3 minutes data series to a chart, and i used RSI(c of data2, 14,...) on it, the value is different from the RSI i used on a single series chart
to clarify it, seems like the RSI(c of data2, 14,...) values change when the time frame of data1 change (ie, using 10 seconds instead of 30 seconds)
any setting that i've missed? Thanks

ps, the 3 minutes RSI would be correct if i set "Base Study On" to series #2, but can i do that for signals ? because, say, i use RSI(c of data2) > 70 = buy, then, the signal generation will be different from the chart

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

Re: multi data series

Postby TJ » 01 Nov 2012

hi, i added a 3 minutes data series to a chart, and i used RSI(c of data2, 14,...) on it, the value is different from the RSI i used on a single series chart
to clarify it, seems like the RSI(c of data2, 14,...) values change when the time frame of data1 change (ie, using 10 seconds instead of 30 seconds)
any setting that i've missed? Thanks

ps, the 3 minutes RSI would be correct if i set "Base Study On" to series #2, but can i do that for signals ? because, say, i use RSI(c of data2) > 70 = buy, then, the signal generation will be different from the chart
see post #5
viewtopic.php?f=16&t=6929

lawrence124
Posts: 23
Joined: 11 Oct 2012
Has thanked: 1 time

Re: multi data series

Postby lawrence124 » 01 Nov 2012

thanks, got it~
one more question, i have a counter that should only add 1 for every data2 bar, how to do that? thanks!

User avatar
furytrader
Posts: 354
Joined: 30 Jul 2010
Location: Chicago, IL
Has thanked: 155 times
Been thanked: 217 times

Re: multi data series

Postby furytrader » 01 Nov 2012

What are the time periods for data1 and data2?

lawrence124
Posts: 23
Joined: 11 Oct 2012
Has thanked: 1 time

Re: multi data series

Postby lawrence124 » 01 Nov 2012

first one is 15sec, 2nd one is 1 minute

User avatar
furytrader
Posts: 354
Joined: 30 Jul 2010
Location: Chicago, IL
Has thanked: 155 times
Been thanked: 217 times

Re: multi data series

Postby furytrader » 01 Nov 2012

One easy way to do this then would be to add 1 for every 4th bar you see in data series 1.

lawrence124
Posts: 23
Joined: 11 Oct 2012
Has thanked: 1 time

Re: multi data series

Postby lawrence124 » 01 Nov 2012

how about i want to do it the right way? anything i can use to check i'm in data2

User avatar
furytrader
Posts: 354
Joined: 30 Jul 2010
Location: Chicago, IL
Has thanked: 155 times
Been thanked: 217 times

Re: multi data series

Postby furytrader » 01 Nov 2012

What do you mean when you say "I'm in data2"?

It's my understanding that the EL code is run (1) after every tick on data1 if the study's "Update On Every Tick" property is checked or (2) at the close of every bar on data1 if the property is not checked. When the code is run, you can check both data1 and data2. You're not "in" one or another.

You may want to see if it is possible to check the BarStatus of data2 to indicate whether that bar is completed and then update your counter appropriately.

Good luck!

lawrence124
Posts: 23
Joined: 11 Oct 2012
Has thanked: 1 time

Re: multi data series

Postby lawrence124 » 01 Nov 2012

cool, i will check it out, much appreciated!


Return to “MultiCharts”