Class: Charty::Plotters::CategoricalPlotter

Inherits:
AbstractPlotter show all
Defined in:
lib/charty/plotters/categorical_plotter.rb

Direct Known Subclasses

BarPlotter, BoxPlotter

Instance Attribute Summary collapse

Attributes inherited from AbstractPlotter

#color, #data, #palette, #x, #y

Instance Method Summary collapse

Methods inherited from AbstractPlotter

#to_iruby

Constructor Details

#initialize(x, y, color, **options, &block) ⇒ CategoricalPlotter

Returns a new instance of CategoricalPlotter.



4
5
6
7
8
9
# File 'lib/charty/plotters/categorical_plotter.rb', line 4

def initialize(x, y, color, **options, &block)
  super

  setup_variables
  setup_colors
end

Instance Attribute Details

#group_labelObject (readonly)

Returns the value of attribute group_label.



26
27
28
# File 'lib/charty/plotters/categorical_plotter.rb', line 26

def group_label
  @group_label
end

#group_namesObject (readonly)

Returns the value of attribute group_names.



26
27
28
# File 'lib/charty/plotters/categorical_plotter.rb', line 26

def group_names
  @group_names
end

#orderObject

Returns the value of attribute order.



11
12
13
# File 'lib/charty/plotters/categorical_plotter.rb', line 11

def order
  @order
end

#plot_dataObject (readonly)

Returns the value of attribute plot_data.



26
27
28
# File 'lib/charty/plotters/categorical_plotter.rb', line 26

def plot_data
  @plot_data
end

#value_labelObject (readonly)

Returns the value of attribute value_label.



26
27
28
# File 'lib/charty/plotters/categorical_plotter.rb', line 26

def value_label
  @value_label
end