Information on this website refers to a deprecated product, and is provided only for historical reference. Please use the Version Switcher above to select an appropriate documentation website for the product you are using.

StockGraph

Type class

StockGraph displays graphs on StockPanel.

Inheritance

StockGraph extends AmGraph.

StockGraph is not extended by any other symbol.

Properties

comparable
#

Type boolean

Default false

Specifies whether this graph will be compared if some data set is selected for comparing.

compareField
#

Type string

Default

Specifies a field to be used to generate comparing graph. Note, this field is not the one used in your dataProvider, but toField from FieldMapping object.

compareFromStart
#

Type boolean

Default false

If you set it to true, when data sets are compared, the graphs will use first value as a base value instead of using the first value of selected period.

compareGraphBalloonColor
#

Type string

Default

Balloon color of comparing graph.

compareGraphBalloonText
#

Type string

Default

Balloon text of comparing graph.

compareGraphBullet
#

Type string

Default

Bullet of comparing graph. Possible values are: "square", "round", "line", "triangleUp", "triangleDown", "dashedLine", "bubble".

compareGraphBulletSize
#

Type number

Default

Bullet size of comparing graph.

compareGraphCornerRadiusTop
#

Type number

Default

Corner radius of comparing graph (if type is "column").

compareGraphDashLength
#

Type number

Default

Dash length of compare graph.

compareGraphFillAlphas
#

Type number

Default

Fill alpha of comparing graph.

compareGraphFillColors
#

Type string

Default

Fill color of comparing graph.

compareGraphLineAlpha
#

Type number

Default

Opacity of comparing graph line.

compareGraphLineThickness
#

Type number

Default

Thickness of compare graph.

compareGraphType
#

Type string

Default "line"

Type of comparing graph. Possible values are: "line", "column", "step", "smoothedLine."

compareGraphVisibleInLegend
#

Type boolean

Default true

Specifies if compare graph is visible in legend.

periodValue
#

Type string

Default "Close"

When data is grouped to periods, the graph must know which period value should be used. Possible values are: "Open", "Low", "High", "Close", "Average" and "Sum".

useDataSetColors
#

Type boolean

Default true

Specifies whether data set color should be used as this graph's lineColor.

alphaField
#

Type string

Default

Inherited from AmGraph

Name of the alpha field in your dataProvider.

balloonColor
#

Type string

Default

Inherited from AmGraph

Value balloon color. Will use graph or data item color if not set.

balloonText
#

Type string

Default [[value]]

Inherited from AmGraph

Balloon text. You can use tags like [[value]], [[description]], [[percents]], [[open]], [[category]]

baloonFunction
#

Type Function

Inherited from AmGraph

If you set some function, the graph will call it and pass GraphDataItem and AmGraph object to it. This function should return a string which will be displayed in a balloon.

behindColumns
#

Type boolean

Default false

Inherited from AmGraph

Specifies if the line graph should be placed behind column graphs

bullet
#

Type string

Default none

Inherited from AmGraph

Type of the bullets. Possible values are: "none", "round", "square", "triangleUp", "triangleDown", "bubble", "custom".

bulletAlpha
#

Type number

Default 1

Inherited from AmGraph

Opacity of bullets. Value range is 0 - 1.

bulletBorderAlpha
#

Type number

Default 1

Inherited from AmGraph

Bullet border opacity.

bulletBorderColor
#

Type string

Default

Inherited from AmGraph

Bullet border color. Will use lineColor if not set.

bulletBorderThickness
#

Type number

Default 2

Inherited from AmGraph

Bullet border thickness.

bulletColor
#

Type string

Default

Inherited from AmGraph

Bullet color. Will use lineColor if not set.

bulletField
#

Type string

Default

Inherited from AmGraph

Name of the bullet field in your dataProvider.

bulletOffset
#

Type number

Default 0

Inherited from AmGraph

Bullet offset. Distance from the actual data point to the bullet. Can be used to place custom bullets above the columns.

bulletSize
#

Type number

Default 8

Inherited from AmGraph

Bullet size.

bulletSizeField
#

Type string

Default

Inherited from AmGraph

Name of the bullet size field in your dataProvider.

closeField
#

Type string

Default

Inherited from AmGraph

Name of the close field (used by candlesticks and ohlc) in your dataProvider.

color
#

Type string

Default

Inherited from AmGraph

Color of value labels. Will use chart's color if not set.

colorField
#

Type string

Default

Inherited from AmGraph

Name of the color field in your dataProvider.

connect
#

