Skip to Main Content
Spotfire Ideas Portal
Status Future Consideration
Product Spotfire
Categories Custom Expressions
Created by Guest
Created on Aug 22, 2023

Add an aggregation method to find the Nth most common value

MostCommon is a pretty useful aggregation method, for example when you have a large set of defective parts across different products and these are defective for different reasons and you want to see the most prominent error say per product. Very easy: MostCommon([Error]) OVER ([Product]).

But if you have a large set if parts (including the non-defective ones and for some reason you don't want to exclude them) with a reasonable yield > 50%, the result of such an expression might be "None" if that is the value in [Error] for non-defective parts.
Or if you already know your biggest yield detractor (e.g. [Error]="human processing error") and you would like to chase the 2nd biggest one.

Long story short: it would be great to be able to specify the n in NthMostCommon to get the most common (N=1), the 2nd most common (N=2) etc.

  • Attach files
  • Admin
    Niklas Amberntsson
    Aug 22, 2023

    Hi Mark, thanks for for contributing this idea. Would it make sense to name the Idea "Add an aggregation method to find the Nth most common value" ? I can change this if you agree.

    1 reply