PureBytes Links
Trading Reference Links
|
Hi Bruiser,
I would need some context or explanation of what the author of this code is
trying to accomplish before I could say I have given you correct code.
But after changing some of your 'punctuation', the edition below will, at
least, pass a syntax check. (You might check it very closely with yours to
see the changes I have made.)
Note: Input("prompt",min,max,default) in Metastock converts to
Param("prompt",default,min,max,step) in Amibroker, where 'step' is optional
and defaults to a value of 1.
<clip>
Value = Param("DEMA OffSet Periods",9,1,55);
Trigger = Param("Trigger Line",13,1,55);
Short =EMA(Close,3)+ EMA(Close,5)+
EMA(Close,7)+EMA(Close,9)+
EMA(Close,11)+EMA(Close,13);
LONG =EMA(Close,30)+EMA(Close,34)+
EMA(Close,38)+EMA(Close,42)+
EMA(Close,46)+EMA(Close,50);
MMACD =((Short-Long)/Long)*100;
MMACD1 =EMA(EMA(MMACD,Value),Value);
MMACD-MMACD1;
maDiffTrig=EMA(MMACD-MMACD1,Trigger);
Plot(0,"",1,1);
Plot(maDiffTrig,"maDiffTrig",2,1);
PlotShapes(Short*shapeDownArrow,colorRed,0,H,10);
PlotShapes(long*shapeUpArrow,colorGreen,0,L,-10);
GraphXSpace=2;
,colorGreen,0,L,-10);
<clip>
-john
----- Original Message -----
From: "bruiserbbq" <bruiserbbq@xxxxxxxxxxxx>
To: <amibroker@xxxxxxxxxxxxxxx>
Sent: Tuesday, April 06, 2004 4:52 AM
Subject: [amibroker] Re: Help with my modified MACD indicator
Ok here's what I have got so far ( but still a bit lost):
/* MMACD - DEMA Offset */
Value = Param("DEMA OffSet Periods",1,55,9);
Trigger = Param("Trigger Line",1,55,13);
Short =(EMA(Close,3, EMA(Close,5,
EMA(Close,7,EMA(Close,9,
EMA(Close,11,EMA(Close,13,
LONG =(EMA(Close,30,EMA(Close,34,
EMA(Close,38,EMA(Close,42,
EMA(Close,46,EMA(Close,50,
MMACD =((Short-Long)/Long)*100
MMACD1 =EMA(EMA(MMACD,Value,),Value,);
MMACD-MMACD1;
EMA(MMACD-MMACD1,Trigger,);
0;
AND HERE'S THE METASTOCK CODE I'M TRYING TO CONVERT:
Value:=Input("DEMA OffSet Periods",1,55,9);
Trigger:=Input("Trigger Line",1,55,13);
SHORT:=(Mov(CLOSE,3,E)+Mov(CLOSE,5,E)+
Mov(CLOSE,7,E)+Mov(CLOSE,9,E)+
Mov(CLOSE,11,E)+Mov(CLOSE,13,E));
LONG:=(Mov(CLOSE,30,E)+Mov(CLOSE,34,E)+
Mov(CLOSE,38,E)+Mov(CLOSE,42,E)+
Mov(CLOSE,46,E)+Mov(CLOSE,50,E));
MMACD:=((Short-Long)/Long)*100;
MMACD1:=Mov(Mov(MMACD,Value,E),Value,E);
MMACD-MMACD1;
Mov(MMACD-MMACD1,Trigger,E);
0;
Thanks in advance
Bruiser
downunder
Send BUG REPORTS to bugs@xxxxxxxxxxxxx
Send SUGGESTIONS to suggest@xxxxxxxxxxxxx
-----------------------------------------
Post AmiQuote-related messages ONLY to: amiquote@xxxxxxxxxxxxxxx
(Web page: http://groups.yahoo.com/group/amiquote/messages/)
--------------------------------------------
Check group FAQ at:
http://groups.yahoo.com/group/amibroker/files/groupfaq.html
Yahoo! Groups Links
------------------------ Yahoo! Groups Sponsor ---------------------~-->
Buy Ink Cartridges or Refill Kits for your HP, Epson, Canon or Lexmark
Printer at MyInks.com. Free s/h on orders $50 or more to the US & Canada.
http://www.c1tracking.com/l.asp?cid=5511
http://us.click.yahoo.com/mOAaAA/3exGAA/qnsNAA/GHeqlB/TM
---------------------------------------------------------------------~->
Send BUG REPORTS to bugs@xxxxxxxxxxxxx
Send SUGGESTIONS to suggest@xxxxxxxxxxxxx
-----------------------------------------
Post AmiQuote-related messages ONLY to: amiquote@xxxxxxxxxxxxxxx
(Web page: http://groups.yahoo.com/group/amiquote/messages/)
--------------------------------------------
Check group FAQ at: http://groups.yahoo.com/group/amibroker/files/groupfaq.html
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/amibroker/
<*> To unsubscribe from this group, send an email to:
amibroker-unsubscribe@xxxxxxxxxxxxxxx
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/
|