Type boolean

Default true

Inherited from AmGraph

Specifies whether to connect data points if data is missing. The default value is true.

cornerRadiusTop
#

Type number

Default 0

Inherited from AmGraph

Corner radius of column. It can be set both in pixels or in percents. The chart's depth and angle styles must be set to 0. The default value is 0. Note, cornerRadiusTop will be applied for all corners of the column, JavaScript charts do not have a possibility to set separate corner radius for top and bottom. As we want all the property names to be the same both on JS and Flex, we didn't change this too.

cursorBulletAlpha
#

Type number

Default 1

Inherited from AmGraph

If bulletsEnabled of ChartCurosor is true, a bullet on each graph follows the cursor. You can set opacity of each graphs bullet. In case you want to disable these bullets for a certain graph, set opacity to 0.

customBullet
#

Type string

Default

Inherited from AmGraph

Path to the image of custom bullet.

customBulletField
#

Type string

Default

Inherited from AmGraph

Name of the custom bullet field in your dataProvider.

dashLength
#

Type number

Default 0

Inherited from AmGraph

Dash length. If you set it to a value greater than 0, the graph line will be dashed.

descriptionField
#

Type string

Default

Inherited from AmGraph

Name of the description field in your dataProvider.

fillAlphas
#

Type number

Default 0

Inherited from AmGraph

Opacity of fill. Plural form is used to keep the same property names as our Flex charts'. Flex charts can accept array of numbers to generate gradients. Although you can set array here, only first value of this array will be used.

fillColors
#

Type String/Array

Default

Inherited from AmGraph

Fill color. Will use lineColor if not set.

fillColorsField
#

Type string

Default

Inherited from AmGraph

Name of the fill colors field in your dataProvider.

fillToGraph
#

Type AmGraph

Inherited from AmGraph

You can set another graph here and if fillAlpha is >0, the area from this graph to fillToGraph will be filled (instead of filling the area to the X axis).

fontSize
#

Type number

Default

Inherited from AmGraph

Size of value labels text. Will use chart's fontSize if not set.

gradientOrientation
#

Type string

Default vertical

Inherited from AmGraph

Orientation of the gradient fills (only for "column" graph type). Possible values are "vertical" and "horizontal".

hidden
#

Type boolean

Default false

Inherited from AmGraph

Specifies whether the graph is hidden. Do not use this to show/hide the graph, use hideGraph(graph) and showGraph(graph) methods instead.

hideBulletsCount
#

Type number

Default 0

Inherited from AmGraph

If there are more data points than hideBulletsCount, the bullets will not be shown. 0 means the bullets will always be visible.

highField
#

Type string

Default

Inherited from AmGraph

Name of the high field (used by candlesticks and ohlc) in your dataProvider.

includeInMinMax
#

Type boolean

Default true

Inherited from AmGraph

Whether to include this graph when calculating min and max value of the axis.

labelColorField
#

Type string

Inherited from AmGraph

Name of label color field in data provider.

labelPosition
#

Type string

Default top

Inherited from AmGraph

Position of value label. Possible values are: "bottom", "top", "right", "left", "inside", "middle". Sometimes position is changed by the chart, depending on a graph type, rotation, etc.

labelText
#

Type string

Default

Inherited from AmGraph

Value label text. You can use tags like [[value]], [[description]], [[percents]], [[open]], [[category]].

legendAlpha
#

Type number

Default

Inherited from AmGraph

Legend marker opacity. Will use lineAlpha if not set. Value range is 0 - 1.

legendColor
#

Type string

Default

Inherited from AmGraph

Legend marker color. Will use lineColor if not set.

legendValueText
#

Type string

Default

Inherited from AmGraph

Legend value text. You can use tags like [[value]], [[description]], [[percents]], [[open]], [[category]] You can also use custom fields from your dataProvider. If not set, uses Legend's valueText.

lineAlpha
#

Type number

Default 1

Inherited from AmGraph

Opacity of the line (or column border). Value range is 0 - 1.

lineColor
#

Type string

Default

Inherited from AmGraph

