Chart. How to control frequency of X-Axis marks?

Mar 18, 2010 at 5:28 PM

I badly need to set one of my charts X-Axis marks frequency.. It tries to display every data point and even with Font=6 and stretch across 3 monitors doesnt let me read the lables!

Mar 22, 2010 at 2:47 PM

If I understand you correctly you want to hide some of your datapoints?

Like every second datapoint... of course depending on your available space and amount of datapoints.

Sadly I don't think there's a feature build in the chartingtoolkit so you would have to write your own Style that does that...

 

Mar 22, 2010 at 3:00 PM
No I need to hide some of the marks (by marks I mean vertical lines with label on the end which tells the X value of data point). In Y-Axis you can set Interval property I believe to control this. In X-Axis I havent found anything....
Mar 22, 2010 at 3:42 PM

I guess your X-Axis is a category axis?

Hiding the label is basically the same deal, you need somehow to decide which datapoints (I mean the labels of which datapoints) to hide, make a property for that in your ViewModel and make a Style for the AxisLabel control Binding to that...

The mark itself is a bit more complicated, there is the MajorTickMarkStyle-Property on your Axis but it is the same for every label... I'm not quite sure how I would approach that.
But maybe it's okay to leave the marks itself.

I've evaluated the usability another diagram which hid many of the label + marks and often the users tended to think that there's not more data available, so it should made be visible somehow that there's more data.

Mar 22, 2010 at 3:52 PM

yes it is category axis... Ernii as long as you are in this business I really would recommend to look at existing graphing software. like Matlab or simpler like SierraCharts.com etc... Not diagramms.. the end-users are not programmers, they dont care about diagramms. they want something and this is already a common knowledge what they want.

All things are already solved. No need to reinvent the wheel. get yourself a demo and play for half an hour.

If you dont comply users will trun to another product very quick.

Re: marks - axis must scale itself to accomodate marks in a fashion that all marks are readable. for that an axis must reduce number of marks as much as it takes. there is no other solution in the whole wide world.

HTH