Sha256: cabb9fa1490fe31d6b8eda7d34533536271aead4976cf763c4288340d2e0fe91
Contents?: true
Size: 570 Bytes
Versions: 108
Compression:
Stored size: 570 Bytes
Contents
- title ||= nil - id ||= title || ("hist-" << (1000 * rand).to_i.to_s) - title ||= "Histogram" - data_values = values2d3(values) - plot_data = [{:key => title, :values => data_values}] :ruby setup =<<-EOF var graph = nv.models.discreteBarChart() .x(function(d) { return d.label }) .y(function(d) { return d.value }) .staggerLabels(true) .showValues(true) graph.tooltip.enabled(true) EOF = partial_render('tools/nvd3/chart', locals.merge(:plot_data => plot_data, :id => id, :resolution => resolution, :setup => setup))
Version data entries
108 entries across 108 versions & 1 rubygems