PureBytes Links
Trading Reference Links
|
Yes, you are right. I can rewrite it...
But 50 is not defined. But after searching in the WEB I think I translated it quite correctly.
Thanks, dubi
--- In amibroker@xxxxxxxxxxxxxxx, Rajiv Arya <rajivarya87@xxx> wrote:
>
>
> Can rewrite this
>
> summ = 0;
> for( i = 5; i < BarCount; i++ )
> {
> if ((22*KAdjusted[i]+8*DAdjusted[i])/30 >50) summ[i]=1;
> if ((22*KAdjusted[i]+8*DAdjusted[i])/30 <50) summ[i]=-1;
> }
> xAverage = EMA(Summ,5);
>
>
>
>
>
> to
>
> summ=iif(((22*Kadjust+8*Dadjust)/30)>=50,1,-1);
>
> xaverage = ema(summ,5);
>
>
>
>
>
>
>
> To: amibroker@xxxxxxxxxxxxxxx
> From: gonzales74@xxx
> Date: Thu, 12 Nov 2009 22:47:51 +0000
> Subject: [amibroker] digital Stochastic
>
>
>
>
>
> Hi,
>
> tried to translate this code from TradeSignal to Amibroker (but I think I did something wrong):
>
> TradeSignal Code:
>
> Meta:
> Synopsis( "Digitale Stochastic - (c)2008 kahler@xxx -
> Info: Trader`s 08/2008" ),
> SubChart( True ),
> WebLink( "http://www.quanttrader.at" );
>
> Inputs:
> PeriodStoch( 5, 1 ),
> PeriodSmoothing1( 3, 1 ),
> PeriodSmoothing2( 3, 1 ),
> OverBought( 80, 0, 100 ),
> OverSold( 20, 0, 100 );
>
> Variables:
> fast_k( 0 ),
> slow_k( 0 ),
> slow_d( 0 ),
> summ;
> { Berechnung fast_k, slow_k }
> StochasticNormal( High, Low, Close, PeriodStoch, PeriodSmoothing1,
> PeriodSmoothing2, fast_k, slow_k, slow_d );
>
> { Digitalisierung }
> if (22*slow_k+8*fast_k)/30 >50 then summ=1;
> if (22*slow_k+8*fast_k)/30 <50 then summ=-1;
>
> { Darstellung }
> DrawLine(xaverage(summ,periodStoch), "digitale Stochastic" );
>
> AFL:
>
> KAdjusted = StochK(5,3);
> DAdjusted = StochD(5,3,3);
>
> // Digitalisierung
> summ = 0;
> for( i = 5; i < BarCount; i++ )
> {
> if ((22*KAdjusted[i]+8*DAdjusted[i])/30 >50) summ[i]=1;
> if ((22*KAdjusted[i]+8*DAdjusted[i])/30 <50) summ[i]=-1;
> }
> xAverage = EMA(Summ,5);
>
> Plot (xAverage, "Stoch. Dig.", colorBlack);
>
> Is my code right?
>
> Thanks and regards, dubi
>
>
>
>
>
> _________________________________________________________________
> Find the right PC with Windows 7 and Windows Live.
> http://www.microsoft.com/Windows/pc-scout/laptop-set-criteria.aspx?cbid=wl&filt=200,2400,10,19,1,3,1,7,50,650,2,12,0,1000&cat=1,2,3,4,5,6&brands=5,6,7,8,9,10,11,12,13,14,15,16&addf=4,5,9&ocid=PID24727::T:WLMTAGL:ON:WL:en-US:WWL_WIN_evergreen2:112009
>
------------------------------------
**** IMPORTANT PLEASE READ ****
This group is for the discussion between users only.
This is *NOT* technical support channel.
TO GET TECHNICAL SUPPORT send an e-mail directly to
SUPPORT {at} amibroker.com
TO SUBMIT SUGGESTIONS please use FEEDBACK CENTER at
http://www.amibroker.com/feedback/
(submissions sent via other channels won't be considered)
For NEW RELEASE ANNOUNCEMENTS and other news always check DEVLOG:
http://www.amibroker.com/devlog/
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/amibroker/
<*> Your email settings:
Individual Email | Traditional
<*> To change settings online go to:
http://groups.yahoo.com/group/amibroker/join
(Yahoo! ID required)
<*> To change settings via email:
amibroker-digest@xxxxxxxxxxxxxxx
amibroker-fullfeatured@xxxxxxxxxxxxxxx
<*> 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/
|