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

[amibroker] Re: Simulated Stops Using BuyPrice/SellPrice



PureBytes Links

Trading Reference Links


I think I agree with you. Logically it should be as you say. If you 
inputted the code as it stands you may have an error message coming 
up since sellprice isn't defined until after it is used.

Sam


--- In amibroker@xxxxxxxxxxxxxxx, "walkegra" <walkegra@xxxx> wrote:
> 
> The AmBroker help file writes:
> 
> Quote:
> 
> BuyStop = ... the formula for buy stop level;
> SellStop = ... the formula for sell stop level;
> 
> // if anytime during the day prices rise above buystop level 
> (high>buystop) 
> // the buy order takes place (at buystop or low whichever is 
higher)
> Buy = Cross( High, BuyStop ); 
> // if anytime during the day prices fall below sellprice level ( 
low 
> < sellstop )
> // the sell order takes place (at sellstop or high whichever is 
> lower)
> ### Sell = Cross( SellPrice, SellStop); ###
> BuyPrice = max( BuyStop, Low ); // make sure buy price not less 
than 
> Low 
> SellPrice = min( SellStop, High ); // make sure sell price not 
> greater than High 
> 
> UnQuote
> 
> 
> Unless I misunderstand the content of the SellPrice variable I 
> believe the line marked ### above should read:
> 
> Sell = Cross(SellStop, Low);
> 
> as this would trigger when Low dipped below SellStop.  Is this 
> correct or am I missing something?





------------------------ Yahoo! Groups Sponsor --------------------~--> 
Has someone you know been affected by illness or disease?
Network for Good is THE place to support health awareness efforts!
http://us.click.yahoo.com/Rcy2bD/UOnJAA/cosFAA/GHeqlB/TM
--------------------------------------------------------------------~-> 

Check AmiBroker web page at:
http://www.amibroker.com/

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/