4 Replies Latest reply on Sep 12, 2018 7:55 AM by Pedro Gallo

    How to divide the subsequent values from the first available value?

    Pedro Gallo

      Hi team,

      I need to divide the subsequent values from the first available value (Closed Value column) to obtain the daily return of stock values. The first value may change based on the date filter chosen in the dashboard

      Here is an example:

       

      First search from 1/2/2008 to 1/9/2008 of stock WXY, so Closed Value 100 is selected and the subsequent are divided by it. (101/100, 99/100, 98/100,95/100,92/100,97/100,87/100)

       

      DateClosed ValueDaily Return (Desired value)
      1/2/20081001
      1/3/20081011.01
      1/4/2008990.99
      1/5/2008980.98
      1/6/2008950.95
      1/7/2008920.92
      1/8/2008970.97
      1/9/2008870.87

       

      From the same database, the second search from 5/23/2009 to 5/26/2009 of stock WXY give the following data

       

      DateClosed ValueDaily Return (Desired value)
      5/23/20091201
      5/24/20091231.025
      5/25/20091251.0416
      5/26/20091321.1

       

      I appreciate the help