ࡱ> #"  !i%&'h)?+,-./0123456789:;<=>(@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefgj|klmopqrsuvwxyz{n~Root Entry Fpcr$Workbook>_VBA_PROJECT_CUR"W+BrErVBA`Er}Er \pTimothy R. Mayes, Ph.D. Ba= ThisWorkbook=ixKU28X@"1Calibri1Calibri1Calibri1Calibri1Calibri1 Calibri1Calibri1h8Cambria1,8Calibri18Calibri18Calibri1Calibri1Calibri1<Calibri1>Calibri1?Calibri14Calibri14Calibri1 Calibri1 Calibri1Calibri1 Calibri"$"#,##0_);\("$"#,##0\)!"$"#,##0_);[Red]\("$"#,##0\)""$"#,##0.00_);\("$"#,##0.00\)'""$"#,##0.00_);[Red]\("$"#,##0.00\)7*2_("$"* #,##0_);_("$"* \(#,##0\);_("$"* "-"_);_(@_).))_(* #,##0_);_(* \(#,##0\);_(* "-"_);_(@_)?,:_("$"* #,##0.00_);_("$"* \(#,##0.00\);_("$"* "-"??_);_(@_)6+1_(* #,##0.00_);_(* \(#,##0.00\);_(* "-"??_);_(@_) 0"-Year"                                                                       ff + ) , *     P  P         `            a>      h@ @  &x@ @  "x @ @  "| @ @   (@ @    ,@ @  Q  ||Gǥ}-} 00\);_(*}-} 00\);_(*}-} 00\);_(*}-} 00\);_(*}-} 00\);_(*}-} 00\);_(*}-} 00\);_(*}-} 00\);_(*}-} 00\);_(*}-}  00\);_(*}-}  00\);_(*}-}  00\);_(*}-}  00\);_(*}-}  00\);_(*}-} 00\);_(*}-} 00\);_(*}(}5  00\);_(*}-}? 00\);_(*}A}@ 00\);_(*;_(@_) }A}A 00\);_(*;_(@_) }A}B 00\);_(*;_(@_) }A}C 00\);_(*;_(@_) }-}D 00\);_(*}-}E 00\);_(*}(}F  00\);_(*}-}+ 00\);_(*}-}, 00\);_(*}-}- 00\);_(*}-}. 00\);_(*}-}; 00\);_(*}-}< 00\);_(*}A}1 00\);_(*;_(@_) }A}2 00\);_(*?;_(@_) }A}3 00\);_(*23;_(@_) }-}4 00\);_(*}A}0 a00\);_(*;_(@_) }A}( 00\);_(*;_(@_) }A}8 e00\);_(*;_(@_) }}6 ??v00\);_(*̙;_(@_)    }}: ???00\);_(*;_(@_) ??? ??? ??? ???}}) }00\);_(*;_(@_)    }A}7 }00\);_(*;_(@_) }}* 00\);_(*;_(@_) ??? ??? ??? ???}-}> 00\);_(*}}9 00\);_(*;_(@_)    }-}/ 00\);_(*}U}= 00\);_(*;_(@_)  }A}" 00\);_(*;_(@_) }A} 00\);_(*ef;_(@_) }A} 00\);_(*L;_(@_) }A} 00\);_(*23;_(@_) }A}# 00\);_(*;_(@_) }A} 00\);_(*ef;_(@_) }A} 00\);_(*L;_(@_) }A} 00\);_(*23;_(@_) }A}$ 00\);_(*;_(@_) }A} 00\);_(*ef;_(@_) }A} 00\);_(*L;_(@_) }A} 00\);_(*23;_(@_) }A}% 00\);_(*;_(@_) }A} 00\);_(*ef;_(@_) }A} 00\);_(*L;_(@_) }A} 00\);_(*23;_(@_) }A}& 00\);_(*;_(@_) }A} 00\);_(*ef;_(@_) }A} 00\);_(*L;_(@_) }A}  00\);_(*23;_(@_) }A}' 00\);_(* ;_(@_) }A} 00\);_(*ef ;_(@_) }A} 00\);_(*L ;_(@_) }A}! 00\);_(*23 ;_(@_)  20% - Accent1M 20% - Accent1 ef % 20% - Accent2M" 20% - Accent2 ef % 20% - Accent3M& 20% - Accent3 ef % 20% - Accent4M* 20% - Accent4 ef % 20% - Accent5M. 20% - Accent5 ef % 20% - Accent6M2 20% - Accent6  ef % 40% - Accent1M 40% - Accent1 L % 40% - Accent2M# 40% - Accent2 L湸 % 40% - Accent3M' 40% - Accent3 L % 40% - Accent4M+ 40% - Accent4 L % 40% - Accent5M/ 40% - Accent5 L % 40% - Accent6M3 40% - Accent6  Lմ % 60% - Accent1M 60% - Accent1 23 % 60% - Accent2M$ 60% - Accent2 23ٗ % 60% - Accent3M( 60% - Accent3 23֚ % 60% - Accent4M, 60% - Accent4 23 % 60% - Accent5M0 60% - Accent5 23 %! 60% - Accent6M4 60% - Accent6  23 % "Accent1AAccent1 O % #Accent2A!Accent2 PM % $Accent3A%Accent3 Y % %Accent4A)Accent4 d % &Accent5A-Accent5 K % 'Accent6A1Accent6  F %(Bad9Bad  %) Calculation Calculation  }% * Check Cell Check Cell  %????????? ???+ Comma,( Comma [0]-&Currency.. Currency [0]/Explanatory TextG5Explanatory Text % 0Good;Good  a%1 Heading 1G Heading 1 I}%O2 Heading 2G Heading 2 I}%?3 Heading 3G Heading 3 I}%234 Heading 49 Heading 4 I}%54 Hyperlink   6InputuInput ̙ ??v% 7 Linked CellK Linked Cell }% 8NeutralANeutral  e%3Normal % 9Noteb Note   :OutputwOutput  ???%????????? ???;$Percent <Title1Title I}% =TotalMTotal %OO> Warning Text? Warning Text %XTableStyleMedium9PivotStyleLight16`1 MACRS Table% MACRS_Table;/Year MACRs ClassTotalSource: J1 ccB4c =_MA  3_=  dMbP?_*+%,&ffffff?'ffffff?(?)?",4c333333?333333?To&<3U,; ,,,,,,, , , , , ,,,,,,,,,; ,,@ AAAAAA B*C@C@C@C$@C.@C4@~ ??ioT?~ ?4@?_LJ??$@?@?@~ @? r?~ ?@@?+eX??2@?#@?B&9 {?~ @?D??~jt?? c??;On??S??Z?~ @?37??H}??8EGr??H}??ʡE??qrCQ?~ @??H}??ec]ܶ??|Pk??v??=$@?~ @??H}??ͪն??Y޲????W/'?~ @ ???ec]ܶ??S㥛İ??h|?5??aۢ?~  @ ?? ?ͪզ? ?S㥛İ? ?h|?5? ?@j'?~ "@ ??? ? ^)˰? ?cZB? ?~nئ?~ $@ ??? ?S㥛İ? ?h|?5? ?,&6צ?~ &@ ??? ? ^)ˠ? ?cZB? ?~nئ?~ (@ ?i|?5? ?,&6צ?~ *@?cZB??~nئ?~ ,@?i|?5??,&6צ?~ .@?cZB??~nئ?~ 0@?i|?5??,&6צ?~ 1@?~nئ?~ 2@?,&6צ?~ 3@?~nئ?~ 4@?,&6צ?~ 5@?~nؖ? D#E? %M#E? %MM#E? %MM#E? %MM#E? %MM#E? %MM F mz/http://www.irs.gov/publications/p946/index.htmlAIRS Publication 946 (Cat. No. 13081F): How to Depreciate PropertyBgDAIRS Publication 946 (Cat. No. 13081F): How to Depreciate Property68 ,<\hzzrrddTTT22222 >@liji Sheet1ggD ThisWorkbookSheet1 FAME_Functions *__SRP_2 > !"#$&'()*+,-./0123456789:;<=>?@ABCEFGHIJKLMNOQRSTUVWXYZ[\]^_`abcdefghijkmopqrstuvxyz{}'D}#xME (SLSS<N0{00020819-0000-0000-C000-000000000046}@(%H@0OJ xAttribute VB_Name = "ThisWorkbook" Bas0{00020P819-0C$0046} |GlobalSpacFalse dCreatablPredeclaIdTru BExposeTemplateDerivBustomizD2'DPP#xME (SLSS<N0{00020820-0000-0000-C000-000000000046}@(%H@0OJ xAttribute VB_Name = "She@et1" Bast0{00020820- C$0046} |Global!SpacFalse dCreatablPre declaIdTru BExposeTemplateDeriv$Bustom izD2  (HPpx    6 * N (0 8HPX`B h Bp 6B  6  $X B  : *0 B 8 0@p B  > > B  >h 0DZ0  B @ 4  ( 0 :@ D     00 `  h 0x @ ((o]DnxME(0*6 < <& `@ --I `I I  i"  Calculates depreciation expense for Year using MACRS with the half-year convention. MacrsClass is 3, 5, 7, 10, 15 or 20.Table is optional, 0 for exact or 1 for table lookup. Default is 0. 14`$`& (% <``  I> @I@ Calculates the Effective Annual Rate of a periodic rate. For example, if you know that a quarterly rate is 2%, this function will tell you that is 8.24% annualized. 14 B@`8P ID p6IF >IH FCalculates the intrinsic value of a stock using the constant growth dividend discount model (also known as the Gordon Growth Model). 14 J` ID IL IH Calculates the Cost of Equity, or Required Return, of a stock using the constant growth dividend discount model (also known as the Gordon Growth Model). 14 N`( IP IR IT Calculates the required return for a security or portfolio using the CAPM (Capital Asset Pricing Model) using the risk-free rate, the expected market return, and the security's beta.  14 VP`X0  )XP$%Calculates the geometric mean rate of growth for a series of dollar values. The first cash flow in the list must be the most recent cash flow, and the last must be the oldest cash flow. 14`Z`\ `8 `  )b%Id Calculates the payback period of a series of cash flows. The first cash flow must be the (negative) initial outlay. The discount rate is an optional argument. If it is provided, this function will return the discounted payback period. 14`f `h@j `l n ` 0 x )p %)r %_Calculates the variance of a random variable given the probabilities of each potential outcome. 14`t `v`l |X `8 )~ %)  %)r0 %Calculates the covariance between two variables using the probabilities of occurrence for each value. Excel's Covar() function does not handle the probabilities of occurrence. 14` @ ``l  ` )~ %) %)r%Calculates the correlation coefficient between two variables using the probabilities of occurrence for each value. Excel's Correl() function does not handle the probabilities of occurrence. 14`  `8 )pX`%)r%iCalculates the standard deviation of a random variable given the probabilities of each potential outcome. 14`  `X )px%)r%Calculates the coefficient of variation using the probabillties of occurrence. Excel does not have a similar function. This is a measure of risk per unit of return, and is calculated by dividing the standard deviation by the expected value. 14` z `P )p (%)rH%cCalculates the Expected Value of a random variable using the probabilities of each potential value. 14` `  `0 )pPX%)x%Calculates the expected return for a portfolio of securities given the expected returns of each security and their weights in the portfolio. 14 `X )x%)%Calculates the Variance of a portfolio of securities given a variance/covariance matrix and the weights of the individual securities. Note that you must supply a complete variance/covariance matrix, not just the upper or lower diagonal. 14` @ ` P`( )HP%)px%)%Calculates the Variance of a portfolio of securities given a correlation matrix, and the standard deviations and weights of the individual securities. Note that you must supply a complete correlation matrix, not just the upper or lower diagonal. 14 ` @ `( `0  ID I I I I Calculates the intrinsic value of a stock using the Two-Stage Dividend Discount Model. Note that G1Periods is the length of the first period of growth. 14@ ` (`H  ID hI I I I I Calculates the intrinsic value of a stock using the Three-Stage Dividend Discount Model. Note that G1Periods is the length of the first period of growth, and TransPeriods is the length of the transition period between fast growth and constant growth. 14` `hh Ib I Calculates the Modified Internal Rate of Return for a series of cash flows. This is different from Excel's built-in function in the way that it handles negative cash flows after period 0. 14`@ ` `  I I 8IH XI xI Calculates the present value of a graduated annuity. Note that BegEnd is an optional argument that describes whether the cash flows occur at the end (0) or beginning (1) of the period. End of period cash flows are assumed if the BegEnd argument is omitted 14 !` ! I  I 0 IH P I p I Calculates the FV of a graduated annuity. PMT is the first payment amount, NPer is the number of periods, GrowthRate is the payment growth rate, DiscRate is the required return, and BegEnd if the payments are at the end (0) or beginning (1) of the period. 14 #`"#! i"i("I H"I h"I "I `Calculates the convexity of a bond. Note that this function only works on a coupon payment date. 14@ @ @ `@ ` `$` @ @ @ @ ` `$%$ I $I Returns a normally distributed random variable with a given mean and standard deviation. Note that this function is volatile, and will return a new result each time the worksheet is recalculated. 148 P!X  P#`$(@p&%`$H&%%OJ *\R1*#222$*\Rffff*0k4c14df45a HHPB X hh J L  Jp D$ H"h   (  ( B 0 88 p x  <       .(  X h p x B  :    , 08@Xp<  B  <8 ,@p l (088px B  B  8 @P`hpx B  H " HPX B ` >h   8HPX B ` Bh B  J(0 @`x 8  F0`  B  R ( 28p" 4 0( X hx B  D 8 6P B`B$B   R( 0N  B  ` *x \ D( *p0  V4PB  . x.HBxv@HB P L`2B  ( * Pp&L@ H  `  ^p   > ! !.0!`! B h! 2p! ! !!!!!"0""P"x""" B " X" \# `#p## #BAll macros here are Copyright 1994-2009 by Timothy R. Mayes, Ph.D.0(bCalculates the MACRS depreciation for an asset with a MACRS class of 3, 5, 7, 10, 15, or 20 years.CThis function returns the depreciation expense for a selected Year.EThe function either uses the IRS table value or an exact calculation,D depending on the value of Table. Default is 0 (use exact result).>Will return #Value! error if MacrsClass or Year are incorrect.]]]A3:G23 %,%*.( "Do a table lookup     .!0 KT   (72'&KT   (72'&KT   (72'& KT   (72'&KT   (72'&KT   (72'&tS` 4Y('&40nHq@d8 4Y('&iaTypek d -Calculate the exact result using VDB functiones             G'$cG?'$j .!0LHUB   ? 78 ? 7: $76'&qd 4Y('&kk &'i<Calculates the effective annual rate given a per period rate/See also Excel functions Effect() and Nominal() >  @ '<Hi/Calculates the value of a constant growth stockusing the Gordon Growth Model D F H 'Bi`@3Calculates the cost of equity for a constant growth#stock using the Gordon Growth Model( D L H 'J.i)Calculates the required return using CAPM P T R P  'NFih7This function is intended only to be used in Chapter 1.8It is an example that calculates the geometric mean rate;of growth in sales. Any other use is strongly discouraged.7Note: The first value is assumed to be the most recent.] ]8 X!^'Z<Get the count of sales figures$X Z$X'\<#Calculate the total growth in salessCla \ Z  'V</Take the Nth root and subtract 1 to get geomeanis 0.ihP9Calculate the payback period or discounted payback period.Note that the first cash flow must be negative] ] ]  b!^'j$(Upper bound (i.e., number of cash flows) Effec'h$6Cumulative sum of cash flows, stop when greater than 0 qua'l$Counter variableon dG dd'djnn h l j b l 'l h l$b d  l  'h h6 h l$b d  l  'h l  h l$b d  l  'f f'`dPayback > Life'`( Report errorki8 2Calculates the variance with unequal probabilities]8 ]P ]h r!^ p!^0!If counts not equal, report errorCounts not equal'txk't p r$z'v or Re l p!^oc t l$p v  l$r 'tmo lknown x t'ni 4Calculates the covariance with unequal probabilities] ] ( ]@ r!^ ~!^ r!^ !^Counts not equal'xk ~ r$z' for a  r$z'olio u l ~!^ A  l$~   l$   l$r 'arke land thx  '|iX 5Calculates the correlation with unequal probabilities] r!^ ~!^ r!^ !^*Counts not equal'xpkheCheck to see if the ranges are identical. If so, avoid error by returning 1. This avoids returning 0. ~! !'xk ~  r$| ~ r$  r$'x 'ix<Calculates the standard deviation with unequal probabilities] r!^ p!^Counts not equal'xk p r$n'x $~a $'d 'kiBCalculates the coefficient of variation with unequal probabilities] r!^ p!^Counts not equal'x k ' p r$ p r$z'x 'i 8Calculates the expected value with unequal probabilities]] r!^ p!^Counts not equal'x k '  p!^  $p $r ' x 'zi <Calculates an expected portfolio return with unequal weights  p$z'i0 DCalculates the portfolio variance using a variance/covariance matrix]] !^ !^Counts not equal'x kx '  !^   !^  $ $  $ '    !^")subtract out what we double counted above  $ $  $ ' xX 'iH KCalculates the portfolio variance using the correlation matrix and std devs]]] !^ !^ !^ !^Counts not equal'xp kh  !^ !^H  !^  !^  $ $ $  +  $ $  $ '  x 'ipP>Calculates the value of a stock with two dividend growth rates2Note that GrowthRate1 must not be equal to ReqRate/Note that GrowthRate2 must be less than ReqRate] D         ' D         '      'iKCalculate the intrinsic value using the three-stage dividend discount model] D  '$Calculate dividend 0             'i(YThis function calculates the MIRR by taking all future cash flows forward to the terminal$period and then solving for the IRR.UNote: Cashflows must include the initial outlay, and initial outlay must be negative.]p]' b!^'2Don't include initial outlay in count of cashflows#Get total Future Value of cashflows    $b      ' OCalculate geometric mean rate of return between initial outlay and future value $b   'ip(Calculates the PV of a graduated annuityrPmt is the first annuity payment, NPer is the number of payments, BegEnd is 0 for END of Period or 1 for BEGINNING Cash Flows at END of period   H  H     'd8  H  H   H  H       'kiECalculates the future value of a graduated annuity by using FAME_PVGA   H  $   'i!"Calculates the convexity of a bond$Only works on a coupon payment date!]#0#H#`#]x##m  $'m  $  '  '  '  '           '-'  `           '<Weighted sum of PV of cashflowsd(           '-yk crsCla     ' 0i#,Calculates a random standard normal variable]#$$0$H$_0A@4$ 'A@4$ '   '>     $ $'ates t  'nn  'pei``$RGenerates a normally distributed random number given a mean and standard deviationUThis function will generate new random numbers whenever the worksheet is recalculated .B@p    'iphAttribute VB_Name = "FAME_Functions" 'All macros here a Copyright 1994-2009 by Timothy R. Mayes, Ph.D.  Op Exp licit Ba@se 1 p ~MACRS(Cost,GcrsClasLYear, Kal Table As BooleanFalse) P.Desc riCalculates depreciaS expenLfor : using K with the half-yI con8ven|X is 3, 5, 7, 105 (20.\oE@al, 0 6ePxact1tplookup. Default+0.rPro cDataxIn0voke \n14|2C6@#T^et= 1) AndR <=I+TXhen'WeApA~j.As}S"? Ca~wk 3ab(= a * .VLbg,C), 2,0i 5 o  7 4y10  1?$;06<2? :E?$VErrx(xl}$h9EacVa_/ Ts7 Ifc'ƶiDVDBox"]r<_g>(8d3) Or ;5? 7? pO 1= 20)~)I` 0H1n0SLT 1.\*?I`S?I6p.VdbD|, .Max(0R- @)AinR- 0.4 % #;#)# *E$pa XCEAR(Periodic_R0, NPER1/` "LEff}iv0nnuGQqa p br. Fq-m ple, `uyo@u knowP/atjquarterly2%,wipzte@th8.24% aizezd_ __ e gn@ 0'trSeдls"opcelv;s () d Nominal("b0 @(1 + :) ^V (/#GGM#(Div1, ReqRe Growth%in`nsic Ft8ockJᛀst ant g2 d0ivid scDoumod(-po" se 0GordP Ma)_ //, s P / >l;27 / (*[9`эEquityR, Z:j c uir@"0fP-Rdiܞ Goolcos`f eRaQ(  W:]9-CAPM(RiskFreeq8!rketBeta9ar1ar_eturn for a secu rity hportfolio using the CAPM (Capital Asset Pric>Model)Xrisk-free rate,expected markxr, and's beta." Attribute FAME_.VB_ProcDa" Invoke_Func = " \n149'CaPlcul|s\requir|uqP /"R^F]R + BF * (M[R- ) EbBtion  \Geomean(DollarValues Range tuDescrip+o kg+c / of growth,ri6 d> v?. Tfir@st cas@ l ow inKliI@mubemorecenH nla old>ePs9!tThpis fyBi ntendtonly to@u0Chapter 1. 'It an exampl4aA1 PRRsales`. Anɀrstrong!discouragedNote:Y^"ssu>m@*-AW@Dim DVCou@[As I@:ger SA!GxrSleA =: I.C'G?r` figurescd)A (1) /J($)gqBIto?DT*pB] ^ (1` - 1 ))!'TakTN^rootsubtract 1Cg@Va riantCupmSumEmpCFbj, tY;DXCH q'Up> b|d (i.e., numb o?Ka\wNo'`@ Ig, sto@p whener#n 0 FW'evbG"R0>= 6 *nmz=c/ 10Do WhikWT <A su<^ =6+< 1s+ ]f(AIPC+) D5CLoop 0a[pB-&=Дd- 2L/aG  $" K'ElsbQ "E> Life" 'Req errog!QSIf͎3( ,obabilI_SF"L2(nceRr9om@0;) g0C@LH05eac(h p@ynRcomeJ_doJ C wihun`XcE CFAvgFd"?F0+@ WF<> #9'}s nr ,\M R,8е!1GoTo Macro!4&@=_!"Xt@ =#Exp2 "<"-F^{U42Fo #V+f G4- 3263NextuG %:26`5[1CoP+1, 2Z v22ca&Pwe`two=2s0qr2ocy re6132. Excel's q )do>%~hp9_87_ onoh8Gt}/8g1,"rj8(5( 81) Or F;2a;'r_9l_9_9 01+A,_ExpValue(Ps1, Probabilities) Avg2 = PFAME 2bFor Counterp1 To .,Covariance() + (H) - 1) *z2 2  qNext MacroEnd:'oA E  Function  CorrU As Range,w2 L Attribute(.VB_Descrip:H"Calculates thet c;eIefficient between two blAusingp of occPurreA`fmeach. Excel's@L l() fDA donot handle]."  T9@EcDataAwith unequal 6 Dim.aQ5gVtAqAIf (e <>˫P) Or\ 2) The@AAi= "²s AN,@7E Go@ɅC If'Check to sePe if\rs( ar@d@ical. @5so, avoid err@uby return1.)i s0.c uAddresfs1#2.%1A#Gp%ji  / (StdDev9prh'bstnard devi[@yDa Bdom xgiva~}p otF`goutcome0ug@+u˔]v rvJA֐5?*;*PortRet3q$ɀWeights_[))frS a pfolio'sep(W|s*y pir w i{O,_x ?,?,8,an 6 T ,CT(t?`Kq01(@MatOO_]prtfolio of securities given a variance/co( matrix and the weightsindiv idual. Note\at you must supplycomplem, not j6d9er or lowdiagonal." $AtbuMFAME_PortVar1.VB_ProcData Invoke_Func = " \n14'Calculat4pusing Dim P; As Bt i, j Integer If (CovMat.Count <> W^ 2) Then3aseqfGoTo MacroEndX IfD0CFUiD1 Jji D+ 2 * (D(i)@j%?(AI))Nexi*'subtract out whwe double cWed `aboveC ,-^*.*i*&EZ:D)ɡMAC `Atios E 2(Co rr@ARange, StdDe|vsHQF$2Descrip{A#"L^@B~za `cee%,&st`ard devia sb?es?"?9"$? ? #!stb#sc#(`7߇Ň#LADOr (G Redo, o aq{eg`^%"}ja=+s7i jr2!TwoStageValue(Div1, ReqR`, Grpowtha2 1Period>sPBC CinwnsicЂ sC`stock00-Eb  ideDisRX Model ?G is2length4hfirp 1g{B_ =PvaQa 3 wiptwo r  rQ '#Ibe#4 touO"2ClesYanQ5V@Vj2Q_S0lpl%V1# / ( L - v(10(P+01 +)) ^ $1@= &3^ ('- 1y2p cDbp*P +}p2 Y L uuThree(/3uH3)3, Trans4e{/4/4/4&GdRO4O4sO4`O4B{ /8!8p?t8betwe90fa91!conqt 3_:_wBMHgt-0g!;dGnmGw304R=QK15'") xAoY&909t~eн05@0/*++(ҵ ?6- m_MIRR(CashFsdinvestd`9b--]ifikAr` !UReturn f/U\P`c f.+ differe0from Excel's built->i0(*wayc0it hp(T negPv aft4,0)N_5ccTh fMc bP akll fu;wab6er|mib$ !5n solvq.td: d@include inal 0lay, uand initial outlay must be negative. Dim FutureValue As SinglehN, i&Integer  ^= 0(N = CashFlows.Count 'Don't clude in c&of c9f9L'Get totl )For= 2 To N="!+S(i) * (1 + ReinvestRate) ^ (N - i)(Nexb'Calcul geometric mean r Prentweenzef v*FAME_MIRRE(V/ -(1)M1 /O@- 1 EFunction  BPVGA(Pmt, Nper, Growth9, Dis2cCOp[BeNgAu?At7bute.VB_DescriB +"FDs the `prese@7 Da graduGd annui@ty. No@that Dis o!argum dBbes hwherBA  occur @A eC(0) beginn@ yfC(eriod. :'E Dare ass? D)%+omitted" IProcDataLInvoke_fL \n14'@OPVTL 'q A8firÀS payJ@x PeCnumb's,H-0 f#END  1BEGINNINGSIf1B ThZsh b}.)pZO V%NkQp- (bq @s`X$sEls a d{ + (! s) RIfuFue,^ u A uFuM.0 PMTKMDL amA6MkMG+g珅req@uired c, dVdwY btĿ }}u$u uiTv by usaccabF{CdQ+aNKC omxW(SetxtleU~IP%Ma0k~Fac #, |pon, Yld, F1ency-lO&'=bcbonX)'athpNfm only workrs aQUO de.Xll/ d0XO!PS, P#+, temp>iS3z= Diff("m", , UDFc\s@%`(oChp129qT@Q/+ * $#RZ_b^1- _/'@S4š1CQ`mi < trmS`( tck ãi2@'Weigh -|kk7+#)iAwG Qf92F0S>2c =E v 7`rmDev(`(YRa@^ndom st@ard normalpriab%V1, V2H, REaca2sGsIouӒCDoR@2zV1 -Rnd()x21^+ Loop Until (R#1) AR > 080Sqr(-Log(RARG'= P"2 N V/qQal(M`BtdYsY"RB Dly disԿxA withXg@ndevrionyK]^v2o`il@Rwill a wsult each timer`he!rec:d/`_?`?`Geneq܏iaІĵa 0cTlrgts`23nevh(ApplicV$F>AME_RandNormal = (HDev * Std@) + Mean End Functio4 rU~|      urU 8`Q!9 ///,` __SRP_3%_VBA_PROJECTt'dirD__SRP_0 P//0` ay///0` a///0!` I q  ///,I` I =) 4q`   =) 8`=) =) D` =) =) =) D ` q=) =) =) 8 `=) =) 89 ` =) =) 8a `=) =) 8 `=) =) 8` =) =) D`  =) =) =) <`ya9Y/////@)` a9Y//////,Q`1"  "//<y` $###////<` (###////@`**1*Q*q***,,////$ `,1`&++//nͲ0* pHdFameFncs>4unctions for Financial Analysis with Microsoft Excel, 5(Ed.@|unctio s f rFnai lA alXys-wthM cr=sfS ETx]e1,!5)Ed.=x OPiFacD GasDevGset$RndRLogd(FAME_RandNormalMean@StdDev$VolatileWorkbookk`    6$T`R(ct Library*\G{00020430-0000-0000-C000-000000000046}#2.0#0#C:\Windows\system32\stdole2.tlb#OLE AutomatJ <stdole> s+d9leD E^*\G{00020430-C 0046}#2.0#0#C:\Windows\system32\22.tlb#OLE AutXomaEEOPfficEOfkEE2DF8D04C-5BFA-101@B-BDE5"A*A!42"Pr ogramvles\CommontShared\OFFICE12\MSO.DLLL#G& 18 Object Library%"BDBTThisWorkbookG TUi@}WYrkbo* 2  HB1Bx-B,!}"B+BB|ShePet1GS@#eA@{t1H2SNPPF AME_FGAAFAM@_FNO 2^ 'u]!n!"!!b, 5th Ed.OJ K*rU~~~~~~o DODN~v~     9 p91Iq 9q ) )FameFncs ThisWorkbookSheet1FAME_FunctionsF /C:\PROGRA~1\COMMON~1\MICROS~1\VBA\VBA6\VBE6.DLLVBA Q y0F4C:\Program Files\Microsoft Office\Office12\EXCEL.EXEExcel Iq@0FC:\Windows\system32\stdole2.tlbstdole YPL-[DR?C:\Program Files\Common Files\Microsoft Shared\OFFICE12\MSO.DLLOffice a` FAME_MACRSFAME_EAR FAME_GGMValueFAME_GGMCostEquity FAME_CAPM FAME_GeomeanFF FAME_PaybackFAME_Var FAME_Covar FAME_Corr FAME_StdDevFAME_CV FAME_ExpValue FAME_PortRet FAME_PortVar1 FAME_PortVar2FAME_TwoStageValueFAME_ThreeStageValue FAME_MIRR FAME_PVGA FAME_FVGAFAME_ConvexityNormDevFAME_RandNormal Uounter(FAME_VThisWorkbookThisWorkbookSheet1Sheet1FAME_FunctionsFAME_Functionsal Analysis with MicrID="{235A77C4-96CC-4691-9FD6-2A36F010C9BA}" Document=ThisWorkbook/&H00000000 Document=Sheet1/&H00000000 Module=FAME_Functionsa  *\G{000204EF-0000-0000-C000-000000000046}#4.0#9#C:\PROGRA~1\COMMON~1\MICROS~1\VBA\VBA6\VBE6.DLL#Visual Basic For Applications*\G{00020813-0000-0000-C000-000000000046}#1.6#0#C:\Program Files\Microsoft Office\Office12\EXCEL.EXE#Microsoft Excel 12.0 Object Library*\G{00020430-0000-0000-C000-000000000046}#2.0#0#C:\Windows\system32\stdole2.tlb#OLE Automation(*\G{2DF8D04C-5BFA-101B-BDE5-00AA0044DE52}#2.4#0#C:\Program Files\Common Files\Microsoft Shared\OFFICE12\MSO.DLL#Microsoft Office 12.0 Object Library  |Functions for Financial Analysis with Microsoft Excel, 5th Ed.OJ DThisWorkbook0>4c14dec2ThisWorkbook}- Sheet10?4c14dec2 Sheet1PP-FAME_Functions0k4c14df45FAME_Functionsn0u]P0psjjG({R[(`|(Hp]:/h;fvJ(澩07 Excel+ VBAWin16~Win32MacVBA6# FameFncsstdole`Officeu ThisWorkbook| _Evaluate Sheet1 FAME_Functions (FAME_MACRSӥCost4 MacrsClassWYear6nTableFactorDeprO MacrsTableGRange Sheets  Application*WorksheetFunction&VLookup xlErrValueVdbBMaxȲMin(FAME_EAR  Periodic_RateiNPERYear (FAME_GGMValueDiv1fReqRet+ GrowthRateƵ(FAME_GGMCostEquitywValueK (FAME_CAPM4Y RiskFreeRate MarketReturn[Beta. (FAME_Geomean% DollarValuesDVCountX SalesGrowtht]Count0v (FAME_Payback CashFlowsi|Ratek PayBackdCumSumDCFCountCounter(FAME_VarjValues ProbabilitiesVariancenAvguMacroEndA (FAME_ExpValueK (FAME_Covar%Values1uValues2u CovarianceAvg1IXAvg2JX (FAME_Corra Correlation?Address (FAME_StdDev StdDeviation IsNumeric$*Sqr((FAME_CVX CoefVariationQExpValue3i` (FAME_PortRetWeights[ (FAME_PortVar1! VarCovMatAPVarja (FAME_PortVar2"CorrMatRStdDevsBCovMat (FAME_TwoStageValueReqRateD GrowthRate1  GrowthRate2  G1PeriodsցV1t_V2u_(FAME_ThreeStageValueN TransPeriods`Div0f (FAME_MIRR< ReinvestRate8 FutureValueNe (FAME_PVGAPmtNperADiscRateTBegEndn (FAME_FVGA(FAME_Convexity,  SettlementeMaturity FaceValuezCoupon9BYld FrequencyPricegSjPaymenttempRPeriodsXDateDiffNormDevR__SRP_1`PROJECTwmlkPROJECT n=SummaryInformation(s. This is different from Excel's built-in function in the way that it handles negative cash flows after period 0.NperDiscRateBegEnd@Calculates the present value of a graduated annuity. Note that BegEnd is an optional argument that describes whether the cash flows occur at the end (0) or beginning (1) of the period. End of period cash flows are assumed if the BegEnd argument is omitted1Returns a normally distributed random variable with a given mean and standard deviation. Note that this function is volatile, and will return a new result each time the worksheet is recalculated. @Calculates the FV of a graduated annuity. PMT is the first payment amount, NPer is the number of periods, GrowthRate is the payment growth rate, DiscRate is the required return, and BegEnd if the payments are at the end (0) or beginning (1) of the period. SettlementMaturity FaceValueCouponYld Frequency`Calculates the convexity of a bond}. Note that this function only works on a coupon payment date.MeanStdDev  DollarValues/Calculates the geometric mean rate of growth for a series of dollar values. The first cash flow in the list must be the most recent cash flow, and the last must be the oldest cash flow. CashFlowsRate;Calculates the payback period of a series of cash flows. The first cash flow must be the (negative) initial outlay. The discount rate is an optional ar HelpFile="" Name="FameFncs" HelpContextID="0" Description="Functions for Financial Analysis with Microsoft Excel, 5th Ed." VersionCompatible32="393222000" CMG="767496227AEEF4F2F4F2F4F2F4F2" DPB="ECEE0CB8F42FF52FF52F" GC="62608236F937F93706" [Host Extender Info] &H00000001={3832D640-CF90-11CF-8E43-00A0C911005A};VBE;&H00000000 [Workspace] ThisWorkbook=0, 0, 0, 0, C Sheet1=0, 0, 0, 0, C FAME_Functions=225, 225, 1319, 858, Z fun՜.+,0 PDocumentSummaryInformation8w0CompObj|rOh+'0 PX $Functions for Financial AnalysisTimothy R. Mayes, Ph.D.Timothy R. Mayes, Ph.D.Microsoft Excel@H0t@ZDrG  #  [  '' ' [rU~} a >Functions for Financial Analysis with Microsoft Excel, 5th Ed.Cost MacrsClassYearTable/Calculates depreciation expense for Year using MACRS with the half-year convention. MacrsClass is 3, 5, 7, 10, 15 or 20.Table is optional, 0 for exact or 1 for table lookup. Default is 0. 14 Periodic_RateNPERYear*Calculates the Effective Annual Rate of a periodic rate. For example, if you know that a quarterly rate is 2%, this function will tell you that is 8.24% annualized.Div1ReqRet GrowthRate"Calculates the intrinsic value of a stock using the constant growth dividend discount model (also known as the Gordon Growth Model).Value_Calculates the variance of a random variable given the probabilities of each potential outcome.Values1Values2'Calculates the Cost of Equity, or Required Return, of a stock using the constant growth dividend discount model (also known as the Gordon Growth Model). RiskFreeRate MarketReturnBeta.Calculates the required return for a security or portfolio using the CAPM (Capital Asset Pricing Model) using the risk-free rate, the expected market return, and the security's beta. a DollarValues/Calculates the geometric mean rate of growth for a series of dollar values. The first cash flow in the list must be the most recent cash flow, and the last must be the oldest cash flow. CashFlowsRate;Calculates the payback period of a series of cash flows. The first cash flow must be the (negative) initial outlay. The discount rate is an optional argument. If it is provided, this function will return the discounted payback period.Values Probabilities,Calculates the covariance between two variables using the probabilities of occurrence for each value. Excel's Covar() function does not handle the probabilities of occurrence.0Calculates the correlation coefficient between two variables using the probabilities of occurrence for each value. Excel's Correl() function does not handle the probabilities of occurrence.iCalculates the standard deviation of a random variable given the probabilities of each potential outcome. VarCovMatPmt=Calculates the coefficient of variation using the probabillties of occurrence. Excel does not have a similar function. This is a measure of risk per unit of return, and is calculated by dividing the standard deviation by the expected value.cCalculates the Expected Value of a random variable using the probabilities of each potential value.Weights$Calculates the expected return for a portfolio of securities given the expected returns of each security and their weights in the portfolio.<Calculates the Variance of a portfolio of securities given a variance/covariance matrix and the weights of the individual securities. Note that you must supply a complete variance/covariance matrix, not just the upper or lower diagonal.CorrMatStdDevs<>Calculates the Variance of a portfolio of securities given a correlation matrix, and the standard deviations and weights of the individual securities. Note that you must supply a complete correlation matrix, not just the upper or lower diagonal.ReqRate GrowthRate1 GrowthRate2 G1Periods&Calculates the intrinsic value of a stock using the Two-Stage Dividend Discount Model. Note that G1Periods is the length of the first period of growth. TransPeriods?Calculates the intrinsic value of a stock using the Three-Stage Dividend Discount Model. Note that G1Periods is the length of the first period of growth, and TransPeriods is the length of the transition period between fast growth and constant growth. ReinvestRate/Calculates the Modified Internal Rate of Return for a series of cash flow' [' [-  -- @ !-- @ !-((- @ !(-==- @ !=-QQ- @ !Q-ee- @ !e-yy- @ !y-- @ !-- @ !-- @ !-- @ !-[- @ !A-- @ !-ZZ- @ !Z-- @ !-- @ !-- @ !-ZZ- @ !Z-  @ !- -- @ !-- @ !- -- @ !-- @ !- -- @ !-- @ !                  ---$   ----$   ----$   ----$    ----$   ----$   ----$   ----$   ----$  ----$   ----$   ----$   ---'' Calibri/ 0a'vw`ywkf- 'A> 2  1 2 * 2 2 ? 3 2 S 4 2 g 5 2 { 6 2 7 2 8 2 9 2 6A 2 wB 2 C 2 D 2 7E-"Systemw Sa'vw`ywkf- '- 'A>[-    @ !* Calibri0 ga'vw`ywkf-  2  MACRs Class  2 *-Year2 *g3-Year2 *5-Year2 *7-Year2 *#10-Year- 2 ?Q12 ?m33.33% 2 ?20.00% 2 ?14.29% 2 ?-10.00% 2 SQ22 Sm44.45% 2 S32.00% 2 S24.49% 2 S-18.00% 2 gQ32 gm14.81% 2 g19.20% 2 g17.49% 2 g-14.40% 2 {Q42 {t7.41%a 2 {11.52% 2 {12.49% 2 {-11.52% 2 Q52 11.52% 2 8.93%a 2 49.22%a 2 Q62 5.76%a 2 8.92%a 2 47.37%a 2 Q72 8.93%a 2 46.55%a - - '--  [-    -- @ !-ZZ- @ !Z-- @ !-- @ !-- @ !-ZZ- @ !Z->- @ !>->ZZ- @ !>Z->- @ !>->- @ !>->- @ !>->ZZ- @ !>Z-   @ !B-(Z(\- @ !(Z @ !B<-   -QQ\- @ !BQ-ee\- @ !Be-yy\- @ !By-\- @ !B-\- @ !B-\- @ !B-\- @ !B-- '- [[- '- [-   -[- @ ![-- @ !-'#A [(     Xp x Excel Add-in  MACRS Table MACRS_Table  Worksheets Named Ranges F&Microsoft Office Excel 2003 WorksheetBiff8Excel.Sheet.89q