3 Replies Latest reply on Jun 1, 2012 2:57 AM by Jonathan Drummey

    Filter using slope

    Sarah Kline

      I have done some searching and cannot seem to find this information.  Perhaps it's not possible, but I've yet to come across something I want to do that Tableau isn't capable of doing!

       

      I have a chart showing a running sum (over 5 years) for a fairly large number of people... so it's a jumbled mess.  I would like to "clean it up" by filtering it to those where the slope of the line is greater than x. (I'm looking for sharply increasing lines)  I'm assuming I would use a "top" filter based on a formula, but I haven't quite figured out what the formula would look like. 

       

      Is this even possible? Or is there a better way to get at what I'm trying to see?

        • 1. Re: Filter using slope
          Tracy Rodgers

          Hi Sarah,

           

          Can you not use the top filter and filter by field (by whatever x is)? Would you be able to post a workbook (twbx) file?

           

          -Tracy

          • 2. Re: Filter using slope
            Sarah Kline

            I will pull together a workbook w/the identifying info stripped out.

             

            I'm looking at giving over time (by year) using a running sum.  I'm not so much interested in seeing the highest total giving as I am in seeing which prospects (aka customers) are increasing their giving at the fastest rates.  So filtering by highest giving totals doesn't quite get me there.

             

            I can do this visually by looking at each individual line and excluding those that aren't sharply climbing, but with about 200 lines that's not particularly efficient (and if the person I'm working with likes this, there are 10+ other folks likely interested in similar information, so doing it by hand may not be an option!)

             

            Thanks!

            Sarah

             

            I just added the file.  What I'm trying to see are lines that are increasing at a rate similar to 10578035, for example. My thinking was that slope would get me there, but I'm certainly very open to other ideas and suggestions. Thanks!

             

            Message was edited by: Sarah Kline

            • 3. Re: Filter using slope
              Jonathan Drummey

              Hi Sarah,

               

              How about something like the attached? What I did was took your running sum calculation and turned that into a calculated field - RS BU Giving. Then I created a field called RS BU Giving % Diff from Prior to get the % change from the prior, and finally a third field to average the % change's for each ID called Avg BU Giving % Diff from Prior that uses the WINDOW_AVG table calculation. I made that last calc use a window based on a user-controlled parameter for the # of periods to review, that way you can choose whether you want the slope to be based on the last 2, 3, 4, etc. years of giving.

               

              I the parameter in the view and that third calc on the Filter Shelf, so you can drag sliders to choose how many periods and what % of Giving.

               

              Let me know if this works for you,

               

              Jonathan