views:

2839

answers:

3

Hello, I am developing an SSRS 2008 report which contains a number of simple charts. On the x axis I have the 12 months of this year - Jan 2009 thru December 2009. On the Y is an integer value ranging from 0 to 100 in increments of 10. I am plotting the number of times an issue occurred per month. So January could have a value of 10, February 30, etc. etc.

I would like to have a horizontal line/series that is constant and shows the yearly average for 2008. So, say the average was 30 issues per month in 2008, I would like for that line to be shown in my chart. Basically, I want to draw a straight line across the chart for that value... I can see how to add more complex series, but this seemingly simple task is getting the better of me.

Doe anyone have any idea how this could be accomplished? Thanks in advance, Jason

[Update] To add some further details, I am already pulling the average for each row in my dataset and have it set up as its own series. However, rather than plotting a line, this approach plots individual points for each month. While this is close to what I want, I need to join the dots so to speak. The chart is of the Error Bar (Range) variety.

+2  A: 

Add the yearly average to each row in the underlying the query. Add data series on just that value.

Andomar
Also has the added benefit that when this year becomes last year, and the yearly average has changed, it'll be easier to plumb in
Rowland Shaw
+2  A: 

Can you use a column / line hybrid chart? If so then add a constant or dynamic target value to the chart:

Design the chart. On the Data tab in the Chart Properties dialog box, add a new data value (for example, Target). Set the target value (see the example in Figure 9 on link this uses a constant target value of 100000 across all categories but you can do it dynamically too). Make sure to use an expression starting with = (equals). Otherwise, the value is not interpreted as a numeric value.

See the example on the MS charts page at http://msdn.microsoft.com/en-us/library/aa964128.aspx

u07ch
Follow the link. Approx. half way down tells you how to do what you want. Look for section "Column and Line Hybrid Charts"
dr
This won't work for me. I cannot find a way to incorporate the Error Bar in a column / line hybrid chart.
Jason Irwin
Im not sure what type of chart you are using (though am assuming stock ?) and am away from my office so cant test this. SSRS 2008 added TrendLine functionality (sorely missed in 2000/5,) Can you add a trendline to your existing points if you click on the average data set go to appearance and select plot as line ? If its not their can you confirm what report type you are using and i will look in the morning.
u07ch
A: 

I managed to solve this issue myself.

As I mentioned, I was using an Error Bar graph. Right-clicking on the series of interest, I was able to change the graph type for that particular series - essentially leaving me with a chart with multiple graphs in it...particularly simple if you know where to look - which i did not! Thanks everyone for your suggestions.

Jason Irwin