BarGraph
An addon that draws (optionally stacked) bar graphs.
Supports automatic scaling, horizontal guidelines and a informative mouseover labels on the bars. The bars are drawn as plain divs.
Sample code
BarGraph graph = new BarGraph(); graph.setWidth("640px"); graph.setHeight("480px"); // Generate 20 random bars that have 2 datapoints each List<Datapoint> data = new ArrayList<Datapoint>(); for (int i = 0; i < 20; ++i) { Double[] points = new Double[2]; String[] labels = new String[2]; points[0] = new Random().nextDouble() * 10; labels[0] = "Bar " + i + " point 1 value is " + points[0]; points[1] = new Random().nextDouble() * 10; labels[1] = "Bar " + i + " point 2 value is " + points[1]; data.add(new Datapoint("Bar " + i, points, labels)); } graph.setData(data);
Links
Compatibility
Was this helpful? Need more help?
Leave a comment or a question below. You can also join
the chat on Discord or
ask questions on StackOverflow.
Version
- Fixed a Google App Engine compatability problem
- Fixed a problem with the empty constructor
- Added a build script
- Released
- 2010-05-02
- Maturity
- STABLE
- License
- Apache License 2.0
Compatibility
- Framework
- Vaadin 6.2+
- Vaadin 6.0+ in 1.0
- Browser
- Internet Explorer
- Internet Explorer
- Firefox
- Opera
- Safari
BarGraph - Vaadin Add-on Directory
An addon that draws (optionally stacked) bar graphs.Supports automatic scaling, horizontal guidelines and a informative mouseover labels on the bars. The bars are drawn as plain divs.
Live demoSources
Forum post with more info
BarGraph version 1.0.1
- Fixed a Google App Engine compatability problem
- Fixed a problem with the empty constructor
- Added a build script