Skip to content


Calculating CAPM with F#

The Capital Asset Pricing Model (CAPM) is a way to determine the rate of return for an asset, a single stock or the entire portfolio.

I wanted to see how this would be calculated in F#, so here you go, enjoy:


let capm (beta:float) (y:float) (z:float) = y + (beta * (z - y));;

Posted in F#, Finance.


0 Responses

Stay in touch with the conversation, subscribe to the RSS feed for comments on this post.



Some HTML is OK

or, reply to this post via trackback.