Indicator on data2

Studies that have been contributed to the community by other users. If you’ve got something useful to share, that’s great!
User avatar
siscop
Posts: 197
Joined: 09 Jan 2011
Has thanked: 34 times
Been thanked: 29 times

Indicator on data2

Postby siscop » 17 Jan 2011

Hi,
I am a little desperate right now.
I am working since a week on this problem and cant finde a solution.
I put on a chart with
Data1 = M1 (minute)
Data2= D1 (daily)
I just want to have the daily DMI (data2). It doesn’t matter which stock

Code:

Code: Select all

variables:
dplus(0),
dminus(0);

dplus=DMIPlusCustom(h of data2,l of data2, c of data2,14);
dminus=DMIMinusCustom(h of data2,l of data2, c of data2,14);
print(" dplus: ",dplus," dminus: ",dminus);
output:

dplus: 0.00 dminus: 81.36

dplus: 0.00 dminus: 97.29
It is obvious that this has to be wrong. There is no DMI with “0” or over “90”.
Could someone please tell me where I am wrong?

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

Re: Indicator on data2

Postby TJ » 17 Jan 2011

Hi,
I am a little desperate right now.
I am working since a week on this problem and cant finde a solution.
I put on a chart with
Data1 = M1 (minute)
Data2= D1 (daily)
I just want to have the daily DMI (data2). It doesn’t matter which stock

Code:

Code: Select all

variables:
dplus(0),
dminus(0);

dplus=DMIPlusCustom(h of data2,l of data2, c of data2,14);
dminus=DMIMinusCustom(h of data2,l of data2, c of data2,14);
print(" dplus: ",dplus," dminus: ",dminus);
output:

dplus: 0.00 dminus: 81.36

dplus: 0.00 dminus: 97.29
It is obvious that this has to be wrong. There is no DMI with “0” or over “90”.
Could someone please tell me where I am wrong?
try this:

dplus=DMIPlusCustom(h , l , c ,14) data2;


for more info, see post #4 and #5
viewtopic.php?f=16&t=6929

User avatar
siscop
Posts: 197
Joined: 09 Jan 2011
Has thanked: 34 times
Been thanked: 29 times

Re: Indicator on data2

Postby siscop » 17 Jan 2011

I can’t believe it. It really works.
TJ thank you sooo much… I have been working at this problem for a while now and even developed workarounds.
You are definitely working too hard - Sundays and holydays. I didn’t expect an answer so soon.

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

Re: Indicator on data2

Postby TJ » 17 Jan 2011

I can’t believe it. It really works.
TJ thank you sooo much… I have been working at this problem for a while now and even developed workarounds.
You are definitely working too hard - Sundays and holydays. I didn’t expect an answer so soon.
You are welcome.

I am glad it works.


Return to “User Contributed Studies and Indicator Library”