class Axlsx::BubbleChart
The BubbleChart
allows you to insert a bubble chart into your worksheet @see Worksheet#add_chart
@see Chart#add_series
@see README for an example
Public Class Methods
new(frame, options={})
click to toggle source
Creates a new bubble chart
Calls superclass method
# File lib/axlsx/drawing/bubble_chart.rb, line 27 def initialize(frame, options={}) @vary_colors = 0 super(frame, options) @series_type = BubbleSeries @d_lbls = nil parse_options options end
Public Instance Methods
axes()
click to toggle source
The axes for the bubble chart. BubbleChart
has an x_val_axis
and a y_val_axis
@return [Axes]
# File lib/axlsx/drawing/bubble_chart.rb, line 55 def axes @axes ||= Axes.new(:x_val_axis => ValAxis, :y_val_axis => ValAxis) end
to_xml_string(str = '')
click to toggle source
Serializes the object @param [String] str @return [String]
Calls superclass method
# File lib/axlsx/drawing/bubble_chart.rb, line 39 def to_xml_string(str = '') super(str) do str << '<c:bubbleChart>' str << ('<c:varyColors val="' << vary_colors.to_s << '"/>') @series.each { |ser| ser.to_xml_string(str) } d_lbls.to_xml_string(str) if @d_lbls axes.to_xml_string(str, :ids => true) str << '</c:bubbleChart>' axes.to_xml_string(str) end str end
x_val_axis()
click to toggle source
the x value axis @return [ValAxis]
# File lib/axlsx/drawing/bubble_chart.rb, line 14 def x_val_axis axes[:x_val_axis] end
Also aliased as: xValAxis
y_val_axis()
click to toggle source
the y value axis @return [ValAxis]
# File lib/axlsx/drawing/bubble_chart.rb, line 21 def y_val_axis axes[:y_val_axis] end
Also aliased as: yValAxis