03-14-2023 07:56 AM
Could please let me know how to convert above "STDEV.P" excel function in Incorta.
03-14-2023 10:38 AM
Unfortunately, no we do not have a built in function for this. We have many of the functions that in aggregate support the calculation such as ABS(), AVERAGE() and SQRT(). In a multi pass process it would look something like:
However, the easier way to do this is by using an python MV and using a python dataframe function to calculate the STDEV from the elements in the dataframe. Pandas supports something like
03-14-2023 11:05 AM
03-16-2023 09:25 AM
Adding on to Jeffs approach, if you happen to be more SQL oriented you can alternatively use SparkSQL or Postgres SQL 'STDDEV' Function within a Materialized View.
Similarly, if we want to show the standard deviation grouped by product in the same scenario here is a simple example.
With Group By: