cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Choose Language Hide Translation Bar
0 Kudos

Dif() and Lag() formula functions by column group (byVar argument)

Row functions are essential in manufacturing data. 

  • We use Dif() to calculate the rate of change (slopes, or derivatives), which can be correlated to our target of interest.
  • Lag() is also used to align data (upstream and downstream equipment)

 

However, when having tables with a column indicating different groups, new users are out of luck.

 

Two consecutive rows can belong to different groups and the only way to guarantee this is by adding complex formulas with conditionals (example).

 

It will be much easier for the user to include a <byVar> argument in Dif() and Lag().

 

For example, Col Cumulative Sum() is another row function that does allow this!

 

Here, I am creating a simple counter where I don't need to be worried about conditionals.

FN_0-1680879298556.png