Newbie - Reading in data basics [message #1614541] |
Fri, 13 February 2015 10:05 |
Jim Seconde Messages: 19 Registered: February 2015 |
Junior Member |
|
|
Hi all, first post so I'll try and explain things as clearly as possible. These are likely to be very simple problems that I've encountered (I hope!)
I'm trying to output a line chart with data like the following:
Month Value
01/01/2014 154484
01/02/2014 165878
01/03/2014 897987
01/04/2014 456434
Data connection is an Excel spreadsheet.
The problem I'm having is with formatting the value in the dataset -
The chart will read the data in, no problem. But, I need the numerical value to be formatted as 0.0,
So, the chart reads in the data (and changes it's axis scale accordingly) like so:
Month Value
01/01/2014 154.5
01/02/2014 165.9
01/03/2014 898.0
01/04/2014 456.4
I've tried multiple ways to get this in, none have worked.
My first question is, shall I change the bindings in the dataset itself to read in as an Integer or a Decimal/Float? It's technically a number changing from one to the other. Or do I read in as Integer at dataset level and change the bindings in the chart to Decimal/Float as part of the formatting?
The second question is, when I changed the data so as to force in the decimal values, Eclipse still wouldn't read the values in as Decimals: The data binding was the same in the dataset and the chart bindings. Any pointers as to why it wouldn't read in decimals at all? (Probably more info required to answer this I expect)
What I'd like ideally is it reads in the original number and formats it accordingly on the fly through either the dataset or the chart. I've tried using Formatter.format in the Axis of the chart itself and at binding levels of the chart and dataset and there's no change in the graph.
Thanks in advance to anyone that can help or respond!
|
|
|
|
|
|
|
Re: Newbie - Reading in data basics [message #1622789 is a reply to message #1622410] |
Wed, 18 February 2015 18:57 |
|
Sorry, questions with multiple responses typically get skipped over by most that are looking for posts to respond to. At a glance, it looks like someone is already helping you.
So, you have a 6 digit integer that you want to read in and move the decimal over 3 places and round those three to the nearest 10th?
Or are you just trying to represent the 6 figure number with ###.#k?
Close to the same issue, I guess, but I'm just wondering. Let me know if I'm misunderstanding something.
Michael
Developer Evangelist, Silanis
|
|
|
|
|
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.03892 seconds