does quantopian provide API to get risk free rate (e.g. 10 year treasury rate) in back-test and live trading?
I searched in forums, but don't see a clue, if not missing something. Thank you!
does quantopian provide API to get risk free rate (e.g. 10 year treasury rate) in back-test and live trading?
I searched in forums, but don't see a clue, if not missing something. Thank you!
Lake,
Try to use IEF as approximation.
10 year US treasury rate is not a risk free it's equity has Volatility 7% and Max Drawdown 10.1%
thanks, Vladimir. would you please give me a hint?
I think the Yield (ttm) is the rate close to risk free approximation. But I don't know how to get 'yield' from quantopian API (e.g. price history) . I guess prices are adjusted for dividend.
http://finance.yahoo.com/q?s=IEF&fr=uh3_finance_web_gs_ctrl1&uhb=uhb2
Lake,
There are a lot of sources for treasury yields
http://www.investing.com/rates-bonds/usa-government-bonds?maturity_from=10&maturity_to=290
https://www.quandl.com/data/USTREASURY/BILLRATES-Treasury-Bill-Rates
https://www.quandl.com/data/FRED/DGS10-10-Year-Treasury-Constant-Maturity-Rate
You can fetch csv from quandl to Q2 API.
other links
https://www.quantopian.com/posts/what-quantopian-use-as-approximation-of-risk-free-return-to-calculate-sharpe-ratio
https://www.quantopian.com/posts/how-does-quantopian-calculate-sharpe