Created
April 28, 2011 00:20
-
-
Save mjansen401/945540 to your computer and use it in GitHub Desktop.
Google Chart Bar
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<% chart = Gchart.bar( | |
# see http://code.google.com/apis/chart/docs/gallery/bar_charts.html for Google Charts API bar chart info | |
# | |
:grouped => 'true', | |
:bar_colors => "D6A061,331F08", | |
:bar_width_and_spacing => 'a,5,30', # bar width, spacing width, group spacing width | |
:size => '700x400', | |
:title => "Expected vs Actual Velocity", | |
:bg => 'FFFFFF00', # transparent | |
:legend => ['Expected', 'Actual'], | |
:data => [@report.collect_iteration(:expected), @report.collect_iteration(:actual)], | |
:axis_with_labels => "x,y", | |
:axis_labels => [@report.collect_dates], | |
:axis_range => [nil, [0, @report.max_value, 5]]) %> | |
<%= image_tag(chart) %> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment