Python Forum

Full Version: Annualised returns in python. Urgent request
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
hi,
I have a data from 1930 of stock returns monthly. I have calculated annualized return for the whole date as annualized_ret. Now I want the annualized return from 2000- 2019. Can some body help with the code.

I am a beginner
What have you tried and where are you stuck? We're not going to do the work for you.
annualised_ret = (return_per_month+1)**12 - 1
annualised_ret

I tried this. annualized_ret[2000:2019].
but not working
I have also changed the index to date time.