[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: [amibroker] Please help in coding a loop involving formula



PureBytes Links

Trading Reference Links

Hi Terry,

Thanks once again for the effort....

I am attaching a graph. The upper frame shows your
plotted line. 

The below frame shows the example of the line the way
I am requesting it.(it shows SAR as line..which needs
to be converted to plot HHV/LLV).

Hope I am clear now....

Thanks and Regards,

Raajesh
--- Terry <MagicTH@xxxxxxxxxxx> wrote:

> Rajeesh,
> 
>  
> 
> Eliminating the places where HHV or LLV = today's
> bar is easy. See added
> test in each Plot statement.
> 
>  
> 
> //-------------------------------
> 
> Plot(C,Name(),colorBlack,styleCandle);
> 
> per = Param("Periods",20,5,100,1);
> 
> Highs = HHV(H,per);
> 
> Lows = LLV(H,per);
> 
> Plot(IIf(Highs > C AND Highs !=
> H,Highs,Null),NumToStr(per,1.0) + " bar
> HHV",colorGreen);
> 
> Plot(IIf(Lows < C AND Lows !=
> L,Lows,Null),NumToStr(per,1.0) + " bar
> LLV",colorRed); 
> 
> //-------------------------------
> 
>  
> 
> This still leaves areas where both lines will plot
> because your HHV-LLV
> conditions not mutually exclusive as they are in
> SAR. You can see this
> by plotting the new code above. What decisions do
> you want to make as to
> when one or the other is the "chosen" level to
> exclude the other? Or is
> this Okay as shown? It does look interesting in that
> it appears to show
> turning points quite well. However, I would look
> very closely at the
> area I have marked. There are some "false"
> indications in there for both
> HHV and LLV. 
> 
>  
> 
> 
> 
> --
> 
> Terry
> 
> -----Original Message-----
> From: amibroker@xxxxxxxxxxxxxxx
> [mailto:amibroker@xxxxxxxxxxxxxxx] On
> Behalf Of Raajesh
> Sent: Tuesday, November 22, 2005 03:24
> To: amibroker@xxxxxxxxxxxxxxx
> Subject: RE: [amibroker] Please help in coding a
> loop involving formula
> 
>  
> 
> HI Terry,
> 
>  
> 
> I am able to plot the 20 bar HHV and 20 bar LLV as
> 
> stylelines....
> 
> But just like SAR, I want only 20 bar LLV to be
> 
> plotted ( and not 20 bar HHV) as and when close
> 
> touches 20 bar HHV and continue plotting the same
> (i.e
> 
> 20 bar LLV) as long as close doesn't touch the 20
> bar
> 
> LLV.
> 
>  
> 
> As and when close touches the 20 bar LLV, the
> looping
> 
> shud enable plotting only the 20 bar HHV and stop
> 
> showing 20 bar LLV till the time close remains below
> 
> and doesn't touch 20 bar HHV once again...
> 
>  
> 
> 1)close touches 20 bar HHV ==== show only 20 bar LLV
> 
>  
> 
> 2)as long as close is not touching 20 bar LLV ===
> 
> continue plotting only 20 bar LLV
> 
>  
> 
> 3)close touches 20 bar LLV === show only 20 bar HHV
> 
>  
> 
> 4)as long as close is not touching 20 bar HHV ===
> 
> continue plotting only 20 bar HHV
> 
>  
> 
> Hope I am clear now.... :)
> 
>  
> 
> Thanks a lot for the effort.......friend
> 
>  
> 
> Regards,
> 
>  
> 
> Raajesh
> 
> --- Terry <MagicTH@xxxxxxxxxxx> wrote:
> 
>  
> 
> > Raajesh,
> 
> > 
> 
> >  
> 
> > 
> 
> > Your problem is not clearly defined. Without some
> 
> > acceleration towards
> 
> > the price, there is no reason for the line to flip
> 
> > above or below as
> 
> > does the SAR.
> 
> > 
> 
> >  
> 
> > 
> 
> > Changing the line style is the most basic of
> 
> > operations. Go to Help and
> 
> > type PLOT under the Index tab for a list of
> styles.
> 
> > 
> 
> >  
> 
> > 
> 
> > Try the code below. Makes somes changes. If that
> 
> > doesn't get the desired
> 
> > result, provide a better description of the
> problem
> 
> > and I will be happy
> 
> > to help you solve the problem, short of writing
> all
> 
> > the code for you.
> 
> > 
> 
> >  
> 
> > 
> 
> > Plot(C,Name(),colorBlack,styleCandle);
> 
> > 
> 
> > per = Param("Periods",20,5,100,1);
> 
> 
=== message truncated ===


((((( Raajesh Jariwala )))))



	
		
__________________________________ 
Yahoo! Mail - PC Magazine Editors' Choice 2005 
http://mail.yahoo.com

------------------------ Yahoo! Groups Sponsor --------------------~--> 
Try Online Currency Trading with GFT. Free 50K Demo. Trade 
24 Hours. Commission-Free. 
http://us.click.yahoo.com/RvFikB/9M2KAA/U1CZAA/GHeqlB/TM
--------------------------------------------------------------------~-> 

Please note that this group is for discussion between users only.

To get support from AmiBroker please send an e-mail directly to 
SUPPORT {at} amibroker.com

For other support material please check also:
http://www.amibroker.com/support.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/
 

PNG image