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

[amibroker] Re: Problems with Buyprice- please help


  • Date: Fri, 22 Jan 2010 05:11:37 -0000
  • From: "Mike" <sfclimbers@xxxxxxxxx>
  • Subject: [amibroker] Re: Problems with Buyprice- please help

PureBytes Links

Trading Reference Links

Looks like you have double negatives, resulting in a value greater than 1 (i.e. 1 - (-0.0359) = 1 + 0.0359 = 1.0359)

You are then multiplying that by the Open, thereby guaranteeing that the Low will be less than the resulting product. In the most optimistic case the Open will be the Low and you have already multiplied that by a factor greater than 1 before making the comparison.

Mike

--- In amibroker@xxxxxxxxxxxxxxx, "woodshedder_blogspot" <woodshedder_blogspot@xxx> wrote:
>
> D2=-0.0359;
> Filter=v>100000;
> Buy=Filter AND L<(Open*(1-D2);
> BuyPrice=Open*(1-D2);
> Sell=SellPrice;
> SellPrice=C;
> 
> No matter what the open is, this code will always generate a price lower than the open. The buy rule should guarantee that a buy will not be recorded if the low is not lower than the BuyPrice. Yet the buy is taking place, and I'm getting the HOD for the BuyPrice.
> 
> Any help will be greatly appreciated. I've been chasing my tail on this issue for two days now.
> 
> Thanks,
> Wood
>




------------------------------------

**** 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/