Show:

A widget for creating data chart

Methods

destroy

()

Removes the chart functionality completely. This will return the element back to its pre-init state.

getPlotObject

()

Returns chart object

resetZoom

()

Redraw chart without axis ranges

Properties

charttype

Unknown

Specifies the type of chart. According to this property and xtypex ytype, proper default options corresponding to chart type are applied and data are transformed to the format expected by flot. Following values are supported: line,bar,pie Options is not required. If it is not used the options and data format remains the same as flot uses by default.

Default: null

data

Unknown

Data to be plotted. The format is the same used by flot. The format may differ if the charttype option is set to pie or bar.

Default: []

grid

Object

Options customizing the chart grid.

Default: {clickable:true, hoverable:true}

Sub-properties:

  • clickable Boolean

    Grid accepts click events.

  • hoverable Boolean

    Grid fires mouseover event. Necessary for tooltip to work.

legend

Object

Legend properties

Default: {postion:'ne', sorted: 'ascending'}

Sub-properties:

  • position String

    Defines the placement of the legend in the grid. One of ne,nw,se,sw

  • sorted String

    Defines the order of labels in the legend. One of ascending,descending,false.

tooltip

Boolean

Turns on tooltip (text shown when mouse points to a part of a chart)

Default: true

tooltipOpts

Object

Customizes the tooltip.

Default: { content: '%s [%x,%y]'}

Sub-properties:

  • content String

    Specify the tooltip format. Use %s for series label, %x for X values, %y for Y value

  • defaultTheme Object

xaxis

Object

Customizes the horizontal axis

Default: {min: null, max: null,autoscaleMargin: null, axisLabel: ''}

Sub-properties:

  • min Number

    Minimal value shown on axis

  • max Number

    Maximal values show on axis

  • autoscaleMargin Number

    It's the fraction of margin that the scaling algorithm will add to avoid that the outermost points ends up on the grid border

  • axisLabel String

    Axis description

xaxis

Object

Customizes the vertical axis

Default: {min: null, max: null,autoscaleMargin: 0.2,axisLabel: ''}

Sub-properties:

  • min Number

    Minimal value shown on axis

  • max Number

    Maximal values show on axis

  • autoscaleMargin Number

    It's the fraction of margin that the scaling algorithm will add to avoid that the outermost points ends up on the grid border.

  • axisLabel String

    Axis description

xtype

Unknown

Specify the data type of values plotted on x-axis Following options are supported: number,string,date

Default: null

xtype

Unknown

Specify the data type of values plotted on x-axis Following options are supported: number,string,date

Default: null

zoom

Unknown

Allows to zoom the chart. Supported only when line chart is used. Requires charttype to be set.

Default: false