Page 1 of 1

How to put Labels to xy-values

Posted: Mon Sep 16, 2013 1:52 am
by JosepM
Hi,

I would like to know how can I label x and y data. I mean for example put an string or any other value non numeric nor datetime.

Data sample.

10/8 2 3
09/8 1 2
08/8 5 9
07/8 2 3
06/8 8 6

Sun 2 3
Mon 1 2
Thu 5 9
Wed 2 3
Sat 8 6

First col is the day/month, second col is customers and the last one the orders.
If I try to show it the graphics collapse one between others and the graph is unreadable.

Other issue is how can I put a sublabel under the x-axis like "Orders per day and customer"?

Thanks in advance,
Josep M

Re: How to put Labels to xy-values

Posted: Tue Sep 17, 2013 7:15 pm
by JosepM
Hi,

Any help about this? :)

Salut,
Josep M

Re: How to put Labels to xy-values

Posted: Tue Sep 17, 2013 7:43 pm
by FourthWorld
Writing a charting library is a bit of work - doable, but tedious. I could point you to the "location" property in the Dictionary, and suggest groups, etc., but really for something this tedious I'm happy to let someone else's good work do the heavy lifting for me, like Hugh Senior's ChartMaker.

Re: How to put Labels to xy-values

Posted: Tue Sep 17, 2013 7:45 pm
by JosepM
:) I go to download the demo... thanks!

Salut,
Josep M

Re: How to put Labels to xy-values

Posted: Wed Sep 18, 2013 9:54 am
by BvG
JosepM wrote:I would like to know how can I label x and y data. I mean for example put an string or any other value non numeric nor datetime.
...
If I try to show it the graphics collapse one between others and the graph is unreadable.

Other issue is how can I put a sublabel under the x-axis like "Orders per day and customer"?
Hi Josep

ChartsEngine is not mainly made for flexible labeling. So 'sublables under the x-axis'; you'd have to do that yourself (for example create a field that you position below the charts group).

As for the other question about collapsing graph, you can only enter numerical data into charts["data"]. So for the day/month, you'd need a date in seconds, and then use the charts["XconvertsTo"], for showing it as a readable date.

Please make sure to read the relevant entries in the documentation.

Re: How to put Labels to xy-values

Posted: Wed Sep 18, 2013 10:04 am
by JosepM
Hi BvG,

Thanks for answer. So show any label on X/Y like "Team A,Team B, Team C" isn't possible, isn't?

Salut,
Josep M

Re: How to put Labels to xy-values

Posted: Wed Sep 18, 2013 10:18 am
by BvG
Yes that is correct.

Re: How to put Labels to xy-values

Posted: Wed Sep 18, 2013 7:12 pm
by FLCo
As Richard has mentioned ChartMaker, it supports both x-axis sub-labeling and y-axis sub-labeling, such as "Orders per day and customer" and "Number of orders". The y-axis label can be horizontal or rotated.

Data labeling is automatic, taken from the specified Categories and Values you supply.

To collapse a graph, simply update the chart with a replacement set of values using CMupdateChart. It's built in.


Hope this helps.

Hugh Senior

Re: How to put Labels to xy-values

Posted: Wed Sep 18, 2013 8:04 pm
by FourthWorld
BvG and the others here: Please accept my apologies for my misplaced post. While it seems the outcome wasn't bad in terms of finding a solution for a need that ChartsEngine doesn't currently address, it wasn't until now that I realized this discussion is in the forum section dedicated to ChartsEngine.

When I log into the forums I hit the "New Posts" link and click those that look like I may be able to help with. I rarely take the time to note all the other details for each new post beyond the thread title, but it's clear now that I should take more care to note the section the post is in. I'll try to do a better job of that going forward.

Since Hugh's post was in response to mine, I take full responsibility for both posts being off-topic here.

Sorry for the off-topic posts.

Re: How to put Labels to xy-values

Posted: Thu Sep 19, 2013 7:32 pm
by BvG
All's fine don't sweat it ;-)

We solved the problems by direct emails in the end.