Accessing higher level timeframes for indicators such as ADX  [SOLVED]

Questions about MultiCharts .NET and user contributed studies.
robbob
Posts: 46
Joined: 26 Jan 2013
Has thanked: 2 times
Been thanked: 3 times

Accessing higher level timeframes for indicators such as ADX

Postby robbob » 20 Mar 2013

Hi,

I've been able to blend 2 timeframes together in my strategy by added a lower timescale chart first ie, 30 minute, and then a higher level timescale such as daily. In my strategy I generate signals off the higher l]evel timeframe by doing something similar to:

m_bollingerband.price = BarsOfData(2).Close;

for the indicators that have a "price" property which is used to calculated their value. This has worked out well for these types of indicators. ADX and ATR however do not have a close/open/high/low property, and I would like to access these indicators within the higher time frame similar to the bollingerband example. Is there a similar way to accomplish this with ADX and ATR?

Thanks,
-Rob

User avatar
Henry MultiСharts
Posts: 9165
Joined: 25 Aug 2011
Has thanked: 1264 times
Been thanked: 2957 times

Re: Accessing higher level timeframes for indicators such as  [SOLVED]

Postby Henry MultiСharts » 21 Mar 2013

Hello Rob,

ADX and ATR functions can be calculated on subcharts.
Here's how to base ADX and ATR calculations on data2:

Code: Select all

ADX _a = new ADX(this,2);
//
double _aa = PublicFunctions.TrueRange(this, 10, 2);


Return to “MultiCharts .NET”