GenericChart Module

Module to represent a GenericChart

Functions and values

Function or value Description

addConfig config gChart

Full Usage: addConfig config gChart

Parameters:
Returns: GenericChart
config : Config
gChart : GenericChart
Returns: GenericChart

addDisplayOptions displayOpts gChart

Full Usage: addDisplayOptions displayOpts gChart

Parameters:
Returns: GenericChart
displayOpts : DisplayOptions
gChart : GenericChart
Returns: GenericChart

addLayout layout gChart

Full Usage: addLayout layout gChart

Parameters:
Returns: GenericChart
layout : Layout
gChart : GenericChart
Returns: GenericChart

combine gCharts

Full Usage: combine gCharts

Parameters:
Returns: GenericChart
gCharts : seq<GenericChart>
Returns: GenericChart

countTrace gChart

Full Usage: countTrace gChart

Parameters:
Returns: int

Returns the number of traces within the GenericChart

gChart : GenericChart
Returns: int

existsTrace predicate gChart

Full Usage: existsTrace predicate gChart

Parameters:
Returns: bool

Returns true if the given chart contains a trace for which the predicate function returns true

predicate : Trace -> bool
gChart : GenericChart
Returns: bool

fromFigure fig

Full Usage: fromFigure fig

Parameters:
Returns: GenericChart
fig : Figure
Returns: GenericChart

getConfig gChart

Full Usage: getConfig gChart

Parameters:
Returns: Config
gChart : GenericChart
Returns: Config

getDisplayOptions gChart

Full Usage: getDisplayOptions gChart

Parameters:
Returns: DisplayOptions
gChart : GenericChart
Returns: DisplayOptions

getLayout gChart

Full Usage: getLayout gChart

Parameters:
Returns: Layout
gChart : GenericChart
Returns: Layout

getTraceID gChart

Full Usage: getTraceID gChart

Parameters:
Returns: TraceID

returns a single TraceID (when all traces of the charts are of the same type), or traceID.Multi if the chart contains traces of multiple different types

gChart : GenericChart
Returns: TraceID

getTraceIDs gChart

Full Usage: getTraceIDs gChart

Parameters:
Returns: TraceID list

returns a list of TraceIDs representing the types of all traces contained in the chart.

gChart : GenericChart
Returns: TraceID list

getTraces gChart

Full Usage: getTraces gChart

Parameters:
Returns: Trace list
gChart : GenericChart
Returns: Trace list

mapConfig f gChart

Full Usage: mapConfig f gChart

Parameters:
Returns: GenericChart
f : Config -> 'a
gChart : GenericChart
Returns: GenericChart

mapDisplayOptions f gChart

Full Usage: mapDisplayOptions f gChart

Parameters:
Returns: GenericChart
f : DisplayOptions -> 'a8
gChart : GenericChart
Returns: GenericChart

mapLayout f gChart

Full Usage: mapLayout f gChart

Parameters:
Returns: GenericChart
f : Layout -> 'a8
gChart : GenericChart
Returns: GenericChart

mapTrace f gChart

Full Usage: mapTrace f gChart

Parameters:
Returns: GenericChart

Creates a new GenericChart whose traces are the results of applying the given function to each of the trace of the GenericChart.

f : Trace -> Trace
gChart : GenericChart
Returns: GenericChart

mapiTrace f gChart

Full Usage: mapiTrace f gChart

Parameters:
Returns: GenericChart

Creates a new GenericChart whose traces are the results of applying the given function to each of the trace of the GenericChart. The integer index passed to the function indicates the index (from 0) of element being transformed.

f : int -> Trace -> Trace
gChart : GenericChart
Returns: GenericChart

ofTraceObject useDefaults trace

Full Usage: ofTraceObject useDefaults trace

Parameters:
    useDefaults : bool
    trace : Trace

Returns: GenericChart

Converts from a trace object and a layout object into GenericChart. If useDefaults = true, also sets the default Chart properties found in `Defaults`

useDefaults : bool
trace : Trace
Returns: GenericChart

ofTraceObjects useDefaults traces

Full Usage: ofTraceObjects useDefaults traces

Parameters:
    useDefaults : bool
    traces : Trace list

Returns: GenericChart

Converts from a list of trace objects and a layout object into GenericChart. If useDefaults = true, also sets the default Chart properties found in `Defaults`

useDefaults : bool
traces : Trace list
Returns: GenericChart

setConfig config gChart

Full Usage: setConfig config gChart

Parameters:
Returns: GenericChart
config : Config
gChart : GenericChart
Returns: GenericChart

setDisplayOptions displayOpts gChart

Full Usage: setDisplayOptions displayOpts gChart

Parameters:
Returns: GenericChart
displayOpts : DisplayOptions
gChart : GenericChart
Returns: GenericChart

setLayout layout gChart

Full Usage: setLayout layout gChart

Parameters:
Returns: GenericChart
layout : Layout
gChart : GenericChart
Returns: GenericChart

toChartHTML gChart

Full Usage: toChartHTML gChart

Parameters:
Returns: string
gChart : GenericChart
Returns: string

toChartHTMLNodes gChart

Full Usage: toChartHTMLNodes gChart

Parameters:
Returns: XmlNode
gChart : GenericChart
Returns: XmlNode

toEmbeddedHTML gChart

Full Usage: toEmbeddedHTML gChart

Parameters:
Returns: string

Converts a GenericChart to it HTML representation and embeds it into a html page.

gChart : GenericChart
Returns: string

toFigure gChart

Full Usage: toFigure gChart

Parameters:
Returns: Figure
gChart : GenericChart
Returns: Figure

toFigureJson gChart

Full Usage: toFigureJson gChart

Parameters:
Returns: string

Serializes a GenericChart to a JSON string, representing the data and layout of the GenericChart: { "data": [ -serialized traces array- ] , "layout": { -serialized layout object- } , "frames": [ -empty array, not supported yet, legacy stuff- ] }

gChart : GenericChart

the chart to serialize

Returns: string

toJson gChart

Full Usage: toJson gChart

Parameters:
Returns: string

Serializes a GenericChart to a JSON string, representing the data, layout and config of the GenericChart: { "data": [ -serialized traces array- ] , "layout": { -serialized layout object- } , "config": { -serialized config object- } }

gChart : GenericChart

the chart to serialize

Returns: string

tryGetLayoutSize gChart

Full Usage: tryGetLayoutSize gChart

Parameters:
Returns: int option * int option

Returns a tuple containing the width and height of a GenericChart's layout if the property is set, otherwise returns None

gChart : GenericChart
Returns: int option * int option