PureBytes Links
Trading Reference Links
|
Hi Udo,
Thanks for the suggestion. I will see what this does. It is fairly
easy to compare relative stock performance against indicators, but not
directly against other stocks. As I have thought about it more, I may
be barking up the wrong tree as you could use a comparison say against
relative strength and then compare it to other stocks and still arrive
at the proper answer.
Thanks,
Bret
--- In amibroker@xxxxxxxxxxxxxxx, Udo Harke <udoharke@xxxx> wrote:
>
> Hello Bret,
>
> you can transform your data sets by the well-known transformation
>
> xNew = (xOld - xAverage) / sigma
>
> where xOld is the old (or former) array to be transformed, xAverage
the mean (or average) value of the old array over a period of
interest, and sigma denotes the standard deviation of the old data set.
> In this way the AFL-library function
>
> Plot(xnew, "xnew", colorBrightGreen, styleThick);
>
> displays the transformed data set that you can compare with other
transformed sets and also plot those sets, too.
>
> Best regards,
>
> Udo
>
>
> Quad Rate Serial Abby <quad_pumped_abby@xxxx> wrote:
> I have the following code. I am trying to normalize the price and
> plot the line of the slope of the average price over the last 15 days.
> This way I can turn it into an explore and use it to see which stocks
> are out performing relatively. I don't really need to plot the slope
> and I could take it out, but I would like to know why it doesn't work,
> because I suspect it may cause an error in the calculation of the
> array itself. If I take out the normalization division there is no
> problem. The error in the "Plot LineArray" is:
>
> Argument #4 has incorrect type (the function expects different
> argument type here)
>
> The code is:
>
> StartP = 15;
> EndP = 1;
> Price_Array = MA (( H + L ) / 2, 1 );
> LP1 = LastValue ( Cum ( 1 ));
> XP0 = LP1 - StartP;
> XP1 = LP1 - EndP;
> Base_Normalization = Ref ((( H + L ) / 2), -StartP );
> YP0 = Price_Array [ XP0 ] / Base_Normalization;
> YP1 = Price_Array [ XP1 ] / Base_Normalization;
> Plot ( Price_Array, "", 1, 1 );
> Plot ( LineArray ( XP0, YP0, XP1, YP1 ), "", 4, 1 );
>
> Thanks in advance for anybodys help,
>
> Bret
>
>
>
>
> 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 the Yahoo! Terms of Service.
>
>
> __________________________________________________
> Do You Yahoo!?
> Tired of spam? Yahoo! Mail has the best spam protection around
> http://mail.yahoo.com
------------------------ 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
--------------------------------------------------------------------~->
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/
|