Documentation
¶
Overview ¶
Package grapher provides a tool for easily creating graphs.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type GraphType ¶
type GraphType int
GraphType is used to define the type of graph you need.
const ( // Normal GraphType provides a grapher where you can set points a certain dates. Normal GraphType = iota // Cumulative GraphType will accumulate all previous values on your graph. Cumulative GraphType = iota // CumulativeSameDate GraphType will accumulate values // with the same date on your graph. CumulativeSameDate GraphType = iota )
type Grapher ¶
type Grapher[T Numeric] struct { // contains filtered or unexported fields }
Grapher is used to easily create graphs.
func New ¶
func New[T Numeric]( graphType GraphType, interpolationType InterpolationType, dateFormat string, dateGranularity time.Duration, ) *Grapher[T]
New returns a new Grapher.
type InterpolationType ¶ added in v0.3.4
type InterpolationType int
InterpolationType is used to define the type of interpolation you need.
const ( // None InterpolationType provides a grapher that won't interpolate. None InterpolationType = iota // Zero InterpolationType provides a grapher that will interpolate using value zero. Zero InterpolationType = iota // PreviousValue InterpolationType provides a grapher // that will interpolate using the previous value. PreviousValue InterpolationType = iota )
Click to show internal directories.
Click to hide internal directories.