Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.

Compute Daily Stock Returns Help Needed

Phuonglin98
5 - Atom

Hi I am trying to compute the daily stock returns with the formula: 

  1. Compute daily stock returns using the following formula: Ln( Pricet / Price t-1  ) where:
    1. Ln = natural log
    2. Pricet = Price on day t
    3. Price t-1 = Price on day t-1
  2. I'm trying to find the solution for my work flow. I'm not sure someone already touched this topic as I can't find any previous solutions for this so I'm seeking for your expertise. Here are the example of my data. Thank you so much in advance
  3. Screen Shot 2023-05-30 at 11.13.25 AM.png
1 REPLY 1
danilang
19 - Altair
19 - Altair

Hi @Phuonglin98 

 

Use a Multi-row Formula tool with Log([Price] / [Row-1:Price]) 

 

Note the LOG returns the Natural Logarithm in Alteryx.  LOG10 returns the Base10 log 

 

Dan

Labels