Color of the line (or column border). If you do not set any, the color from [[AmCoordinateChart

lineColorField
#

Type string

Default

Inherited from AmGraph

Name of the line color field (used by columns and candlesticks only) in your dataProvider.

lineThickness
#

Type number

Default 1

Inherited from AmGraph

Specifies thickness of the graph line (or column border).

lowField
#

Type string

Default

Inherited from AmGraph

Name of the low field (used by candlesticks and ohlc) in your dataProvider.

markerType
#

Type string

Default

Inherited from AmGraph

Legend marker type. You can set legend marker (key) type for individual graphs. Possible values are: "square", "circle", "line", "dashedLine", "triangleUp", "triangleDown", "bubble".

maxBulletSize
#

Type number

Default 50

Inherited from AmGraph

Specifies size of the bullet which value is the biggest (XY chart).

minBulletSize
#

Type number

Default 0

Inherited from AmGraph

Specifies minimum size of the bullet (XY chart).

negativeBase
#

Type number

Default 0

Inherited from AmGraph

If you use different colors for your negative values, a graph below zero line is filled with negativeColor. With this property you can define a different base value at which colors should be changed to negative colors.

negativeFillAlphas
#

Type number

Default

Inherited from AmGraph

Fill opacity of negative part of the graph. Will use fillAlphas if not set.

negativeFillColors
#

Type String/Array

Default

Inherited from AmGraph

Fill color of negative part of the graph. Will use fillColors if not set.

negativeLineColor
#

Type string

Default

Inherited from AmGraph

Color of the line (or column) when the values are negative. In case the graph type is candlestick or ohlc, negativeLineColor is used when close value is less then open value.

numberFormatter
#

Type object

Default

Inherited from AmGraph

Example: {precision:-1, decimalSeparator:'.', thousandsSeparator:','}. The graph uses this object's values to format the numbers. Uses chart's numberFormatter if not defined.

openField
#

Type string

Default

Inherited from AmGraph

Name of the open field (used by floating columns, candlesticks and ohlc) in your dataProvider.

pointPosition
#

Type string

Default middle

Inherited from AmGraph

Specifies where data points should be placed - on the beginning of the period (day, hour, etc) or in the middle (only when parseDates property of categoryAxis is set to true). This setting affects Serial chart only. Possible values are "start" and "middle".

showAllValueLabels
#

Type boolean

Default false

Inherited from AmGraph

If graph's type is column and labelText is set, graph hides labels which do not fit into the column's space. If you don't want these labels to be hidden, set this to true.

showBalloon
#

Type boolean

Default true

Inherited from AmGraph

Specifies whether the value balloon of this graph is shown when mouse is over data item or chart's indicator is over some series.

showBalloonAt
#

Type string

Default close

Inherited from AmGraph

Specifies graphs value at which cursor is showed. This is only important for candlestick and ohlc charts, also if column chart has "open" value. Possible values are: "open", "close", "high", "low".

showHandOnHover
#

Type boolean

Default false

Inherited from AmGraph

If you want mouse pointer to change to hand when hovering the graph, set this property to true.

stackable
#

Type boolean

Default true

Inherited from AmGraph

If the value axis of this graph has stack types like "regular" or "100%" You can exclude this graph from stacking.

title
#

Type string

Default

Inherited from AmGraph

Graph title.

type
#

Type string

Default line

Inherited from AmGraph

Type of the graph. Possible values are: "line", "column", "step", "smoothedLine", "candlestick", "ohlc". XY and Radar charts can only display "line" type graphs.

urlField
#

Type string

Default

Inherited from AmGraph

Name of the url field in your dataProvider.

urlTarget
#

Type string

Default

Inherited from AmGraph

Target to open URLs in, i.e. _blank, _top, etc.

valueAxis
#

Type ValueAxis

Default

Inherited from AmGraph

Specifies which value axis the graph will use. Will use the first value axis if not set.

valueField
#

Type string

Default

Inherited from AmGraph

Name of the value field in your dataProvider.

visibleInLegend
#

Type boolean

Default true

Inherited from AmGraph

Specifies whether this graph should be shown in the Legend.

xAxis
#

Type ValueAxis

Default

Inherited from AmGraph

XY chart only. A horizontal value axis object to attach graph to.

xField
#

Type string

Default

Inherited from AmGraph

XY chart only. Name of the x field in your dataProvider.

yAxis
#

Type ValueAxis

Default

Inherited from AmGraph

XY chart only. A vertical value axis object to attach graph to.

yField
#

Type string

Default

Inherited from AmGraph

XY chart only. Name of the y field in your dataProvider.

There are 72 inherited items currently hidden from this list.

Methods

hideBullets()

#

Returns void

Inherited from AmGraph

Hides graph's bullets.

showBullets()

#

Returns void

Inherited from AmGraph

Shows graph's bullets.

There are 2 inherited items currently hidden from this list.

Events

StockGraph does not have any events.

Adapters

StockGraph does not have any adapters.