Multi series Bar Chart?

Mar 27, 2009 at 9:51 PM
Hi - first off, thanks for DD, it's a great library.

Now on to my question.  I have a need to build a bar chart and also needs to support multiple point collections.  Is there a straight forward way to extend DD to do this?

Thanks
Mar 28, 2009 at 12:58 AM
Hi,

I have a need to build a bar chart
     -> http://dynamicdatadisplay.codeplex.com/Thread/View.aspx?ThreadId=49088

and also needs to support multiple point collections
     -> You just need to use the AddLineGraph function of your plotter. See DataTableSample or MarkersSample.


Mar 28, 2009 at 2:28 AM
I've went down that path, creating a custom Marker.  Much like the CircleElementPointMarker but instead, one which draws a Rectangle.

This works well with a single series, but with multiple series the rectangles are basically overlayed on the Canvas.  Typically, a bar chart will have each marker adjacent to each other for comparison purposes.  Here's an image of a bar chart I had in mind: http://www.infocaptor.com/img/charts/bar_chart.png

Apologies, should have explained the multi series I'm looking to achieve better.  
Editor
Mar 31, 2009 at 9:30 AM
Edited Mar 31, 2009 at 9:31 AM
Hi!

Curently I cannot think up a way to get multi series bar chart looking as on the picture you've given.
Maybe it is possible to emulate this kind of chart by following steps:
  • unite yor data series into one series so that each data element has additional property indicating its initial data source (e.g. Series = 1, Series = 2,...)
  • Add a mapping to marker that will change marker's background according to initial data source of data element.
  • Also you have to modify position of each bar's marker according again to its initial data source number, arranging markers so that markers with equal position and different initial data source would be adjacent.
I know that this is not the best soultion :) but it is the best I advice I can give to you now)

I hope that'll help you, and our team will consider developing some special chart type for such cases.

Mikhail.
Mar 31, 2009 at 8:06 PM
Thanks for your response.  We will give the proposed solution a shot.

Another question, where can I modify the space between each tick mark?
Editor
Apr 1, 2009 at 9:49 AM
Space between what tick marks do you mean? A picture or additional explanation will help me to give an answer)

Yours,
Mikhail.
Apr 2, 2009 at 6:00 PM
I misread your response the first time, I think having a single data source eliminates my previous request.  Thanks
Apr 3, 2009 at 12:31 AM
Actually, how do I modify the number of visible points?

Basically I need to limit the number of visible points so that there's enough space (specifically width) for me to fit the adjacent bar charts.
Editor
Apr 6, 2009 at 9:23 AM
Hi!

LineGraph has built-in collection of filters, that a being applied to initial points, passed to chart. This collection is called Filters, and you can modify it contents - e.g., remove default filters, that are added in ChartPlotter.AddLineChart extension method. Or you can add to this collection an instance of you own filters - everything is in your hands) So you can create a filter class which wil limit somehow the number of points.

Mikhail.