Class Gruff::Line
In: lib/gruff/line.rb
Parent: Gruff::Base

Methods

draw   new   normalize  

Attributes

baseline_color  [RW]  Color of the baseline
baseline_value  [RW]  Draw a dashed line at the given value
hide_dots  [RW]  Hide parts of the graph to fit more datapoints, or for a different appearance.
hide_lines  [RW]  Hide parts of the graph to fit more datapoints, or for a different appearance.

Public Class methods

Call with target pixel width of graph (800, 400, 300), and/or ‘false’ to omit lines (points only).

 g = Gruff::Line.new(400) # 400px wide with lines

 g = Gruff::Line.new(400, false) # 400px wide, no lines (for backwards compatibility)

 g = Gruff::Line.new(false) # Defaults to 800px wide, no lines (for backwards compatibility)

The preferred way is to call hide_dots or hide_lines instead.

Public Instance methods

[Validate]