Community Spring Cleaning week is here! Join your fellow Maveryx in digging through your old posts and marking comments on them as solved. Learn more here!

Alteryx Designer Desktop Discussions

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

Calculating Column Variance dynamically

JasonHerden
6 - Meteoroid

Hi -

 

I have the following output, and I want to have a variance column at the end that always calculates the further right column vs the column to the left of it.  I tried a couple things and cant seem to get anything to work properly.  Any thoughts on this. 

 

JasonHerden_0-1616089709209.png

 

1 REPLY 1
AngelosPachis
16 - Nebula

Hi @JasonHerden ,

 

Not sure if you want to use a particular variance formula for variance estimation (in another thread, variance was referred to as the percentage difference between two values) but the summarize tool allows you to calculate the variance (Standard Deviation squared)

 

AngelosPachis_0-1616101639766.png

 

This is the workflow that estimates the variance dynamically between the two most recent dates

 

AngelosPachis_1-1616101723630.png

 

What the workflow does is transposing all columns that have a date in their header and then replaces the "_" with "-" so the names are in a date format.

 

Then it sorts them and only keeps the two columns with the most recent dates. After the join tool, you can stick a summarize tool to estimate the variance for each order/Bill cycle.

 

Hope that helps, let me know if you have any questions on the workflow.

 

Cheers,

 

Angelos

Labels