Page 1 of 1

Difficulty with Data Stream Aliasing on Custom DMI Strategy

Posted: 09 Sep 2007
by irishkev
Hello,

I'm using the following code to generate an "Uptrend" strategy in an 8 minute chart:

inputs:
Length( 14 ),
ADXTrend( 25 ) ;

variables:
oDMIPlus( 0 ),
oDMIMinus( 0 ),
oDMI( 0 ),
oADX( 0 ),
oADXR( 0 ),
oVolty( 0 ) ;

Value1 = DirMovement( H, L, C, Length, oDMIPlus, oDMIMinus, oDMI, oADX,
oADXR,
oVolty ) ;

if oDMIPlus > 21 and oADX > 21 and oDMIPlus > oADX then
buy ( "Up Trend" ) next bar at market ;

By itself, it works fine.

What I want to do is combine this with another indicator that uses 1 minute data. I constructed a chart with 1 minute (data1) and 8 minute (data2) symbols. I create a strategy but I am unable to make this DMI study reference the 8 minute data stream (data2) properly. I've tried referencing data2 in every possible way (except a way that works, of course).

I've created a screen shot that shows it working properly with just 8 minute data and it not working on a combined 1 min and 8 min chart.

Any help would be appreciated.

Thanks,
Kevin

Posted: 10 Sep 2007
by Marina Pashkova
Hello,

Please, make sure that the starting point is the same for the strategy and the indicator.

Posted: 10 Sep 2007
by irishkev
Hi,

Do you mean to make sure that all symbols are pulling the same number of bars?

Thanks,
Kevin

Posted: 13 Sep 2007
by Marina Pashkova
Hello,

You need to make sure that Max Bars back is the same.