2 Replies Latest reply on Sep 18, 2012 7:31 AM by Mark Holtz

    Create a positive sloping reference line?

    James Eichinger

      Okay. This is one of those questions I'm anticipating an easy answer to, where I'm embarrassed that I had to ask the community. However, I have looked and looked and I can't find a solution.

       

      I want to create a positive sloping reference line which tracks a cumulative goal. Is there a simple way to have this calculated or do I need to actually enter the monthly goal into my dataset. I'd be surprised if that were the case.

      My intent is to create something like this (The Green Line):

      Qual Pros Graph.bmp

      Any ideas?

        • 2. Re: Create a positive sloping reference line?
          Mark Holtz

          I'm not sure if you're after a trend line as opposed to just a function with a constant. (think y=mx+b from algebra class)

           

          If you are definitely using dates (days or months) on your X axis, you might try making a calculated field as a function of number of days since a base point in time. I haven't really flushed this out, but hopefully you get my drift.

           

          So if the goal "increases" from a starting point of 9/1/2012 by 75 each month:

          DATEDIFF('month',#9/1/2012#,[DateField]) * 75 + 6800

           

          You should be able to display the MAX or AVG of this calculated field as a Line measure and each time-point's value will be a bit higher than the previous time-point.

           

          a few more options:

          Switch from 'month' to 'day' if you want to increment the goal daily

          Replace #9/1/2012# with a parameter to allow the user to dynamically set the "start point"

          Replace 75 with a parameter to allow the user to dynamically set the "delta" coefficient factor of this function

          Replace 6800 with a parameter to set the "goal at the base point in time" to which you add as time passes

           

          Hope that makes sense/is helpful