• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

GWT Chart which displays bars on x axis at irregular intervals

 
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I need to create various charts (using GWT) which will display values along the x axis at irregular intervals.
All examples I have come across (and testing I have done) display the values along the x axis at regular intervals.
However for my purposes I need to display a set of values (Y axis) taken at specific times/java.util.Date (X axis).
The range of the x axis can be varied from 1 month to n months and the labels must show the Months. The values however must be displayed at the appropriate place on the x axis (see screen shots).

Does anyone have any idea how to achieve this using the GWT charts?
1-mnth.png
[Thumbnail for 1-mnth.png]
Range of 1 month
6-mnths.png
[Thumbnail for 6-mnths.png]
Range of 6 months
12-months.png
[Thumbnail for 12-months.png]
Range of 12 months
 
Bartender
Posts: 11497
19
Android Google Web Toolkit Mac Eclipse IDE Ubuntu Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Welcome to the Ranch.

In the past I have used the Visualization API to generate charts and graphs for my GWT apps.
A sampler of what all is possible can be found here
 
Louise Moritmer
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thank you for the quick reply Maneesh.

I have looked at the Visualization API but i believe the same problem exists.

I realise I may not have made the actual problem clear in the initial post but it is this:
in the examples I have seen, when drawing a simple column grid (for example), the bars are drawn from the x grid at REGULAR intervals for each entry supplied (Jan, Feb, March) (Java, C++, Prolog)

However, I need to display an x grid which, while marking the intervals along the x axis as months (Jan, Feb, etc), will display the Bars themselves at points along the x axis which reflect the actual java.util.Date when the value was measured.

So there may be no Bars during Jan and yet 20 Bars in May!

Does the Visualisation API allow this? I didn't see it.
Can you point me to some example code?

Many thanks
 
How do they get the deer to cross at the signs? Or to read this tiny ad?
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic