7 Replies Latest reply on Jan 18, 2017 3:10 PM by Alan Eldridge

    Creating Dynamic Ellipses

    Tony Covey

      The data I'm working with come from a launch monitor used to track a golf ball. I'm trying to replicate the dispersion ellipses we get from the launch monitor, while having it be possible to dynamically redraw the ellipses based on a set of filters.

       

      For example, the user may want to show the dispersion plot with 1 or more golfers removed from the dataset.

      The user may want to show the dispersion plot with 1 or more golfers removed from the dataset.

      The user may want to see dispersion with shots more than 30 yards offline eliminated.

      There are countless other scenarios that we might want to filter based on user selections.

       

      I've followed the instructions for creating ellipses within Tableau (Plotting Ellipses | Tableau Software). As long as I pre-calculate the necessary parameters (X Center, Y Center, and my two coefficient values) everything works fine. What I'd like to do is calculate those values on the fly. Unfortunately, what I've tried thus far results in the "Cannot mix aggregate and non-aggregate arguments" error.

       

      As an example, in my particular case, the formula that would otherwise work to create what the doc calls the X Parameter is:

       

      AVG([Offline])+STDEVP([Offline])*COS([T]/100*PI())

       

      This issue is mixing the aggregate functions (AVG and STDEVP) with the non-aggregate COS and PI functions.

       

      I don't see a way to accomplish what I need to accomplish without calculating the average and the standard deviation (my coefficient), and I haven't been able to come up with an aggregation function to pair with cosign that actually works (draws the ellipses properly).


      Does anyone have a workaround?

       

      Thanks,

      TC