Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( VeryLowRisk uint = 10 LowRisk uint = 15 MediumRisk uint = 20 HighRisk uint = 25 VeryHighRisk uint = 30 CriticalRisk uint = 35 )
View Source
var HeightPx = 800
If choose picture height in px
View Source
var ScatterSymbolSize = 8
View Source
var WidthPx = 1200
If choose picture width in px
View Source
var WithLegend = true
If need to show legend in chart
View Source
var WithRisks = false
If need to devide risks into categories
View Source
var WithScroll = false
If need to show scroll in chart
View Source
var WithTooltip = true
If need to show tooltip in chart
Functions ¶
func CreateScatterChart ¶
func CreateScatterChart(entries []ScatterEntry, mapper EntryMapper, outputPath string) error
TODO: pass EntryMapper as parameter!
func ValidateRiskThresholds ¶
func ValidateRiskThresholds() error
Need to make it more general TODO refactor
Types ¶
type EntryMapper ¶
type EntryMapper interface {
Map(ScatterData) Category
Style(Category) opts.ItemStyle
}
TODO: Maybe categorizer?
type NoopMapper ¶
type NoopMapper struct{}
func (*NoopMapper) Map ¶
func (rm *NoopMapper) Map(data ScatterData) Category
type RisksMapper ¶
type RisksMapper struct {
// contains filtered or unexported fields
}
func NewRisksMapper ¶
func NewRisksMapper() *RisksMapper
func (*RisksMapper) Map ¶
func (rm *RisksMapper) Map(data ScatterData) Category
type ScatterData ¶
type ScatterEntry ¶
type ScatterEntry struct {
ScatterData
File string
}
type ScatterSeries ¶
type ScatterSeries map[Category][]opts.ScatterData
Click to show internal directories.
Click to hide internal directories.