Warning: Use of undefined constant Symbol - assumed 'Symbol' (this will throw an Error in a future version of PHP) in /mnt/new-ebs/workbench-106550/lib/dojo/util/docscripts/lib/parser2/dojo2.inc on line 215 Warning: Use of undefined constant JavaScriptSymbol - assumed 'JavaScriptSymbol' (this will throw an Error in a future version of PHP) in /mnt/new-ebs/workbench-106550/lib/dojo/util/docscripts/lib/parser2/dojo2.inc on line 215

dojox/charting/Chart.js

  • Provides:

    • dojox.charting.Chart
  • Requires:

    • dojox.gfx in common
    • dojox.lang.functional in common
    • dojox.lang.functional.fold in common
    • dojox.lang.functional.reversed in common
    • dojox.charting.Element in common
    • dojox.charting.Theme in common
    • dojox.charting.Series in common
    • dojox.charting.axis2d.common in common
  • dojox.charting.Chart

    • type
      Function
    • parameters:
      • node: (typeof DOMNode)
      • kwArgs: (typeof dojox.charting.__ChartCtorArgs)
    • summary
      The main chart object in dojox.charting.  This will create a two dimensional
      chart based on dojox.gfx.
    • return_summary
      dojox.charting.Chart
      The newly created chart.
    • description
      dojox.charting.Chart is the primary object used for any kind of charts.  It
      is simple to create--just pass it a node reference, which is used as the
      container for the chart--and a set of optional keyword arguments and go.
      
      Note that like most of dojox.gfx, most of dojox.charting.Chart's methods are
      designed to return a reference to the chart itself, to allow for functional
      chaining.  This makes defining everything on a Chart very easy to do.
    • example
      Create an area chart, with smoothing.
      	new dojox.charting.Chart(node))
      		.addPlot("default", { type: "Areas", tension: "X" })
      		.setTheme(dojox.charting.themes.Shrooms)
      		.addSeries("Series A", [1, 2, 0.5, 1.5, 1, 2.8, 0.4])
      		.addSeries("Series B", [2.6, 1.8, 2, 1, 1.4, 0.7, 2])
      		.addSeries("Series C", [6.3, 1.8, 3, 0.5, 4.4, 2.7, 2])
      		.render();
    • example
      The form of data in a data series can take a number of forms: a simple array,
      an array of objects {x,y}, or something custom (as determined by the plot).
      Here's an example of a Candlestick chart, which expects an object of
      { open, high, low, close }.
      	new dojox.charting.Chart(node))
      		.addPlot("default", {type: "Candlesticks", gap: 1})
      		.addAxis("x", {fixLower: "major", fixUpper: "major", includeZero: true})
      		.addAxis("y", {vertical: true, fixLower: "major", fixUpper: "major", natural: true})
      		.addSeries("Series A", [
      				{ open: 20, close: 16, high: 22, low: 8 },
      				{ open: 16, close: 22, high: 26, low: 6, mid: 18 },
      				{ open: 22, close: 18, high: 22, low: 11, mid: 21 },
      				{ open: 18, close: 29, high: 32, low: 14, mid: 27 },
      				{ open: 29, close: 24, high: 29, low: 13, mid: 27 },
      				{ open: 24, close: 8, high: 24, low: 5 },
      				{ open: 8, close: 16, high: 22, low: 2 },
      				{ open: 16, close: 12, high: 19, low: 7 },
      				{ open: 12, close: 20, high: 22, low: 8 },
      				{ open: 20, close: 16, high: 22, low: 8 },
      				{ open: 16, close: 22, high: 26, low: 6, mid: 18 },
      				{ open: 22, close: 18, high: 22, low: 11, mid: 21 },
      				{ open: 18, close: 29, high: 32, low: 14, mid: 27 },
      				{ open: 29, close: 24, high: 29, low: 13, mid: 27 },
      				{ open: 24, close: 8, high: 24, low: 5 },
      				{ open: 8, close: 16, high: 22, low: 2 },
      				{ open: 16, close: 12, high: 19, low: 7 },
      				{ open: 12, close: 20, high: 22, low: 8 },
      				{ open: 20, close: 16, high: 22, low: 8 },
      				{ open: 16, close: 22, high: 26, low: 6 },
      				{ open: 22, close: 18, high: 22, low: 11 },
      				{ open: 18, close: 29, high: 32, low: 14 },
      				{ open: 29, close: 24, high: 29, low: 13 },
      				{ open: 24, close: 8, high: 24, low: 5 },
      				{ open: 8, close: 16, high: 22, low: 2 },
      				{ open: 16, close: 12, high: 19, low: 7 },
      				{ open: 12, close: 20, high: 22, low: 8 },
      				{ open: 20, close: 16, high: 22, low: 8 }
      			],
      			{ stroke: { color: "green" }, fill: "lightgreen" }
      		)
      		.render();
      
      theme: dojox.charting.Theme?
      An optional theme to use for styling the chart.
      axes: dojox.charting.Axis{}?
      A map of axes for use in plotting a chart.
      stack: dojox.charting.plot2d.Base[]
      A stack of plotters.
      plots: dojox.charting.plot2d.Base{}
      A map of plotter indices
      series: dojox.charting.Series[]
      The stack of data runs used to create plots.
      runs: dojox.charting.Series{}
      A map of series indices
      margins: Object?
      The margins around the chart. Default is { l:10, t:10, r:10, b:10 }.
      stroke: dojox.gfx.Stroke?
      The outline of the chart (stroke in vector graphics terms).
      fill: dojox.gfx.Fill?
      The color for the chart.
      node: DOMNode
      The container node passed to the constructor.
      surface: dojox.gfx.Surface
      The main graphics surface upon which a chart is drawn.
      dirty: Boolean
      A boolean flag indicating whether or not the chart needs to be updated/re-rendered.
      coords: Object
      The coordinates on a page of the containing node, as returned from dojo.coords.
  • dojox.charting.Chart.constructor

    • constructor - constructor
    • type
      Function
    • parameters:
      • node: (typeof DOMNode)
      • kwArgs: (typeof dojox.charting.__ChartCtorArgs)
    • summary
      The constructor for a new Chart.  Initializes all parameters used for a chart.
    • return_summary
      dojox.charting.Chart
      The newly created chart.
  • dojox.charting.Chart.destroy

    • summary
      Cleanup when a chart is to be destroyed.
    • return_summary
      void
    • type
      Function
  • dojox.charting.Chart.getCoords

    • returns
      Object
    • summary
      Get the coordinates and dimensions of the containing DOMNode, as
      returned by dojo.coords.
    • return_summary
      Object
      The resulting coordinates of the chart.  See dojo.coords for details.
    • type
      Function
  • dojox.charting.Chart.coords

    • type
      Object
  • dojox.charting.Chart.setTheme

    • parameters:
      • theme: (typeof dojox.charting.Theme)
        The theme to be used for visual rendering.
    • returns
      dojox.charting.Chart
    • summary
      Set a theme of the chart.
    • return_summary
      dojox.charting.Chart
      A reference to the current chart for functional chaining.
    • type
      Function
  • dojox.charting.Chart.theme

    • type
      Object
  • dojox.charting.Chart.dirty

    • type
      Object
  • dojox.charting.Chart.setTheme.theme

    • type
      dojox.charting.Theme
    • summary
      The theme to be used for visual rendering.
  • dojox.charting.Chart.addAxis

    • parameters:
      • name: (typeof String)
        The name of the axis.
      • kwArgs: (typeof dojox.charting.axis2d.__AxisCtorArgs)
        An optional keyword arguments object for use in defining details of an axis.
    • returns
      dojox.charting.Chart
    • summary
      Add an axis to the chart, for rendering.
    • return_summary
      dojox.charting.Chart
      A reference to the current chart for functional chaining.
    • type
      Function
  • dojox.charting.Chart.getAxis

    • parameters:
      • name: (typeof String)
        The name the axis was defined by.
    • returns
      dojox.charting.axis2d.Default
    • summary
      Get the given axis, by name.
    • return_summary
      dojox.charting.axis2d.Default
      The axis as stored in the chart's axis map.
    • type
      Function
  • dojox.charting.Chart.removeAxis

    • parameters:
      • name: (typeof String)
        The axis name, as defined in addAxis.
    • returns
      dojox.charting.Chart
    • summary
      Remove the axis that was defined using name.
    • return_summary
      dojox.charting.Chart
      A reference to the current chart for functional chaining.
    • type
      Function
  • dojox.charting.Chart.addPlot

    • parameters:
      • name: (typeof String)
        The name of the plot to be added to the chart.  If you only plan on using one plot, call it "default".
      • kwArgs: (typeof dojox.charting.plot2d.__PlotCtorArgs)
        An object with optional parameters for the plot in question.
    • returns
      dojox.charting.Chart
    • summary
      Add a new plot to the chart, defined by name and using the optional keyword arguments object.
      Note that dojox.charting assumes the main plot to be called "default"; if you do not have
      a plot called "default" and attempt to add data series to the chart without specifying the
      plot to be rendered on, you WILL get errors.
    • return_summary
      dojox.charting.Chart
      A reference to the current chart for functional chaining.
    • type
      Function
  • dojox.charting.Chart.removePlot

    • parameters:
      • name: (typeof String)
        The name of the plot as defined using addPlot.
    • returns
      dojox.charting.Chart
    • summary
      Remove the plot defined using name from the chart's plot stack.
    • return_summary
      dojox.charting.Chart
      A reference to the current chart for functional chaining.
    • type
      Function
  • dojox.charting.Chart.runs

    • type
      Object
  • dojox.charting.Chart.series

    • type
      Array
  • dojox.charting.Chart.getPlotOrder

    • returns
      Array
    • summary
      Returns an array of plot names in the current order
      (the top-most plot is the first).
    • return_summary
      Array
    • type
      Function
  • dojox.charting.Chart.setPlotOrder

    • parameters:
      • newOrder: (typeof Array:)
        Array of plot names compatible with getPlotOrder().
    • returns
      dojox.charting.Chart
    • summary
      Sets new order of plots. newOrder cannot add or remove
      plots. Wrong names, or dups are ignored.
    • return_summary
      dojox.charting.Chart
      A reference to the current chart for functional chaining.
    • type
      Function
  • dojox.charting.Chart.stack

    • type
      Array
  • dojox.charting.Chart.movePlotToFront

    • parameters:
      • name: (typeof String:)
        Plot's name to move.
    • returns
      dojox.charting.Chart
    • summary
      Moves a given plot to front.
    • return_summary
      dojox.charting.Chart
      A reference to the current chart for functional chaining.
    • type
      Function
  • dojox.charting.Chart.movePlotToBack

    • parameters:
      • name: (typeof String:)
        Plot's name to move.
    • returns
      dojox.charting.Chart
    • summary
      Moves a given plot to back.
    • return_summary
      dojox.charting.Chart
      A reference to the current chart for functional chaining.
    • type
      Function
  • dojox.charting.Chart.addSeries

    • parameters:
      • name: (typeof String:)
        The name of the data series to be plotted.
      • data: (typeof Array|Object:)
        The array of data points (either numbers or objects) that
        represents the data to be drawn. Or it can be an object. In
        the latter case, it should have a property "data" (an array),
        destroy(), and setSeriesObject().
      • kwArgs: (typeof dojox.charting.__SeriesCtorArgs:)
        An optional keyword arguments object that will be mixed into
        the resultant series object.
    • returns
      dojox.charting.Chart
    • summary
      Add a data series to the chart for rendering.
    • return_summary
      dojox.charting.Chart:
      A reference to the current chart for functional chaining.
    • type
      Function
  • dojox.charting.Chart.removeSeries

    • parameters:
      • name: (typeof String)
        The name of the series as defined by addSeries.
    • returns
      dojox.charting.Chart
    • summary
      Remove the series defined by name from the chart.
    • return_summary
      dojox.charting.Chart
      A reference to the current chart for functional chaining.
    • type
      Function
  • dojox.charting.Chart.updateSeries

    • parameters:
      • name: (typeof String)
        The name of the series as defined in addSeries.
      • data: (typeof Array|Object:)
        The array of data points (either numbers or objects) that
        represents the data to be drawn. Or it can be an object. In
        the latter case, it should have a property "data" (an array),
        destroy(), and setSeriesObject().
    • returns
      dojox.charting.Chart
    • summary
      Update the given series with a new set of data points.
    • return_summary
      dojox.charting.Chart
      A reference to the current chart for functional chaining.
    • type
      Function
  • dojox.charting.Chart.getSeriesOrder

    • parameters:
      • plotName: (typeof String:)
        Plot's name.
    • summary
      Returns an array of series names in the current order
      (the top-most series is the first) within a plot.
    • return_summary
      Array
    • type
      Function
  • dojox.charting.Chart.setSeriesOrder

    • parameters:
      • newOrder: (typeof Array:)
        Array of series names compatible with getPlotOrder(). All
        series should belong to the same plot.
    • returns
      dojox.charting.Chart
    • summary
      Sets new order of series within a plot. newOrder cannot add
      or remove series. Wrong names, or dups are ignored.
    • return_summary
      dojox.charting.Chart
      A reference to the current chart for functional chaining.
    • type
      Function
  • dojox.charting.Chart.moveSeriesToFront

    • parameters:
      • name: (typeof String:)
        Series' name to move.
    • returns
      dojox.charting.Chart
    • summary
      Moves a given series to front of a plot.
    • return_summary
      dojox.charting.Chart
      A reference to the current chart for functional chaining.
    • type
      Function
  • dojox.charting.Chart.moveSeriesToBack

    • parameters:
      • name: (typeof String:)
        Series' name to move.
    • returns
      dojox.charting.Chart
    • summary
      Moves a given series to back of a plot.
    • return_summary
      dojox.charting.Chart
      A reference to the current chart for functional chaining.
    • type
      Function
  • dojox.charting.Chart.resize

    • parameters:
      • width: (typeof Number)
        The new width of the chart.
      • height: (typeof Number)
        The new height of the chart.
    • returns
      dojox.charting.Chart
    • summary
      Resize the chart to the dimensions of width and height.
    • description
      Resize the chart and its surface to the width and height dimensions.
      If no width/height or box is provided, resize the surface to the marginBox of the chart.
    • return_summary
      dojox.charting.Chart
      A reference to the current chart for functional chaining.
    • type
      Function
  • dojox.charting.Chart.getGeometry

    • returns
      Object
    • summary
      Returns a map of information about all axes in a chart and what they represent
      in terms of scaling (see dojox.charting.axis2d.Default.getScaler).
    • return_summary
      Object
      An map of geometry objects, a one-to-one mapping of axes.
    • type
      Function
  • dojox.charting.Chart.setAxisWindow

    • parameters:
      • name: (typeof String)
        The name of the axis as defined by addAxis.
      • scale: (typeof Number)
        The scale on the target axis.
      • offset: (typeof Number)
        Any offest, as measured by axis tick
      • zoom: (typeof Boolean|Object)
        The chart zooming animation trigger.  This is null by default,
        e.g. {duration: 1200}, or just set true.
    • returns
      dojox.charting.Chart
    • summary
      Zooms an axis and all dependent plots. Can be used to zoom in 1D.
    • return_summary
      dojox.charting.Chart
      A reference to the current chart for functional chaining.
    • type
      Function
  • dojox.charting.Chart.setWindow

    • parameters:
      • sx: (typeof Number)
        The scale for the x axis.
      • sy: (typeof Number)
        The scale for the y axis.
      • dx: (typeof Number)
        The pixel offset on the x axis.
      • dy: (typeof Number)
        The pixel offset on the y axis.
      • zoom: (typeof Boolean|Object)
        The chart zooming animation trigger.  This is null by default,
        e.g. {duration: 1200}, or just set true.
    • returns
      dojox.charting.Chart
    • summary
      Zooms in or out any plots in two dimensions.
    • return_summary
      dojox.charting.Chart
      A reference to the current chart for functional chaining.
    • type
      Function
  • dojox.charting.Chart.zoomIn

    • parameters:
      • name: (typeof String)
        The name of the axis as defined by addAxis.
      • range: (typeof Array)
        The end points of the zoom range, measured in axis ticks.
    • summary
      Zoom the chart to a specific range on one axis.  This calls render()
      directly as a convenience method.
    • type
      Function
  • dojox.charting.Chart.calculateGeometry

    • returns
      dojox.charting.Chart
    • summary
      Calculate the geometry of the chart based on the defined axes of
      a chart.
    • return_summary
      dojox.charting.Chart
      A reference to the current chart for functional chaining.
    • type
      Function
  • dojox.charting.Chart.fullGeometry

    • returns
      dojox.charting.Chart
    • summary
      Calculate the full geometry of the chart.  This includes passing
      over all major elements of a chart (plots, axes, series, container)
      in order to ensure proper rendering.
    • return_summary
      dojox.charting.Chart
      A reference to the current chart for functional chaining.
    • type
      Function
  • dojox.charting.Chart.dim

    • type
      Object
  • dojox.charting.Chart.offsets

    • type
      Object
  • dojox.charting.Chart.titleGap

  • dojox.charting.Chart.titlePos

    • type
      String
  • dojox.charting.Chart.titleFont

    • type
      Object
  • dojox.charting.Chart.titleFontColor

    • type
      String
  • dojox.charting.Chart.plotArea

    • type
      Object
  • dojox.charting.Chart.render

    • returns
      dojox.charting.Chart
    • summary
      Render the chart according to the current information defined.  This should
      be the last call made when defining/creating a chart, or if data within the
      chart has been changed.
    • return_summary
      dojox.charting.Chart
      A reference to the current chart for functional chaining.
    • type
      Function
  • dojox.charting.Chart.fullRender

    • returns
      dojox.charting.Chart
    • summary
      Force a full rendering of the chart, including full resets on the chart itself.
      You should not call this method directly unless absolutely necessary.
    • return_summary
      dojox.charting.Chart
      A reference to the current chart for functional chaining.
    • type
      Function
  • dojox.charting.Chart.chartTitle

    • type
      Object
  • dojox.charting.Chart.delayedRender

    • returns
      dojox.charting.Chart
    • summary
      Delayed render, which is used to collect multiple updates
      within a delayInMs time window.
    • return_summary
      dojox.charting.Chart
      A reference to the current chart for functional chaining.
    • type
      Function
  • dojox.charting.Chart._delayedRenderHandle

    • type
      Object
  • dojox.charting.Chart.connectToPlot

    • parameters:
      • name: (typeof String)
        The name of the plot as defined by addPlot.
      • object: (typeof Object)
        The object to be connected.
      • method: (typeof Function)
        The function to be executed.
    • returns
      Array
    • summary
      A convenience method to connect a function to a plot.
    • return_summary
      Array
      A handle to the connection, as defined by dojo.connect (see dojo.connect).
    • type
      Function
  • dojox.charting.Chart.fireEvent

    • parameters:
      • seriesName: (typeof String:)
        Series name.
      • eventName: (typeof String:)
        Event name to simulate: onmouseover, onmouseout, onclick.
      • index: (typeof Number:)
        Valid data value index for the event.
    • returns
      dojox.charting.Chart
    • summary
      Fires a synthetic event for a series item.
    • return_summary
      dojox.charting.Chart
      A reference to the current chart for functional chaining.
    • type
      Function
  • dojox.charting.Chart._makeClean

    • type
      Function
  • dojox.charting.Chart._makeDirty

    • type
      Function
  • dojox.charting.Chart._invalidateDependentPlots

    • parameters:
      • plotName
      • verticalAxis: (typeof Boolean)
    • type
      Function
  • dojox.charting.Chart.margins

    • type
      Object
  • dojox.charting.Chart.stroke

  • dojox.charting.Chart.fill

  • dojox.charting.Chart.delayInMs

    • type
      Number
  • dojox.charting.Chart.title

  • dojox.charting.Chart.axes

    • type
      Object
  • dojox.charting.Chart.plots

    • type
      Object
  • dojox.charting.Chart.node

    • type
      Object
  • dojox.charting.Chart.surface

    • type
      Object
  • dojox.charting.__ChartCtorArgs

    • type
      Object
  • dojox.lang.functional

    • alias - dojox.lang.functional
  • dojox.charting

    • alias - dojox.charting
  • dojox.gfx

    • alias - dojox.gfx
  • dojox

    • type
      Object