Method: Charty::PlotMethods#bar_plot
- Defined in:
- lib/charty/plot_methods.rb
#bar_plot(x: nil, y: nil, color: nil, data: nil, order: nil, color_order: nil, estimator: :mean, ci: 95, n_boot: 1000, units: nil, random: nil, orient: nil, key_color: nil, palette: nil, saturation:, error_color: [0.26, 0.26, 0.26], error_width: nil, cap_size: nil, dodge: true, log: false, x_label: nil, y_label: nil, title: nil, **options, &block) ⇒ Object
Show the given data as rectangular bars.
30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 |
# File 'lib/charty/plot_methods.rb', line 30 def (x: nil, y: nil, color: nil, data: nil, order: nil, color_order: nil, estimator: :mean, ci: 95, n_boot: 1000, units: nil, random: nil, orient: nil, key_color: nil, palette: nil, saturation: 1r, error_color: [0.26, 0.26, 0.26], error_width: nil, cap_size: nil, dodge: true, log: false, x_label: nil, y_label: nil, title: nil, **, &block) Plotters::BarPlotter.new( data: data, variables: { x: x, y: y, color: color }, order: order, orient: orient, estimator: estimator, ci: ci, n_boot: n_boot, units: units, random: random, color_order: color_order, key_color: key_color, palette: palette, saturation: saturation, error_color: error_color, error_width: error_width, cap_size: cap_size, dodge: dodge, log: log, x_label: x_label, y_label: y_label, title: title, **, &block ) end |