PureBytes Links
Trading Reference Links
|
<FONT face=Arial color=#0000ff
size=2>Generally speaking, most data vendors and institutions use the S&P
500 to calculate beta and they tend to use a 5-year lookback
period. IMO, current conditions dictate that we should be using a
much shorter lookback period. Personally, I use six
months.
<FONT face=Arial color=#0000ff
size=2>
IMO,
one should also apply the risk-free interest rate when calculating beta and many
people/date vendors do not. The AFL you found in the library does
not take the risk-free interest rate into consideration.
<FONT face=Arial color=#0000ff
size=2>
Like
many things that we do when developing trading systems, I don't think the
objective is to exactly match values with another source so much as have values
that work for us.
<BLOCKQUOTE
>
<FONT face="Times New Roman"
size=2>-----Original Message-----From: Dave Merrill
[mailto:dmerrill@xxxxxxx]Sent: Tuesday, September 02, 2003 11:04
PMTo: AmiBrokerSubject: [amibroker] AFL version of Beta
vs QuotesPlusthere's an AFL indicator set in the
library that computes Alpha, Beta andR-Squared. looking at relatively high
profile NASDAQ stocks, the beta valuesit generates don't line up with Beta
info from QuotesPlus. that makes mewonder about Alpha and R-Squared
too.there are only two parameters you can set for the AFL version: the
indexyou're comparing to, and the number of periods.- the index
I'd think was most likely would be !SPX, the S&P 500. I've trieda
number of others too.- my understanding is that the standard period,
if there is such a thing, is36 months. I took that to mean 3 years, or
256*3 trading days.any ideas? (full formula below for
reference.)Dave
MerrillFORMULA:--------------------------------------------Mkt
= "!SPX";Periods = 256*3;P = Foreign(Mkt,"C",1);Beta2 = ((
Periods * Sum(ROC( C,1) * ROC(P,1),Periods )) -(Sum(ROC(C,1),Periods) *
Sum(ROC( P,1),Periods))) / ((Periods *Sum((ROC(P,1)^2 ),Periods)) -
(Sum(ROC(P,1 ),Periods)^2 ));Alpha = (Sum(ROC( C,1) ,Periods) - ( Beta2 )
* Sum( ROC( P,1) ,Periods ) )/ Periods;R2 =
Correlation(P,C,Periods)^2;--------------------------------------------Send
BUG REPORTS to bugs@xxxxxxxxxxxxxSend SUGGESTIONS to
suggest@xxxxxxxxxxxxx-----------------------------------------Post
AmiQuote-related messages ONLY to: amiquote@xxxxxxxxxxxxxxx (Web page: <A
href="">http://groups.yahoo.com/group/amiquote/messages/)--------------------------------------------Check
group FAQ at: <A
href="">http://groups.yahoo.com/group/amibroker/files/groupfaq.html
Your use of Yahoo! Groups is subject to the <A
href="">Yahoo! Terms of Service.
Yahoo! Groups Sponsor
ADVERTISEMENT
Send BUG REPORTS to bugs@xxxxxxxxxxxxx
Send SUGGESTIONS to suggest@xxxxxxxxxxxxx
-----------------------------------------
Post AmiQuote-related messages ONLY to: amiquote@xxxxxxxxxxxxxxx
(Web page: http://groups.yahoo.com/group/amiquote/messages/)
--------------------------------------------
Check group FAQ at: http://groups.yahoo.com/group/amibroker/files/groupfaq.html
Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
|