MCPcopy Index your code
hub / github.com/gonum/plot / Color

Function Color

plotutil/plotutil.go:47–53  ·  view source on GitHub ↗

Color returns the ith default color, wrapping if i is less than zero or greater than the max number of colors in the DefaultColors slice.

(i int)

Source from the content-addressed store, hash-verified

45// if i is less than zero or greater than the max
46// number of colors in the DefaultColors slice.
47func Color(i int) color.Color {
48 n := len(DefaultColors)
49 if i < 0 {
50 return DefaultColors[i%n+n]
51 }
52 return DefaultColors[i%n]
53}
54
55// DefaultGlyphShapes is a set of GlyphDrawers used by
56// the Shape function.

Callers 7

AddStackedAreaPlotsFunction · 0.70
AddScattersFunction · 0.70
AddLinesFunction · 0.70
AddLinePointsFunction · 0.70
AddErrorBarsFunction · 0.70
AddXErrorBarsFunction · 0.70
AddYErrorBarsFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected