Python Forum
Calculate column with cumulative return
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Calculate column with cumulative return
#1
Hello,

I have a very basic question and would appreciate any help.

I have a column with percentage changes on a daily basis for the last 100 days. Now I'd like to calculate a new column that shows the cumulative return for each day, i.e. for day 3 it would be: % change day 1* % change day 2 * % change day 3.

In Excel this task would be very simple, but in Python I have no idea how to solve this.

I'd be happy if someone could please help me.

Many thanks,

Tim
Reply


Messages In This Thread
Calculate column with cumulative return - by tgottsc1 - Jan-25-2021, 11:50 AM

Possibly Related Threads…
Thread Author Replies Views Last Post
  How do I calculate a ratio from 2 numbers and return an equivalent list of about 1000 Pleiades 8 15,775 Jan-05-2024, 08:30 PM
Last Post: sgrey
  calculate daily return in percent in forex as to some strategy? alen 1 2,233 Mar-12-2021, 10:03 AM
Last Post: buran
  How to calculate column mean and row skip non numeric and na Mekala 5 4,988 May-06-2020, 10:52 AM
Last Post: anbu23
  How to calculate unique rows column sum and percentage SriRajesh 4 3,491 Feb-12-2020, 02:21 PM
Last Post: SriRajesh
  How to calculate variance(standard deviation) by column SriRajesh 2 2,857 Dec-27-2018, 12:35 PM
Last Post: SriRajesh
  Need help for finding cumulative values in a loop Lightning1800 10 6,199 May-23-2018, 07:48 PM
Last Post: Lightning1800

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020