I want to visualize some data about cars in a table via Prefuse Java. Three kinds of important data objects are used:
- PIT (Point in Time)
- Value (contains the consumption of gas as a Double)
- Car (the class that represents a Car)
So first I put them into a table like this:
car1 | pit1 | value11
car1 | pit2 | value12
car1 | pit3 | value13
car2 | pit1 | value21
car2 | pit2 | value22
car2 | pit3 | value23
car3 | pit1 | value31
car3 | pit2 | value32
car3 | pit3 | value33
Using the examples in the Prefuse project I was able to create a visualization of a table with the x-axis labeled with pit1, pit2 and pit3 and the y-axis with the different values in correct order.
But what I've tried for hours is to somehow draw little squares at the corresponding spots (like a red square for car1 where pit1 and value11 "meet").
How do I do this?
PS: I also would like to know how to improve the y-axis in the following way:
Imagine the lowest value is 2.6 and the highest is 32.0. Right now the y-axis would start with 2.6 and just label every value (with the same space between the labels regardless of the actual difference) up to 32.0. What I would prefer is that the labels would start with 0.0 (or 2.0) and then use steps of 5 or so till 35.