public class FacetChart extends DrawPane implements HasChartBackgroundDrawnHandlers, HasChartDrawnHandlers, HasDataLabelClickHandlers, HasDataLabelHoverHandlers, HasLegendClickHandlers, HasLegendHoverHandlers, HasValueClickHandlers, HasZoomChangedHandlers
Can be used directly, or specified as chartConstructor
or
chartConstructor
.
NOTE: you must load the Drawing and Charts
Optional Modules
before you can use FacetChart. Also,
the Charts Module is available in Pro Edition or better, please see
smartclient.com/product for licensing
information.
To create a FacetChart, set facets
to an Array of Facet
objects describing the
chart dimensions and valueProperty
to value field
name. For example:
// Creating data Record sprRec = new Record(); sprRec.setAttribute("season", "Spring"); sprRec.setAttribute("temp", "79"); Record sumRec = new Record(); sumRec.setAttribute("season", "Summer"); sumRec.setAttribute("temp", "102"); Record autRec = new Record(); autRec.setAttribute("season", "Autumn"); autRec.setAttribute("temp", "81"); Record winRec = new Record(); winRec.setAttribute("season", "Winter"); winRec.setAttribute("temp", "59"); // Creating chart FacetChart chart = new FacetChart(); chart.setFacets(new Facet("season", "Season")); chart.setValueProperty("temp"); chart.setData(new Record[]{sprRec, sumRec, autRec, winRec}); chart.setTitle("Average temperature in Las Vegas");
The following SDK examples demonstrate charts with a single facet:
Having an "inlined facet" is another method to provide data to the chart. In this case each CellRecord
contains multiple data values; one facet definition is considered "inlined", meaning that
the facetValueIds from this facet appear as properties in each Record, and each such
property holds one data value. In this case the singular valueProperty
is ignored.
For example:
// Creating data CellRecord lvRec = new CellRecord(); lvRec.setAttribute("spring", "79"); lvRec.setAttribute("summer", "102"); lvRec.setAttribute("autumn", "81"); lvRec.setAttribute("winter", "59"); // Creating inlined facet Facet inlinedFacet = new Facet(); inlinedFacet.setInlinedValues(true); inlinedFacet.setValues( new FacetValue("spring", "Spring"), new FacetValue("summer", "Summer"), new FacetValue("autumn", "Autumn"), new FacetValue("winter", "Winter") ); // Creating chart FacetChart chart = new FacetChart(); chart.setFacets(inlinedFacet); chart.setData(new Record[]{lvRec}); chart.setTitle("Average temperature in Las Vegas");Example with two facets:
// Creating data CellRecord lvRec = new CellRecord(); lvRec.setAttribute("city", "Las Vegas"); lvRec.setAttribute("spring", "79"); lvRec.setAttribute("summer", "102"); lvRec.setAttribute("autumn", "81"); lvRec.setAttribute("winter", "59"); CellRecord nyRec = new CellRecord(); nyRec.setAttribute("city", "New York"); nyRec.setAttribute("spring", "60"); nyRec.setAttribute("summer", "83"); nyRec.setAttribute("autumn", "66"); nyRec.setAttribute("winter", "40"); // Creating inlined facet Facet inlinedFacet = new Facet(); inlinedFacet.setInlinedValues(true); inlinedFacet.setValues( new FacetValue("spring", "Spring"), new FacetValue("summer", "Summer"), new FacetValue("autumn", "Autumn"), new FacetValue("winter", "Winter") ); // Creating chart FacetChart chart = new FacetChart(); chart.setFacets(inlinedFacet, new Facet("city", "City")); chart.setData(new Record[]{lvRec, nyRec}); chart.setStacked(false); chart.setTitle("Average temperatures");
FacetChart supports drawing multiple vertical axes. This is commonly used to show values with different units (for example: sales in dollars, total units shipped) and/or very different ranges (for example: gross revenue, profit) on the same chart. Each set of values, referred to as a "metric", gets its own axis and gradation marks.
To use multiple axes, you add an additional facet called the "metric facet" that specifies
each axis to be plotted as a facetValueId. The metric facet is an inlined facet, so as with
inlined facets in general, each CellRecord has a value for each facetValueId of the metric
facet. You then set extraAxisMetrics
to the
list of
metrics that should be plotted as additional axes.
For example, if you were plotting revenue and profit for each month of the year, you would
have one facet named "metric" with facetValueIds "revenue" and "profit" and a second facet
"month". Each CellRecord would have the revenue and profit for one month, stored under the
properties "revenue" and "profit". Setting extraAxisMetrics
to ["profit"]
would cause plofit to be plotted as the second axis. See the
Dual Axis SDK sample for
an example.
You can have multiple extra axes and the additional axes and gradation tics will be drawn at
increasing distances from the chart. By default, the first metric is drawn as a column chart
and subsequent metrics are drawn as lines; you can override this via
extraAxisSettings
. See the
3+ Axes SDK sample for
an example of multiple extra axes.
Multi-axis, multi-facet charts are also allowed. Extending the previous example, you might add a new facet "company", for a total of 3 facets. Each CellRecord would have "revenue" and "profit" for one combination of "company" and "month". The default appearance in this case would show revenue as clustered columns (one cluster per month, one column per company) and would show profit as multiple lines (one per company). See the Multi-Series SDK sample for an example of a multi-axis, multi-facet chart.
To achieve a mixed plot like this, define it as a multi-axis chart as explained above, but
set showAxis
false to avoid a second axis
appearing, and set
matchGradations
to cause the same gradations
to be used for both
plots.
See the Mixed Plots SDK example.
Scatter charts differ from other chart types in that both axes represent continuous numeric
data rather than a discrete set of facet values (like months of the year). For this reason
Scatter charts use the same concept of a "metric" facet as is used by Dual-Axis charts,
where the metric facet is expected to have exactly two metrics: the
xAxisMetric
and yAxisMetric
.
Unlike all other chart types, a scatter plot may be specified with only the metric facet. However one additional facet can be defined, which allows multiple sets of x,y points to be drawn in different colors, analogous to the different colors of a multi-series line chart.
See the Scatter Plot SDK example.
Date values on the X axis
FacetChart also supports scatter charts where the x-axis represents date- or time-valued
data and the y-axis represents numeric data, as normal. To enable this mode all records in
the data must have values for the facetValueId of the
xAxisMetric
that are true Date objects, not Strings
or
null
s. For these charts, vertical lines are drawn to represent a sequence of
significant datetime values on the x-axis, such as the first day of the month or week. The
mechanism used to select these Dates and format them into the x-axis labels is the same
mechanism used by charts with labelCollapseMode
set to
"time".
A "bubble" chart is a type of scatter chart where the size of each rendered data
point represents an additional metric value, allowing 3 continuous data values to be
visualized together. When using chartType:"Bubble"
, the additional metric
is configured via pointSizeMetric
.
Points will be sized between the minDataPointSize
and
maxDataPointSize
, optionally with
logarithmic scaling
. A legend will be
included showing
how point size represents data values, and a multi-facet Bubble chart can optionally use a
different shape for each facetValue
via
useMultiplePointShapes
.
Variable-size points can also be used with other, non-scatter chart types (such as "Line"
or "Radar") when showDataPoints
is enabled, by
setting
pointSizeMetric
to the id
of a facetValue
of the metric facet. In this case, a legend for point sizes is not shown by default, but can
be enabled via showPointSizeLegend
.
Whenever drawing variable size data points, by default, the largest data points are drawn
first so that smaller data points are less likely to be completely occluded by larger data
points, but this can be disabled by setting
autoSortBubblePoints
to false
.
Visual
appearance of data points can be further customized by setting the
bubbleProperties
.
See the Bubble Chart SDK example.
FacetChart supports rendering an additional metric value as the color of each data
point. This feature requires that showDataPoints
be
enabled and is configured via colorScaleMetric
.
Instead
of data points being drawn using a separate color for each facetValue
of the
legend facet, the data points will be drawn using a color interpolated between the
scaleStartColor
and
scaleEndColor
, optionally with
logarithmic scaling
. A legend is included by
default
via showColorScaleLegend
that shows how the
data
values are mapped to a color via a gradient over the range of colors used in the chart.
Visual appearance of data points in color scale charts can be further customized by setting
the bubbleProperties
, just as with bubble
charts.
Note that when color is being used to show values of the colorScaleMetric
then
color cannot be used to distinguish between different facetValues
. Therefore
color scale charts cannot have a (non-metric) legend facet.
See the Color Scale Chart SDK example.
FacetCharts support printing on all supported desktop browsers. When using Pro Edition or
better with the Smart GWT Server Framework installed, charts can also be exported to PDF
via RPCManager.exportContent()
or to images via RPCManager.exportImage()
.
UIObject.DebugIdImpl, UIObject.DebugIdImplEnabled
config, configOnly, factoryCreated, factoryProperties, id, nativeObject, scClassName
DEBUG_ID_PREFIX
Constructor and Description |
---|
FacetChart() |
FacetChart(JavaScriptObject jsObj) |
Modifier and Type | Method and Description |
---|---|
HandlerRegistration |
addChartBackgroundDrawnHandler(ChartBackgroundDrawnHandler handler)
Add a chartBackgroundDrawn handler.
|
HandlerRegistration |
addChartDrawnHandler(ChartDrawnHandler handler)
Add a chartDrawn handler.
|
HandlerRegistration |
addDataLabelClickHandler(DataLabelClickHandler handler)
Add a dataLabelClick handler.
|
HandlerRegistration |
addDataLabelHoverHandler(DataLabelHoverHandler handler)
Add a dataLabelHover handler.
|
HandlerRegistration |
addLegendClickHandler(LegendClickHandler handler)
Add a legendClick handler.
|
HandlerRegistration |
addLegendHoverHandler(LegendHoverHandler handler)
Add a legendHover handler.
|
HandlerRegistration |
addValueClickHandler(ValueClickHandler handler)
Add a valueClick handler.
|
HandlerRegistration |
addZoomChangedHandler(ZoomChangedHandler handler)
Add a zoomChanged handler.
|
static void |
changeAutoChildDefaults(java.lang.String autoChildName,
Canvas defaults)
Changes the defaults for Canvas AutoChildren named
autoChildName . |
static void |
changeAutoChildDefaults(java.lang.String autoChildName,
FormItem defaults)
Changes the defaults for FormItem AutoChildren named
autoChildName . |
protected JavaScriptObject |
create() |
java.lang.Boolean |
drawnValueContainsPoint(DrawnValue drawnValue)
Returns whether a given
DrawnValue contains a point. |
java.lang.Boolean |
drawnValueContainsPoint(DrawnValue drawnValue,
java.lang.Integer x) |
java.lang.Boolean |
drawnValueContainsPoint(DrawnValue drawnValue,
java.lang.Integer x,
java.lang.Integer y)
Returns whether a given
DrawnValue contains a point. |
boolean |
getAllowBubbleGradients()
Setting this flag to
false prevents the chart from drawing fill gradients into the bubbles of each data
point. |
ChartType[] |
getAllowedChartTypes()
Other
chart types that the end user will be allowed to switch to, using the
built-in context menu. |
java.lang.Boolean |
getAutoRotateLabels()
Deprecated.
As of Smart GWT 9.0 this property is replaced by the property
rotateLabels . Setting rotateLabels to "auto" is
equivalent to setting autoRotateLabels to true . Setting rotateLabels to "never" is equivalent to setting
autoRotateLabels to false . |
boolean |
getAutoSortBubblePoints()
Whether to draw data points in order of descending
point size so that small values are less likely to be
completely occluded by larger values. |
java.lang.Double |
getAxisStartValue()
Start value for the primary axis of the chart.
|
DrawRect |
getBackgroundBandProperties()
Properties for background band
|
java.lang.Boolean |
getBandedBackground()
Whether to show alternating color bands in the background of chart.
|
java.lang.Boolean |
getBandedStandardDeviations()
Whether to show color bands between the
standard deviation lines. |
int |
getBarMargin()
Distance between bars.
|
DrawRect |
getBarProperties()
Properties for bar
|
int |
getBubbleHoverMaxDistance()
Maximum distance from the *outer radius* of the nearest bubble when hover will be shown.
|
DrawItem |
getBubbleProperties()
Properties for the shapes displayed around the data points (for example, in a bubble chart).
|
java.lang.Boolean |
getCanMoveAxes()
Whether the positions of value axes can be changed.
|
java.lang.Boolean |
getCanZoom()
Enables "zooming" on the X axis, specifically, only a portion of the overall dataset is shown in the main chart, and a
second smaller chart appears with slider controls
allowing a range to be selected for display in the main chart. |
Point |
getChartCenter()
Returns the centerpoint for radar charts and pie charts.
|
float |
getChartHeight(boolean recalc)
Deprecated.
|
double |
getChartHeightAsDouble(boolean recalc)
Get the height the central chart area, where data elements appear.
|
float |
getChartLeft()
Deprecated.
|
double |
getChartLeftAsDouble()
Get the left margin of the central chart area, where data elements appear.
|
float |
getChartRadius()
Deprecated.
|
double |
getChartRadiusAsDouble()
Returns the radius for radar charts and pie charts.
|
int |
getChartRectMargin()
Margin around the main chart rect: between title and chart, between chart and axis labels, and chart rect and right edge
of chart.
|
DrawRect |
getChartRectProperties()
Properties for chart rect.
|
float |
getChartTop()
Deprecated.
|
double |
getChartTopAsDouble()
Get the top coordinate of the central chart area, where data elements appear.
|
ChartType |
getChartType()
See
ChartType for a list of known types - Column, Bar, Line, Pie, Doughnut, Area, and
Radar charts are supported. |
float |
getChartWidth(boolean recalc)
Deprecated.
|
double |
getChartWidthAsDouble(boolean recalc)
Get the width of the central chart area, where data elements appear.
|
float |
getClusterMarginRatio()
For clustered charts, ratio between margins between individual bars and margins between clusters.
|
java.lang.Float |
getColorMutePercent()
Should be set to a number between -100 and 100.
|
java.lang.String |
getColorScaleMetric()
For charts where
showDataPoints is enabled, this
property specifies an additional metric (i.e. |
RecordList |
getDataAsRecordList() |
DrawLabel |
getDataAxisLabelProperties()
Properties for labels of data axis.
|
java.lang.String |
getDataColor(int index)
Get a color from the
dataColors Array |
java.lang.String[] |
getDataColors()
An array of colors to use for a series of visual elements representing data (eg columns, bars, pie slices), any of which
may be adjacent to any other.
|
Facet |
getDataLabelFacet()
|
java.lang.String |
getDataLabelHoverHTML(FacetValue facetValue)
Called when the mouse hovers over a data label, that is, a text label showing values from the first facet.
|
DrawLabel |
getDataLabelProperties()
Properties for data label
|
DrawLine |
getDataLineProperties()
Properties for lines that show data (as opposed to gradations or borders around the data area).
|
DataLineType |
getDataLineType()
How to draw lines between adjacent data points in Line and Scatter charts.
|
int |
getDataMargin()
For rectangular charts (bar, column, line), margin around the inside of the main chart area, so that data elements are
not flush to edge.
|
DrawItem |
getDataOutlineProperties()
Properties for lines that outline a data shape (in filled charts such as area or radar charts).
|
DrawItem |
getDataPointProperties()
Common properties to apply for all data points (see
showDataPoints ). |
int |
getDataPointSize()
Size in pixels for data points drawn for line, area, radar and other chart types.
|
DrawPath |
getDataShapeProperties()
Properties for data shapes (filled areas in area or radar charts).
|
int |
getDecimalPrecision()
Default precision used when formatting float numbers for axis labels
|
java.lang.Boolean |
getDiscontinuousLines()
Whether to treat non-numeric values in the dataset as indicating a break in the data line.
|
DrawOval |
getDoughnutHoleProperties()
Properties for doughnut hole
|
float |
getDoughnutRatio()
If showing a doughnut hole (see
showDoughnut ),
ratio of the size of the doughnut hole to the size of the overall pie chart, as a number between 0 to 1. |
DrawnValue |
getDrawnValue(FacetValueMap facetValues)
Returns rendering information for the data value specified by the passed facet values.
|
DrawnValue |
getDrawnValueAtPoint()
Returns a
DrawnValue object for the data value that is shown nearest to the
passed coordinates only if it's under the given coordinates, or under the current mouse event coordinates if no
coordinates are passed. |
DrawnValue |
getDrawnValueAtPoint(java.lang.Integer x) |
DrawnValue |
getDrawnValueAtPoint(java.lang.Integer x,
java.lang.Integer y) |
DrawnValue |
getDrawnValueAtPoint(java.lang.Integer x,
java.lang.Integer y,
java.lang.String metric)
Returns a
DrawnValue object for the data value that is shown nearest to the
passed coordinates only if it's under the given coordinates, or under the current mouse event coordinates if no
coordinates are passed. |
DrawnValue[] |
getDrawnValues()
Returns rendering information for the data values specified by the passed facet values.
|
DrawnValue[] |
getDrawnValues(FacetValueMap facetValues)
Returns rendering information for the data values specified by the passed facet values.
|
DrawnValue[] |
getDrawnValuesAtPoint()
Returns an array of
DrawnValue objects for the data values of each metric that
are shown nearest to the passed coordinates, but only if they're under the given coordinates, or under the current mouse
event coordinates if no coordinates are passed. |
DrawnValue[] |
getDrawnValuesAtPoint(java.lang.Integer x) |
DrawnValue[] |
getDrawnValuesAtPoint(java.lang.Integer x,
java.lang.Integer y)
Returns an array of
DrawnValue objects for the data values of each metric that
are shown nearest to the passed coordinates, but only if they're under the given coordinates, or under the current mouse
event coordinates if no coordinates are passed. |
java.lang.String |
getEditProxyConstructor()
Default class used to construct the
EditProxy for this component when the component is
first placed into edit mode . |
float |
getErrorBarColorMutePercent()
This property helps specify the color of the error bars and its value must be a number between -100 and 100.
|
int |
getErrorBarWidth()
Width of the horizontal line of the "T"-shape portion of the error bar).
|
DrawLine |
getErrorLineProperties()
Properties of the lines used to draw error bars (short, horizontal lines at the low and high metric values, and a
vertical connecting line).
|
DrawItem |
getExpectedValueLineProperties()
Properties for the
line drawn at the mean
value . |
java.lang.String[] |
getExtraAxisMetrics()
Defines the set of metrics that will be plotted as additional vertical axes.
|
MetricSettings[] |
getExtraAxisSettings()
For charts will multiple vertical axes, optionally provides settings for how each
extra axis metric is plotted. |
Facet |
getFacet(java.lang.String facetId)
Get a facet definition by facetId.
|
Facet[] |
getFacets()
An Array of facets, exactly analogous to
facets , except
that: the "inlinedValues" property can be set on a facet to change data representation as described under
data. |
Facet |
getFacetsAsFacet()
An Array of facets, exactly analogous to
facets , except
that: the "inlinedValues" property can be set on a facet to change data representation as described under
data. |
FacetValue |
getFacetValue(java.lang.String facetId,
java.lang.String facetValueId)
Get facet value definition by facetId and facetValueId.
|
java.lang.Boolean |
getFilled()
Whether shapes are filled, for example, whether a multi-series line chart appears as a stack of filled regions as
opposed to just multiple lines.
|
DrawLabel |
getGradationLabelProperties()
Properties for gradation labels
|
DrawLine |
getGradationLineProperties()
Properties for gradation lines
|
float[] |
getGradations()
Return an array of the gradation values used in the current chart.
|
int |
getGradationTickMarkLength()
Length of the tick marks used to denote the gradations of any
extra value axes . |
DrawLine |
getGradationZeroLineProperties()
Properties for the gradation line drawn for zero (slightly thicker by default).
|
java.lang.String |
getHighErrorMetric()
See
lowErrorMetric . |
int |
getHoverLabelPadding()
An extra amount of padding to show around the
hoverLabel when showValueOnHover is enabled. |
DrawLabel |
getHoverLabelProperties()
Properties for text in a floating label that represents the data value shown whenever the mouse moves withing the main
chart area when
showValueOnHover is enabled. |
DrawRect |
getHoverRectProperties()
Properties for rectangle that draws behind of a floating hover label that represents the data value.
|
LabelCollapseMode |
getLabelCollapseMode()
What to do when there are too many data points to be able to show labels for every data point at the current chart size
- see
LabelCollapseMode . |
Facet |
getLegendFacet()
|
java.lang.String |
getLegendHoverHTML(FacetValue facetValue,
FacetValue metricFacetValue)
Called when the mouse hovers over a color swatch or its label in the legend area of the chart.
|
int |
getLegendItemPadding()
Padding between each swatch and label pair.
|
DrawLabel |
getLegendLabelProperties()
Properties for labels shown next to legend color swatches.
|
int |
getLegendMargin()
Space between the legend and the chart rect or axis labels (whatever the legend is adjacent to.
|
int |
getLegendPadding()
Padding around the legend as a whole.
|
DrawRect |
getLegendRectProperties()
Properties for rectangle around the legend as a whole.
|
DrawRect |
getLegendSwatchProperties()
Properties for the swatches of color shown in the legend.
|
int |
getLegendSwatchSize()
Size of individual color swatches in legend.
|
int |
getLegendTextPadding()
Padding between color swatch and its label.
|
int |
getLogBase()
When
useLogGradations , base value for
logarithmic gradation lines. |
float[] |
getLogGradations()
When
useLogGradations is set, gradation lines
to show in between powers,
expressed as a series of integer or float values between 1 and logBase . |
com.smartgwt.logicalstructure.core.LogicalStructureObject |
getLogicalStructure()
Getter implementing the
LogicalStructure interface,
which supports Eclipse's logical structure debugging facility. |
java.lang.Boolean |
getLogScale()
Whether to use logarithmic scaling for values.
|
boolean |
getLogScalePointColor()
Whether to use logarithmic scaling for the
color
scale of the data points. |
boolean |
getLogScalePointSize()
Whether to use logarithmic scaling for the
data
point sizes . |
java.lang.String |
getLowErrorMetric()
lowErrorMetric and highErrorMetric
can be used to cause error bars to appear above and below the main data point. |
java.lang.Float |
getMax(FacetValueMap criteria)
Calculate the maximum of the data from a single metric.
|
java.lang.Float |
getMax(java.lang.String criteria)
Calculate the maximum of the data from a single metric.
|
int |
getMaxBarThickness()
Bars will not be drawn over this thickness, instead, margins will be increased.
|
double |
getMaxDataPointSize()
The maximum allowed data point size when controlled by
pointSizeMetric . |
java.lang.Float |
getMean(FacetValueMap criteria)
Calculate the mean, or expected value, of the data over a single metric.
|
java.lang.Float |
getMean(java.lang.String criteria)
Calculate the mean, or expected value, of the data over a single metric.
|
java.lang.Float |
getMedian(FacetValueMap criteria)
Calculate the median of the data over a single metric.
|
java.lang.Float |
getMedian(java.lang.String criteria)
Calculate the median of the data over a single metric.
|
java.lang.Float |
getMin(FacetValueMap criteria)
Calculate the minimum of the data from a single metric.
|
java.lang.Float |
getMin(java.lang.String criteria)
Calculate the minimum of the data from a single metric.
|
int |
getMinBarThickness()
If bars would be smaller than this size, margins are reduced until bars overlap.
|
double |
getMinDataPointSize()
The minimum allowed data point size when controlled by
pointSizeMetric . |
int |
getMinDataSpreadPercent()
If all data values would be spread across less than
minDataSpreadPercent of the axis, the start values
of axes will be automatically adjusted to make better use of space. |
java.lang.Integer |
getMinLabelGap()
Minimum gap between labels on the X axis before some labels are omitted or larger time granularity is shown (eg show
days instead of hours) based on the
labelCollapseMode . |
int |
getMinXDataSpreadPercent()
For scatter charts only, if all data points would be spread across less than
minXDataSpreadPercent of the x-axis, the start
value of x-axis will be automatically adjusted to make better use of space. |
DrawnValue |
getNearestDrawnValue()
Returns rendering information for the data value that is shown nearest to the passed coordinates, as a
DrawnValue object. |
DrawnValue |
getNearestDrawnValue(java.lang.Integer x) |
DrawnValue |
getNearestDrawnValue(java.lang.Integer x,
java.lang.Integer y) |
DrawnValue |
getNearestDrawnValue(java.lang.Integer x,
java.lang.Integer y,
java.lang.String metric)
Returns rendering information for the data value that is shown nearest to the passed coordinates, as a
DrawnValue object. |
DrawnValue[] |
getNearestDrawnValues()
Returns an array of
DrawnValue objects containing rendering information for
the data values having each metric that are shown nearest to the passed coordinates. |
DrawnValue[] |
getNearestDrawnValues(java.lang.Integer x) |
DrawnValue[] |
getNearestDrawnValues(java.lang.Integer x,
java.lang.Integer y)
Returns an array of
DrawnValue objects containing rendering information for
the data values having each metric that are shown nearest to the passed coordinates. |
java.lang.Integer |
getNumDataPoints()
Count the number of data points.
|
java.lang.Integer |
getNumDataPoints(FacetValueMap criteria)
Count the number of data points.
|
static FacetChart |
getOrCreateRef(JavaScriptObject jsObj) |
boolean |
getPadChartRectByCornerRadius()
If
showChartRect is enabled and if chartRectProperties specifies a nonzero rounding , whether the padding around the inside of the chart
rect. |
java.lang.Float |
getPercentile(FacetValueMap criteria,
float percentile)
Calculate a percentile of the data over a single metric.
|
java.lang.Float |
getPercentile(java.lang.String criteria,
float percentile)
Calculate a percentile of the data over a single metric.
|
DrawOval |
getPieBorderProperties()
Properties for the border around a pie chart.
|
int |
getPieLabelAngleStart()
Angle where first label is placed in a Pie chart in stacked mode, in degrees.
|
int |
getPieLabelLineExtent()
How far label lines stick out of the pie radius in a Pie chart in stacked mode.
|
DrawLine |
getPieLabelLineProperties()
Properties for pie label line
|
DrawOval |
getPieRingBorderProperties()
Properties for pie ring border
|
DrawSector |
getPieSliceProperties()
Properties for pie slices
|
java.lang.Integer |
getPieStartAngle()
Default angle in degrees where pie charts start drawing sectors to represent data values.
|
java.lang.Integer |
getPointColorLogBase()
When
logScalePointColor is true ,
this property specifies the base value for logarithmic color scale metric values. |
PointShape[] |
getPointShapes()
For charts where
showDataPoints is enabled, this
property specifies an array of geometric shapes to draw for the data points of each series. |
java.lang.Integer |
getPointSizeGradations()
When a
point size legend is shown, this
property controls the number of gradations of the pointSizeMetric that the chart tries to display. |
java.lang.Integer |
getPointSizeLogBase()
When
logScalePointSize is true, base value for
logarithmic point size metric values. |
float[] |
getPointSizeLogGradations()
When
usePointSizeLogGradations is set,
this property specifies the pointSizeMetric
value gradations to show in the point size
legend in between powers, expressed as a series of integer or float values between 1 and pointSizeLogBase . |
java.lang.String |
getPointSizeMetric()
For charts where
showDataPoints is enabled, this
property specifies an additional metric (i.e. |
void |
getPolynomialRegressionFunction()
For scatter plots only, get a Function from the specified independent variable X to the specified dependent variable Y
that defines the polynomial that best fits the data.
|
void |
getPolynomialRegressionFunction(java.lang.Integer degree) |
void |
getPolynomialRegressionFunction(java.lang.Integer degree,
java.lang.String xMetric) |
void |
getPolynomialRegressionFunction(java.lang.Integer degree,
java.lang.String xMetric,
java.lang.String yMetric)
For scatter plots only, get a Function from the specified independent variable X to the specified dependent variable Y
that defines the polynomial that best fits the data.
|
java.lang.String |
getPrintHTML(PrintProperties printProperties,
PrintHTMLCallback callback)
Retrieves printable HTML for this component and all printable subcomponents.
|
boolean |
getPrintZoomChart()
Should the
zoom chart be printed with this
FacetChart ? If true , then the SVG string returned by DrawPane.getSvgString() will include the zoom chart's SVG as
well. |
java.lang.String |
getProbabilityMetric()
The "id" of the metric facet value that assigns a probability to each combination of facets and their values.
|
java.lang.Boolean |
getProportional()
For multi-facet charts, render data values as a proportion of the sum of all data values that have the same label.
|
java.lang.String |
getProportionalAxisLabel()
Default title for the value axis label when the chart is in
proportional rendering mode . |
DrawOval |
getRadarBackgroundProperties()
Properties for radar background
|
int |
getRadialLabelOffset()
Distance in pixels that radial labels are offset from the outside of the circle.
|
java.lang.Float |
getRange(FacetValueMap criteria)
Calculate the range of the data from a single metric.
|
java.lang.Float |
getRange(java.lang.String criteria)
Calculate the range of the data from a single metric.
|
Record[] |
getRecords() |
DrawLine |
getRegressionLineProperties()
Properties for the
regression line . |
RegressionLineType |
getRegressionLineType()
Regression algorithm used for the
regression
line . |
int |
getRegressionPolynomialDegree()
For scatter plots only, specify the degree of polynomial to use for any polynomial regression that is calculated.
|
LabelRotationMode |
getRotateLabels()
This property controls whether to rotate the labels on the X-axis.
|
java.lang.String |
getScaleEndColor()
The ending color of the color scale when the data points are colored according to a
color scale metric . |
java.lang.String |
getScaleStartColor()
The starting color of the color scale when the data points are colored according to a
color scale metric . |
DrawOval |
getShadowProperties()
Properties for shadows.
|
boolean |
getShowBubbleLegendPerShape()
Whether to draw multiple bubble legends horizontally stacked to the right of the chart, one per shape type.
|
java.lang.Boolean |
getShowChartRect()
Whether to show a rectangular shape around the area of the chart where data is plotted.
|
java.lang.Boolean |
getShowColorScaleLegend()
Whether to show an additional legend underneath the chart to indicate color values.
|
java.lang.Boolean |
getShowDataAxisLabel()
Whether to show a label for the data axis as a whole (the data axis is where labels for each data point appear).
|
boolean |
getShowDataLabels()
If set to
false , data labels for values are entirely omitted. |
java.lang.Boolean |
getShowDataPoints()
For Line, Area, Radar, Scatter or Bubble charts, whether to show data points for each individual data value.
|
boolean |
getShowDataValues()
Should data values be shown as text labels near the shape representing the value, for example, above columns of a column
chart, or adjacent to points in a line chart?
|
java.lang.Boolean |
getShowDoughnut()
Whether to show a "doughnut hole" in the middle of pie charts.
|
java.lang.Boolean |
getShowExpectedValueLine()
Display a line at the
mean value . |
java.lang.Boolean |
getShowGradationsOverData()
If set, gradation lines are drawn on top of data rather than underneath.
|
java.lang.Boolean |
getShowInlineLabels()
Causes labels for the X axis to be shown above the axis and to the right of the gradation line they label, making for a
vertically more compact chart at the risk of gradation labels being partially obscured by data values.
|
java.lang.Boolean |
getShowLegend()
The legend is automatically shown for charts that need it (generally, multi-series charts) but can be forced off by
setting showLegend to false.
|
java.lang.Boolean |
getShowPointSizeLegend()
Whether to show an additional legend to the right of the chart to indicate
point size . |
java.lang.Boolean |
getShowRadarGradationLabels()
Whether to show gradation labels in radar charts.
|
java.lang.Boolean |
getShowRegressionLine()
For scatter plots only, whether to display a regression curve that best fits the data of the two metric facet values.
|
java.lang.Boolean |
getShowScatterLines()
Whether to draw lines between adjacent data points in "Scatter" plots.
|
java.lang.Boolean |
getShowShadows()
Whether to automatically show shadows for various charts.
|
java.lang.Boolean |
getShowStandardDeviationLines()
Display multiple
standard deviations away from the mean
as lines. |
java.lang.Boolean |
getShowStatisticsOverData()
If set, the
mean line , standard deviation lines , standard deviation bands , and regression curves are drawn on top of the data
rather than underneath. |
java.lang.Boolean |
getShowTitle()
Whether to show a title.
|
java.lang.Boolean |
getShowValueAxisLabel()
Whether to show the
valueTitle (or, in the case of
proportional rendering mode , the proportionalAxisLabel ) as a label on the value
axis. |
java.lang.Boolean |
getShowValueOnHover()
Shows the value of the nearest data value in a floating label whenever the mouse moves within the main chart area.
|
void |
getSimpleLinearRegressionFunction()
For scatter plots only, get a Function from the specified independent variable X to the specified dependent variable Y
that defines the line that best fits the data.
|
void |
getSimpleLinearRegressionFunction(java.lang.String xMetric) |
void |
getSimpleLinearRegressionFunction(java.lang.String xMetric,
java.lang.String yMetric)
For scatter plots only, get a Function from the specified independent variable X to the specified dependent variable Y
that defines the line that best fits the data.
|
java.lang.Boolean |
getStacked()
Whether to use stacking for charts where this makes sense (column, area, pie, line and radar charts).
|
DrawItem[] |
getStandardDeviationBandProperties()
An Array of DrawRect properties to specify the bands between the
standard deviation lines . |
DrawItem |
getStandardDeviationLineProperties()
Properties for the
standard deviation
lines . |
float[] |
getStandardDeviations()
When
showStandardDeviationLines is
set, the number of standard deviation lines drawn
and their respective standard deviation away from the mean are specified by this property. |
java.lang.Float |
getStdDev(FacetValueMap criteria,
boolean population)
Calculate the standard deviation of the data from a single metric.
|
java.lang.Float |
getStdDev(java.lang.String criteria,
boolean population)
Calculate the standard deviation of the data from a single metric.
|
java.lang.String |
getStyleName()
Default styleName for the chart.
|
int |
getTickMarkToValueAxisMargin()
Margin between the tick marks and the labels of the
extra value axes . |
java.lang.String |
getTitle()
Title for the chart as a whole.
|
DrawLabel |
getTitleProperties()
Properties for title label.
|
java.lang.Boolean |
getUseAutoGradients()
Causes the chart to use the colors specified in
dataColors but specify chart-specific gradients based on the primary data color per chart type. |
java.lang.Boolean |
getUseLogGradations()
Whether to use classic logarithmic gradations, where each order of magnitude is shown as a gradation as well as a few
intervening lines.
|
java.lang.Boolean |
getUseMultiplePointShapes()
Whether the chart should use multiple shapes to show data points.
|
java.lang.Boolean |
getUsePointSizeLogGradations()
Whether to use classic logarithmic gradations, where each order of magnitude is shown as a gradation as well as a few
intervening values, for the
pointSizeMetric
values displayed in the point size legend . |
java.lang.Boolean |
getUseSymmetricStandardDeviations()
Whether to display both the positive and negative of the
standard deviations . |
DrawLabel |
getValueAxisLabelProperties()
Properties for labels of value axis.
|
int |
getValueAxisMargin()
Margin between
multiple value axes . |
DrawLine |
getValueLineProperties()
Properties for a "value line" - a line shows where a particular discrete value is placed, eg, vertical lines connecting
points of a line chart to the X axis, or radial lines in a Radar chart.
|
java.lang.String |
getValueProperty()
Property in each record that holds a data value.
|
java.lang.String |
getValueTitle()
A label for the data values, such as "Sales in Thousands", typically used as the label for the value axis.
|
java.lang.Float |
getVariance(FacetValueMap criteria,
boolean population)
Calculate the variance of the data from a single metric.
|
java.lang.Float |
getVariance(java.lang.String criteria,
boolean population)
Calculate the variance of the data from a single metric.
|
java.lang.String |
getXAxisMetric()
For scatter charts only, the "id" of the metric facet value to use for the x-axis.
|
java.lang.Double |
getXAxisStartValue()
For Bubble and Scatter charts only, the start value for the x-axis.
|
float |
getXCoord(FacetValueMap criteria)
Returns the X coordination where the passed data value would be drawn.
|
float |
getXCoord(float value)
Returns the X coordination where the passed data value would be drawn.
|
java.lang.String |
getYAxisMetric()
For scatter charts only, the "id" of the metric facet value to use for the y-axis.
|
float |
getYCoord(FacetValueMap criteria)
Returns the Y coordination where the passed data value would be drawn.
|
float |
getYCoord(float value)
Returns the Y coordination where the passed data value would be drawn.
|
FacetChart |
getZoomChart()
Mini-chart created to allow zooming when
canZoom is
enabled. |
double |
getZoomChartHeight()
Height of the
zoomChart . |
FacetChart |
getZoomChartProperties()
Properties to further configure the
zoomChart . |
RangeSlider |
getZoomChartSlider()
Slider controls shown on the mini-chart which is created when
canZoom is enabled. |
java.lang.Object |
getZoomEndValue()
For a
zoomed chart , end value of the data range shown in
the main chart. |
java.lang.Boolean |
getZoomLogScale()
|
float |
getZoomMutePercent()
colorMutePercent to use for the zoomChart . |
FacetChart |
getZoomSelectionChart()
Mini-chart created when
canZoom is enabled. |
FacetChart |
getZoomSelectionChartProperties()
Properties to further configure the
zoomSelectionChart . |
java.lang.Boolean |
getZoomShowSelection()
Whether the selected range should be shown in a different style, which can be configured via
zoomSelectionChartProperties . |
ZoomStartPosition |
getZoomStartPosition()
For a
zoomed chart , determines what portion of the
overall dataset should be initially shown in the main chart. |
java.lang.Object |
getZoomStartValue()
For a
zoomed chart , start value of the data range shown
in the main chart. |
void |
setAllowBubbleGradients(boolean allowBubbleGradients)
Setting this flag to
false prevents the chart from drawing fill gradients into the bubbles of each data
point. |
void |
setAllowedChartTypes(ChartType... allowedChartTypes)
Other
chart types that the end user will be allowed to switch to, using the
built-in context menu. |
void |
setAutoRotateLabels(java.lang.Boolean autoRotateLabels)
Deprecated.
As of Smart GWT 9.0 this property is replaced by the property
rotateLabels . Setting rotateLabels to "auto" is
equivalent to setting autoRotateLabels to true . Setting rotateLabels to "never" is equivalent to setting
autoRotateLabels to false . |
void |
setAutoSortBubblePoints(boolean autoSortBubblePoints)
Whether to draw data points in order of descending
point size so that small values are less likely to be
completely occluded by larger values. |
void |
setAxisStartValue(java.lang.Double axisStartValue)
Start value for the primary axis of the chart.
|
void |
setAxisValueFormatter(ValueFormatter formatter)
Formatter to apply to values displayed in the gradation labels.
|
void |
setBackgroundBandProperties(DrawRect backgroundBandProperties)
Properties for background band
|
void |
setBandedBackground(java.lang.Boolean bandedBackground)
Whether to show alternating color bands in the background of chart.
|
void |
setBandedStandardDeviations(java.lang.Boolean bandedStandardDeviations)
Whether to show color bands between the
standard deviation lines. |
void |
setBarMargin(int barMargin)
Distance between bars.
|
void |
setBarProperties(DrawRect barProperties)
Properties for bar
|
void |
setBubbleHoverMaxDistance(int bubbleHoverMaxDistance)
Maximum distance from the *outer radius* of the nearest bubble when hover will be shown.
|
void |
setBubbleProperties(DrawItem bubbleProperties)
Properties for the shapes displayed around the data points (for example, in a bubble chart).
|
void |
setCanMoveAxes(java.lang.Boolean canMoveAxes)
Whether the positions of value axes can be changed.
|
void |
setCanZoom(java.lang.Boolean canZoom)
Enables "zooming" on the X axis, specifically, only a portion of the overall dataset is shown in the main chart, and a
second smaller chart appears with slider controls
allowing a range to be selected for display in the main chart. |
void |
setChartRectMargin(int chartRectMargin)
Margin around the main chart rect: between title and chart, between chart and axis labels, and chart rect and right edge
of chart.
|
void |
setChartRectProperties(DrawRect chartRectProperties)
Properties for chart rect.
|
void |
setChartType(ChartType chartType)
See
ChartType for a list of known types - Column, Bar, Line, Pie, Doughnut, Area, and
Radar charts are supported. |
void |
setClusterMarginRatio(float clusterMarginRatio)
For clustered charts, ratio between margins between individual bars and margins between clusters.
|
void |
setColorMutePercent(java.lang.Float colorMutePercent)
Should be set to a number between -100 and 100.
|
void |
setColorScaleMetric(java.lang.String colorScaleMetric)
For charts where
showDataPoints is enabled, this
property specifies an additional metric (i.e. |
void |
setData(Record[] records)
Dataset for this chart.
|
void |
setData(RecordList records) |
void |
setDataAxisLabelProperties(DrawLabel dataAxisLabelProperties)
Properties for labels of data axis.
|
void |
setDataColors(java.lang.String... dataColors)
An array of colors to use for a series of visual elements representing data (eg columns, bars, pie slices), any of which
may be adjacent to any other.
|
void |
setDataLabelHoverHTMLCustomizer(DataLabelHoverCustomizer dataLabelHoverHTMLCustomizer)
Called when the mouse hovers over a data label, that is, a text label showing values from
the first facet.
|
void |
setDataLabelProperties(DrawLabel dataLabelProperties)
Properties for data label
|
void |
setDataLineProperties(DrawLine dataLineProperties)
Properties for lines that show data (as opposed to gradations or borders around the data area).
|
void |
setDataLineType(DataLineType dataLineType)
How to draw lines between adjacent data points in Line and Scatter charts.
|
void |
setDataMargin(int dataMargin)
For rectangular charts (bar, column, line), margin around the inside of the main chart area, so that data elements are
not flush to edge.
|
void |
setDataOutlineProperties(DrawItem dataOutlineProperties)
Properties for lines that outline a data shape (in filled charts such as area or radar charts).
|
void |
setDataPointProperties(DrawItem dataPointProperties)
Common properties to apply for all data points (see
showDataPoints ). |
void |
setDataPointSize(int dataPointSize)
Size in pixels for data points drawn for line, area, radar and other chart types.
|
void |
setDataShapeProperties(DrawPath dataShapeProperties)
Properties for data shapes (filled areas in area or radar charts).
|
void |
setDataValueFormatter(ValueFormatter formatter)
Formatter to apply to values displayed in the hover labels and other value labels
|
void |
setDecimalPrecision(int decimalPrecision)
Default precision used when formatting float numbers for axis labels
|
static void |
setDefaultProperties(FacetChart facetChartProperties)
Class level method to set the default properties of this class.
|
void |
setDiscontinuousLines(java.lang.Boolean discontinuousLines)
Whether to treat non-numeric values in the dataset as indicating a break in the data line.
|
void |
setDoughnutHoleProperties(DrawOval doughnutHoleProperties)
Properties for doughnut hole
|
void |
setDoughnutRatio(float doughnutRatio)
If showing a doughnut hole (see
showDoughnut ),
ratio of the size of the doughnut hole to the size of the overall pie chart, as a number between 0 to 1. |
void |
setEditProxyConstructor(java.lang.String editProxyConstructor)
Default class used to construct the
EditProxy for this component when the component is
first placed into edit mode . |
void |
setErrorBarColorMutePercent(float errorBarColorMutePercent)
This property helps specify the color of the error bars and its value must be a number between -100 and 100.
|
void |
setErrorBarWidth(int errorBarWidth)
Width of the horizontal line of the "T"-shape portion of the error bar).
|
void |
setErrorLineProperties(DrawLine errorLineProperties)
Properties of the lines used to draw error bars (short, horizontal lines at the low and high metric values, and a
vertical connecting line).
|
void |
setExpectedValueLineProperties(DrawItem expectedValueLineProperties)
Properties for the
line drawn at the mean
value . |
void |
setExtraAxisMetrics(java.lang.String... extraAxisMetrics)
Defines the set of metrics that will be plotted as additional vertical axes.
|
void |
setExtraAxisSettings(MetricSettings... extraAxisSettings)
For charts will multiple vertical axes, optionally provides settings for how each
extra axis metric is plotted. |
void |
setFacets(Facet... facets)
An Array of facets, exactly analogous to
facets , except
that: the "inlinedValues" property can be set on a facet to change data representation as described under
data. |
void |
setFacets(Facet facets)
An Array of facets, exactly analogous to
facets , except
that: the "inlinedValues" property can be set on a facet to change data representation as described under
data. |
void |
setFilled(java.lang.Boolean filled)
Whether shapes are filled, for example, whether a multi-series line chart appears as a stack of filled regions as
opposed to just multiple lines.
|
void |
setGradationLabelProperties(DrawLabel gradationLabelProperties)
Properties for gradation labels
|
void |
setGradationLineProperties(DrawLine gradationLineProperties)
Properties for gradation lines
|
void |
setGradationTickMarkLength(int gradationTickMarkLength)
Length of the tick marks used to denote the gradations of any
extra value axes . |
void |
setGradationZeroLineProperties(DrawLine gradationZeroLineProperties)
Properties for the gradation line drawn for zero (slightly thicker by default).
|
void |
setHighErrorMetric(java.lang.String highErrorMetric)
See
lowErrorMetric . |
void |
setHoverLabelPadding(int hoverLabelPadding)
An extra amount of padding to show around the
hoverLabel when showValueOnHover is enabled. |
void |
setHoverLabelProperties(DrawLabel hoverLabelProperties)
Properties for text in a floating label that represents the data value shown whenever the mouse moves withing the main
chart area when
showValueOnHover is enabled. |
void |
setHoverRectProperties(DrawRect hoverRectProperties)
Properties for rectangle that draws behind of a floating hover label that represents the data value.
|
void |
setLabelCollapseMode(LabelCollapseMode labelCollapseMode)
What to do when there are too many data points to be able to show labels for every data point at the current chart size
- see
LabelCollapseMode . |
void |
setLegendHoverCustomizer(LegendHoverCustomizer legendHoverHTMLCustomizer)
Called when the mouse hovers over a color swatch or its label in the legend area of the
chart.
|
void |
setLegendItemPadding(int legendItemPadding)
Padding between each swatch and label pair.
|
void |
setLegendLabelProperties(DrawLabel legendLabelProperties)
Properties for labels shown next to legend color swatches.
|
void |
setLegendMargin(int legendMargin)
Space between the legend and the chart rect or axis labels (whatever the legend is adjacent to.
|
void |
setLegendPadding(int legendPadding)
Padding around the legend as a whole.
|
void |
setLegendRectProperties(DrawRect legendRectProperties)
Properties for rectangle around the legend as a whole.
|
void |
setLegendSwatchProperties(DrawRect legendSwatchProperties)
Properties for the swatches of color shown in the legend.
|
void |
setLegendSwatchSize(int legendSwatchSize)
Size of individual color swatches in legend.
|
void |
setLegendTextPadding(int legendTextPadding)
Padding between color swatch and its label.
|
void |
setLogBase(int logBase)
When
useLogGradations , base value for
logarithmic gradation lines. |
void |
setLogGradations(float... logGradations)
When
useLogGradations is set, gradation lines
to show in between powers,
expressed as a series of integer or float values between 1 and logBase . |
com.smartgwt.logicalstructure.core.LogicalStructureObject |
setLogicalStructure(com.smartgwt.logicalstructure.widgets.chart.FacetChartLogicalStructure s)
Setter implementing the
LogicalStructure interface,
which supports Eclipse's logical structure debugging facility. |
void |
setLogScale(java.lang.Boolean logScale)
Whether to use logarithmic scaling for values.
|
void |
setLogScalePointColor(boolean logScalePointColor)
Whether to use logarithmic scaling for the
color
scale of the data points. |
void |
setLogScalePointSize(boolean logScalePointSize)
Whether to use logarithmic scaling for the
data
point sizes . |
void |
setLowErrorMetric(java.lang.String lowErrorMetric)
lowErrorMetric and highErrorMetric
can be used to cause error bars to appear above and below the main data point. |
void |
setMaxBarThickness(int maxBarThickness)
Bars will not be drawn over this thickness, instead, margins will be increased.
|
void |
setMaxDataPointSize(double maxDataPointSize)
The maximum allowed data point size when controlled by
pointSizeMetric . |
void |
setMinBarThickness(int minBarThickness)
If bars would be smaller than this size, margins are reduced until bars overlap.
|
void |
setMinDataPointSize(double minDataPointSize)
The minimum allowed data point size when controlled by
pointSizeMetric . |
void |
setMinDataSpreadPercent(int minDataSpreadPercent)
If all data values would be spread across less than
minDataSpreadPercent of the axis, the start values
of axes will be automatically adjusted to make better use of space. |
void |
setMinLabelGap(java.lang.Integer minLabelGap)
Minimum gap between labels on the X axis before some labels are omitted or larger time granularity is shown (eg show
days instead of hours) based on the
labelCollapseMode . |
void |
setMinXDataSpreadPercent(int minXDataSpreadPercent)
For scatter charts only, if all data points would be spread across less than
minXDataSpreadPercent of the x-axis, the start
value of x-axis will be automatically adjusted to make better use of space. |
void |
setPadChartRectByCornerRadius(boolean padChartRectByCornerRadius)
If
showChartRect is enabled and if chartRectProperties specifies a nonzero rounding , whether the padding around the inside of the chart
rect. |
void |
setPieBorderProperties(DrawOval pieBorderProperties)
Properties for the border around a pie chart.
|
void |
setPieLabelAngleStart(int pieLabelAngleStart)
Angle where first label is placed in a Pie chart in stacked mode, in degrees.
|
void |
setPieLabelLineExtent(int pieLabelLineExtent)
How far label lines stick out of the pie radius in a Pie chart in stacked mode.
|
void |
setPieLabelLineProperties(DrawLine pieLabelLineProperties)
Properties for pie label line
|
void |
setPieRingBorderProperties(DrawOval pieRingBorderProperties)
Properties for pie ring border
|
void |
setPieSliceProperties(DrawSector pieSliceProperties)
Properties for pie slices
|
void |
setPieStartAngle(java.lang.Integer pieStartAngle)
Default angle in degrees where pie charts start drawing sectors to represent data values.
|
void |
setPointClickHandler(ChartPointClickHandler handler)
Apply a handler to fire when
showDataPoints is true,
and the user clicks on a point. |
void |
setPointColorLogBase(java.lang.Integer pointColorLogBase)
When
logScalePointColor is true ,
this property specifies the base value for logarithmic color scale metric values. |
void |
setPointHoverCustomizer(ChartPointHoverCustomizer hoverCustomizer)
Display custom HTML when
showDataPoints is true and the mouse hovers
over a point. |
void |
setPointShapes(PointShape... pointShapes)
For charts where
showDataPoints is enabled, this
property specifies an array of geometric shapes to draw for the data points of each series. |
void |
setPointSizeGradations(java.lang.Integer pointSizeGradations)
When a
point size legend is shown, this
property controls the number of gradations of the pointSizeMetric that the chart tries to display. |
void |
setPointSizeLogBase(java.lang.Integer pointSizeLogBase)
When
logScalePointSize is true, base value for
logarithmic point size metric values. |
void |
setPointSizeLogGradations(float... pointSizeLogGradations)
When
usePointSizeLogGradations is set,
this property specifies the pointSizeMetric
value gradations to show in the point size
legend in between powers, expressed as a series of integer or float values between 1 and pointSizeLogBase . |
void |
setPointSizeMetric(java.lang.String pointSizeMetric)
For charts where
showDataPoints is enabled, this
property specifies an additional metric (i.e. |
void |
setPrintZoomChart(boolean printZoomChart)
Should the
zoom chart be printed with this
FacetChart ? If true , then the SVG string returned by DrawPane.getSvgString() will include the zoom chart's SVG as
well. |
void |
setProbabilityMetric(java.lang.String probabilityMetric)
The "id" of the metric facet value that assigns a probability to each combination of facets and their values.
|
void |
setProportional(java.lang.Boolean proportional)
For multi-facet charts, render data values as a proportion of the sum of all data values that have the same label.
|
void |
setProportionalAxisLabel(java.lang.String proportionalAxisLabel)
Default title for the value axis label when the chart is in
proportional rendering mode . |
void |
setRadarBackgroundProperties(DrawOval radarBackgroundProperties)
Properties for radar background
|
void |
setRadialLabelOffset(int radialLabelOffset)
Distance in pixels that radial labels are offset from the outside of the circle.
|
void |
setRegressionLineProperties(DrawLine regressionLineProperties)
Properties for the
regression line . |
void |
setRegressionLineType(RegressionLineType regressionLineType)
Regression algorithm used for the
regression
line . |
void |
setRegressionPolynomialDegree(int regressionPolynomialDegree)
For scatter plots only, specify the degree of polynomial to use for any polynomial regression that is calculated.
|
void |
setRotateLabels(LabelRotationMode rotateLabels)
This property controls whether to rotate the labels on the X-axis.
|
void |
setScaleEndColor(java.lang.String scaleEndColor)
The ending color of the color scale when the data points are colored according to a
color scale metric . |
void |
setScaleStartColor(java.lang.String scaleStartColor)
The starting color of the color scale when the data points are colored according to a
color scale metric . |
void |
setShadowProperties(DrawOval shadowProperties)
Properties for shadows.
|
void |
setShowBubbleLegendPerShape(boolean showBubbleLegendPerShape)
Whether to draw multiple bubble legends horizontally stacked to the right of the chart, one per shape type.
|
void |
setShowChartRect(java.lang.Boolean showChartRect)
Whether to show a rectangular shape around the area of the chart where data is plotted.
|
void |
setShowColorScaleLegend(java.lang.Boolean showColorScaleLegend)
Whether to show an additional legend underneath the chart to indicate color values.
|
void |
setShowDataAxisLabel(java.lang.Boolean showDataAxisLabel)
Whether to show a label for the data axis as a whole (the data axis is where labels for each data point appear).
|
void |
setShowDataLabels(boolean showDataLabels)
If set to
false , data labels for values are entirely omitted. |
void |
setShowDataPoints(java.lang.Boolean showDataPoints)
For Line, Area, Radar, Scatter or Bubble charts, whether to show data points for each individual data value.
|
void |
setShowDataValues(boolean showDataValues)
Should data values be shown as text labels near the shape representing the value, for example, above columns of a column
chart, or adjacent to points in a line chart?
|
void |
setShowDoughnut(java.lang.Boolean showDoughnut)
Whether to show a "doughnut hole" in the middle of pie charts.
|
void |
setShowExpectedValueLine(java.lang.Boolean showExpectedValueLine)
Display a line at the
mean value . |
void |
setShowGradationsOverData(java.lang.Boolean showGradationsOverData)
If set, gradation lines are drawn on top of data rather than underneath.
|
void |
setShowInlineLabels(java.lang.Boolean showInlineLabels)
Causes labels for the X axis to be shown above the axis and to the right of the gradation line they label, making for a
vertically more compact chart at the risk of gradation labels being partially obscured by data values.
|
void |
setShowLegend(java.lang.Boolean showLegend)
The legend is automatically shown for charts that need it (generally, multi-series charts) but can be forced off by
setting showLegend to false.
|
void |
setShowPointSizeLegend(java.lang.Boolean showPointSizeLegend)
Whether to show an additional legend to the right of the chart to indicate
point size . |
void |
setShowRadarGradationLabels(java.lang.Boolean showRadarGradationLabels)
Whether to show gradation labels in radar charts.
|
void |
setShowRegressionLine(java.lang.Boolean showRegressionLine)
For scatter plots only, whether to display a regression curve that best fits the data of the two metric facet values.
|
void |
setShowScatterLines(java.lang.Boolean showScatterLines)
Whether to draw lines between adjacent data points in "Scatter" plots.
|
void |
setShowShadows(java.lang.Boolean showShadows)
Whether to automatically show shadows for various charts.
|
void |
setShowStandardDeviationLines(java.lang.Boolean showStandardDeviationLines)
Display multiple
standard deviations away from the mean
as lines. |
void |
setShowStatisticsOverData(java.lang.Boolean showStatisticsOverData)
If set, the
mean line , standard deviation lines , standard deviation bands , and regression curves are drawn on top of the data
rather than underneath. |
void |
setShowTitle(java.lang.Boolean showTitle)
Whether to show a title.
|
void |
setShowValueAxisLabel(java.lang.Boolean showValueAxisLabel)
Whether to show the
valueTitle (or, in the case of
proportional rendering mode , the proportionalAxisLabel ) as a label on the value
axis. |
void |
setShowValueOnHover(java.lang.Boolean showValueOnHover)
Shows the value of the nearest data value in a floating label whenever the mouse moves within the main chart area.
|
void |
setStacked(java.lang.Boolean stacked)
Whether to use stacking for charts where this makes sense (column, area, pie, line and radar charts).
|
void |
setStandardDeviationBandProperties(DrawItem... standardDeviationBandProperties)
An Array of DrawRect properties to specify the bands between the
standard deviation lines . |
void |
setStandardDeviationLineProperties(DrawItem standardDeviationLineProperties)
Properties for the
standard deviation
lines . |
void |
setStandardDeviations(float... standardDeviations)
When
showStandardDeviationLines is
set, the number of standard deviation lines drawn
and their respective standard deviation away from the mean are specified by this property. |
void |
setStyleName(java.lang.String styleName)
Default styleName for the chart.
|
void |
setTickMarkToValueAxisMargin(int tickMarkToValueAxisMargin)
Margin between the tick marks and the labels of the
extra value axes . |
void |
setTitle(java.lang.String title)
Title for the chart as a whole.
|
void |
setTitleProperties(DrawLabel titleProperties)
Properties for title label.
|
void |
setUseAutoGradients(java.lang.Boolean useAutoGradients)
Causes the chart to use the colors specified in
dataColors but specify chart-specific gradients based on the primary data color per chart type. |
void |
setUseLogGradations(java.lang.Boolean useLogGradations)
Whether to use classic logarithmic gradations, where each order of magnitude is shown as a gradation as well as a few
intervening lines.
|
void |
setUseMultiplePointShapes(java.lang.Boolean useMultiplePointShapes)
Whether the chart should use multiple shapes to show data points.
|
void |
setUsePointSizeLogGradations(java.lang.Boolean usePointSizeLogGradations)
Whether to use classic logarithmic gradations, where each order of magnitude is shown as a gradation as well as a few
intervening values, for the
pointSizeMetric
values displayed in the point size legend . |
void |
setUseSymmetricStandardDeviations(java.lang.Boolean useSymmetricStandardDeviations)
Whether to display both the positive and negative of the
standard deviations . |
void |
setValueAxisLabelProperties(DrawLabel valueAxisLabelProperties)
Properties for labels of value axis.
|
void |
setValueAxisMargin(int valueAxisMargin)
Margin between
multiple value axes . |
void |
setValueLineProperties(DrawLine valueLineProperties)
Properties for a "value line" - a line shows where a particular discrete value is placed, eg, vertical lines connecting
points of a line chart to the X axis, or radial lines in a Radar chart.
|
void |
setValueProperty(java.lang.String valueProperty)
Property in each record that holds a data value.
|
void |
setValueTitle(java.lang.String valueTitle)
A label for the data values, such as "Sales in Thousands", typically used as the label for the value axis.
|
void |
setXAxisMetric(java.lang.String xAxisMetric)
For scatter charts only, the "id" of the metric facet value to use for the x-axis.
|
void |
setXAxisStartValue(java.lang.Double xAxisStartValue)
For Bubble and Scatter charts only, the start value for the x-axis.
|
void |
setXAxisValueFormatter(ValueFormatter formatter)
Formatter to apply to values displayed in the gradation labels on the x-axis.
|
void |
setYAxisMetric(java.lang.String yAxisMetric)
For scatter charts only, the "id" of the metric facet value to use for the y-axis.
|
void |
setYAxisValueFormatter(ValueFormatter formatter)
Formatter to apply to values displayed in the gradation labels on the y-axis.
|
void |
setZoomChartHeight(double zoomChartHeight)
Height of the
zoomChart . |
void |
setZoomChartProperties(FacetChart zoomChartProperties)
Properties to further configure the
zoomChart . |
void |
setZoomEndValue(java.lang.Object zoomEndValue)
For a
zoomed chart , end value of the data range shown in
the main chart. |
void |
setZoomLogScale(java.lang.Boolean zoomLogScale)
|
void |
setZoomMutePercent(float zoomMutePercent)
colorMutePercent to use for the zoomChart . |
void |
setZoomSelectionChartProperties(FacetChart zoomSelectionChartProperties)
Properties to further configure the
zoomSelectionChart . |
void |
setZoomShowSelection(java.lang.Boolean zoomShowSelection)
Whether the selected range should be shown in a different style, which can be configured via
zoomSelectionChartProperties . |
void |
setZoomStartPosition(ZoomStartPosition zoomStartPosition)
For a
zoomed chart , determines what portion of the
overall dataset should be initially shown in the main chart. |
void |
setZoomStartValue(java.lang.Object zoomStartValue)
For a
zoomed chart , start value of the data range shown
in the main chart. |
void |
zoomTo(java.lang.Object startValue,
java.lang.Object endValue)
|
addDrawItem, addGradient, bezier, bezierExtrema, createLinearGradient, createRadialGradient, createSimpleGradient, destroyItems, erase, getBezierBoundingBox, getCanDragScroll, getDataURL, getDataURL, getDrawingHeight, getDrawingWidth, getDrawItems, getGradient, getGradients, getPolygonPoints, getRegularPolygonPoints, getRotation, getRotationAsDouble, getSvgString, getTranslate, getZoomLevel, getZoomLevelAsDouble, removeGradient, rotate, scaleAndCenter, scaleAndCenterBezier, setCanDragScroll, setDefaultProperties, setDrawingHeight, setDrawingWidth, setDrawItems, setGradients, setLogicalStructure, setRotation, setRotation, setTranslate, setZoomLevel, setZoomLevel, zoom, zoom
addChild, addChild, addChild, addChild, addChild, addClickHandler, addDoubleClickHandler, addDragMoveHandler, addDragRepositionMoveHandler, addDragRepositionStartHandler, addDragRepositionStopHandler, addDragResizeMoveHandler, addDragResizeStartHandler, addDragResizeStopHandler, addDragStartHandler, addDragStopHandler, addDropHandler, addDropMoveHandler, addDropOutHandler, addDropOverHandler, addFocusChangedHandler, addHoverHandler, addHoverHiddenHandler, addKeyDownHandler, addKeyPressHandler, addMouseDownHandler, addMouseMoveHandler, addMouseOutHandler, addMouseOverHandler, addMouseStillDownHandler, addMouseUpHandler, addMouseWheelHandler, addMovedHandler, addParentMovedHandler, addPeer, addPeer, addPeer, addPeer, addResizedHandler, addRightMouseDownHandler, addScrolledHandler, addShowContextMenuHandler, addStyleName, addVisibilityChangedHandler, adjustForContent, animateFade, animateFade, animateFade, animateFade, animateFade, animateFade, animateFade, animateFade, animateHide, animateHide, animateHide, animateMove, animateMove, animateMove, animateMove, animateRect, animateRect, animateRect, animateRect, animateResize, animateResize, animateResize, animateResize, animateScroll, animateScroll, animateScroll, animateScroll, animateScroll, animateScroll, animateShow, animateShow, animateShow, animateShow, animateShow, animateShow, asSGWTComponent, blur, bringToFront, clear, clickMaskUp, clickMaskUp, contains, contains, containsEvent, containsFocus, containsPoint, containsPoint, deparent, depeer, disable, enable, encloses, focus, focusInNextTabElement, focusInPreviousTabElement, getAbsoluteLeft, getAbsoluteTop, getAccessKey, getAlwaysShowScrollbars, getAnimateAcceleration, getAnimateFadeTime, getAnimateHideAcceleration, getAnimateHideTime, getAnimateMoveAcceleration, getAnimateMoveTime, getAnimateRectAcceleration, getAnimateRectTime, getAnimateResizeAcceleration, getAnimateResizeTime, getAnimateScrollAcceleration, getAnimateScrollTime, getAnimateShowAcceleration, getAnimateShowEffect, getAnimateShowTime, getAnimateTime, getAppImgDir, getAriaRole, getAutoDraw, getAutoMaskComponents, getAutoShowParent, getBackgroundColor, getBackgroundImage, getBackgroundPosition, getBackgroundRepeat, getBorder, getBottom, getById, getByJSObject, getByLocalId, getCanAcceptDrop, getCanDrag, getCanDragReposition, getCanDragResize, getCanDrop, getCanDropBefore, getCanFocus, getCanHover, getCanSelectText, getCanvasAutoChild, getCanvasItem, getChildren, getChildrenSnapResizeToGrid, getChildrenSnapToGrid, getClassName, getComponentMask, getComponentMaskDefaults, getContentElement, getContents, getContextMenu, getCursor, getDataPath, getDefaultHeight, getDefaultWidth, getDestroyed, getDestroying, getDisabled, getDisabledCursor, getDisableTouchScrollingForDrag, getDoubleClickDelay, getDragAppearance, getDragIntersectStyle, getDragMaskType, getDragOpacity, getDragRepositionAppearance, getDragRepositionCursor, getDragResizeAppearance, getDragScrollDelay, getDragStartDistance, getDragTarget, getDragType, getDropTypes, getDropTypesAsString, getDynamicContents, getEdgeBackgroundColor, getEdgeCenterBackgroundColor, getEdgeImage, getEdgeMarginSize, getEdgeOffset, getEdgeOpacity, getEdgeShowCenter, getEdgeSize, getEditNode, getEditProxy, getElement, getElement, getEventEdge, getEventEdge, getExtraSpace, getFacetId, getFormItemAutoChild, getFullDataPath, getGroupBorderCSS, getGroupLabelBackgroundColor, getGroupLabelStyleName, getGroupTitle, getHeight, getHeightAsString, getHideUsingDisplayNone, getHoverAlign, getHoverAutoDestroy, getHoverComponent, getHoverDelay, getHoverHeight, getHoverHTML, getHoverMoveWithMouse, getHoverOpacity, getHoverStyle, getHoverVAlign, getHoverWidth, getHoverWrap, getHSnapOrigin, getHSnapOrigin, getHSnapPosition, getHSnapPosition, getHtmlElement, getHtmlPosition, getImage, getImgURL, getImgURL, getInnerContentHeight, getInnerContentWidth, getInnerHeight, getInnerWidth, getIsGroup, getKeepInParentRect, getLayoutAlign, getLeavePageSpace, getLeft, getLeftAsString, getLocateChildrenBy, getLocateChildrenType, getLocatePeersBy, getLocatePeersType, getMargin, getMasterCanvas, getMasterElement, getMatchElement, getMaxHeight, getMaxWidth, getMenuConstructor, getMinHeight, getMinNonEdgeSize, getMinWidth, getMomentumScrollMinSpeed, getMouseStillDownDelay, getMouseStillDownInitialDelay, getNextZIndex, getNoDoubleClicks, getOffsetHeight, getOffsetWidth, getOffsetX, getOffsetY, getOpacity, getOuterElement, getOverflow, getPadding, getPageBottom, getPageLeft, getPageRect, getPageRight, getPageTop, getParentCanvas, getParentElement, getPeers, getPercentBox, getPercentSource, getPosition, getPrefix, getPrintChildrenAbsolutelyPositioned, getPrintHTML, getPrompt, getProportionalResizeModifiers, getProportionalResizing, getRect, getRedrawOnResize, getResizeBarTarget, getResizeFrom, getRight, getScrollbarSize, getScrollBottom, getScrollHeight, getScrollLeft, getScrollRight, getScrollTop, getScrollWidth, getShadowDepth, getShadowImage, getShadowOffset, getShadowSoftness, getShouldPrint, getShowCustomScrollbars, getShowDragShadow, getShowEdges, getShowHover, getShowHoverComponents, getShowResizeBar, getShowShadow, getShowSnapGrid, getShrinkElementOnHide, getSkinImgDir, getSnapAxis, getSnapEdge, getSnapHDirection, getSnapHGap, getSnapOffsetLeft, getSnapOffsetTop, getSnapOnDrop, getSnapResizeToGrid, getSnapTo, getSnapToGrid, getSnapVDirection, getSnapVGap, getTabIndex, getTestInstance, getTooltip, getTop, getTopAsString, getTopElement, getUseBackMask, getUseDragMask, getUseNativeDrag, getUseOpacityFilter, getUseTouchScrolling, getValuesManager, getViewportHeight, getViewportWidth, getVisibility, getVisibleHeight, getVisibleWidth, getVSnapOrigin, getVSnapOrigin, getVSnapPosition, getVSnapPosition, getWidth, getWidthAsString, getZIndex, getZIndex, handleHover, hide, hideClickMask, hideClickMask, hideComponentMask, hideContextMenu, imgHTML, imgHTML, imgHTML, intersects, isDirty, isDisabled, isDrawn, isFocused, isVisible, keyUp, layoutChildren, linkHTML, linkHTML, linkHTML, linkHTML, linkHTML, linkHTML, markForDestroy, markForRedraw, markForRedraw, moveAbove, moveBelow, moveBy, moveTo, onAttach, onDetach, onInit, parentResized, printComponents, redraw, redraw, removeChild, removeChild, removePeer, removePeer, resizeBy, resizeTo, resizeTo, scrollBy, scrollByPercent, scrollTo, scrollTo, scrollTo, scrollToBottom, scrollToLeft, scrollToPercent, scrollToRight, scrollToTop, sendToBack, setAccessKey, setAlign, setAllowExternalFilters, setAlwaysShowScrollbars, setAnimateAcceleration, setAnimateFadeTime, setAnimateHideAcceleration, setAnimateHideTime, setAnimateMoveAcceleration, setAnimateMoveTime, setAnimateRectAcceleration, setAnimateRectTime, setAnimateResizeAcceleration, setAnimateResizeTime, setAnimateScrollAcceleration, setAnimateScrollTime, setAnimateShowAcceleration, setAnimateShowEffect, setAnimateShowTime, setAnimateTime, setAppImgDir, setAriaRole, setAriaState, setAutoChildConstructor, setAutoChildProperties, setAutoChildProperties, setAutoChildProperties, setAutoChildProperties, setAutoChildVisibility, setAutoDraw, setAutoHeight, setAutoMaskComponents, setAutoShowParent, setAutoWidth, setBackgroundColor, setBackgroundImage, setBackgroundPosition, setBackgroundRepeat, setBorder, setBottom, setCanAcceptDrop, setCanDrag, setCanDragReposition, setCanDragResize, setCanDrop, setCanDropBefore, setCanFocus, setCanHover, setCanSelectText, setChildren, setChildrenSnapResizeToGrid, setChildrenSnapToGrid, setComponentMaskDefaults, setContents, setContextMenu, setCursor, setDataPath, setDefaultHeight, setDefaultPageSpace, setDefaultProperties, setDefaultWidth, setDisabled, setDisabledCursor, setDisableTouchScrollingForDrag, setDoubleClickDelay, setDragAppearance, setDragIntersectStyle, setDragMaskType, setDragOpacity, setDragRepositionAppearance, setDragRepositionCursor, setDragResizeAppearance, setDragScrollDelay, setDragStartDistance, setDragTarget, setDragType, setDropTypes, setDropTypes, setDynamicContents, setEdgeBackgroundColor, setEdgeCenterBackgroundColor, setEdgeImage, setEdgeMarginSize, setEdgeOffset, setEdgeOpacity, setEdgeShowCenter, setEdgeSize, setEditMode, setEditMode, setEditMode, setElement, setExtraSpace, setFacetId, setGroupBorderCSS, setGroupLabelBackgroundColor, setGroupLabelStyleName, setGroupTitle, setHeight, setHeight, setHeight, setHeight100, setHideUsingDisplayNone, setHoverAlign, setHoverAutoDestroy, setHoverDelay, setHoverHeight, setHoverMoveWithMouse, setHoverOpacity, setHoverStyle, setHoverVAlign, setHoverWidth, setHoverWrap, setHtmlElement, setHtmlPosition, setImage, setImage, setInitHandler, setIsGroup, setKeepInParentRect, setKeepInParentRect, setKeepInParentRect, setLayoutAlign, setLayoutAlign, setLeavePageSpace, setLeft, setLeft, setLocateChildrenBy, setLocateChildrenType, setLocatePeersBy, setLocatePeersType, setLogicalStructure, setMargin, setMatchElement, setMaxHeight, setMaxWidth, setMenuConstructor, setMinHeight, setMinNonEdgeSize, setMinWidth, setMomentumScrollMinSpeed, setMouseStillDownDelay, setMouseStillDownInitialDelay, setNeverUseFilters, setNoDoubleClicks, setOpacity, setOverflow, setPadding, setPageLeft, setPageTop, setParentCanvas, setParentElement, setPeers, setPercentBox, setPercentSource, setPosition, setPrefix, setPrintChildrenAbsolutelyPositioned, setPrompt, setProportionalResizeModifiers, setProportionalResizing, setRect, setRect, setRedrawOnResize, setResizeBarTarget, setResizeFrom, setResizeFrom, setRight, setScrollbarConstructor, setScrollbarSize, setShadowDepth, setShadowImage, setShadowOffset, setShadowSoftness, setShouldPrint, setShowCustomScrollbars, setShowDragShadow, setShowEdges, setShowHover, setShowHoverComponents, setShowResizeBar, setShowShadow, setShowSnapGrid, setShrinkElementOnHide, setSkinImgDir, setSmoothFade, setSnapAxis, setSnapEdge, setSnapHDirection, setSnapHGap, setSnapOffsetLeft, setSnapOffsetTop, setSnapOnDrop, setSnapResizeToGrid, setSnapTo, setSnapToGrid, setSnapVDirection, setSnapVGap, setTabIndex, setTooltip, setTop, setTop, setUseBackMask, setUseDragMask, setUseNativeDrag, setUseOpacityFilter, setUseTouchScrolling, setValuesManager, setVisibility, setVisible, setWidth, setWidth, setWidth, setWidth100, setZIndex, shouldDragScroll, show, showClickMask, showComponentMask, showComponentMask, showNextTo, showNextTo, showNextTo, showNextTo, showPrintPreview, showPrintPreview, showPrintPreview, showPrintPreview, showRecursively, updateEditNode, updateHover, updateHover, updateShadow, visibleAtPoint, willAcceptDrop
addDrawHandler, applyFactoryProperties, destroy, doAddHandler, doInit, doOnRender, draw, equals, error, errorIfNotCreated, getAttribute, getAttributeAsBoolean, getAttributeAsDate, getAttributeAsDateArray, getAttributeAsDouble, getAttributeAsElement, getAttributeAsFloat, getAttributeAsFloatArray, getAttributeAsInt, getAttributeAsIntArray, getAttributeAsJavaScriptObject, getAttributeAsMap, getAttributeAsRecord, getAttributeAsString, getAttributeAsStringArray, getConfig, getDOM, getHandlerCount, getID, getInnerHTML, getJsObj, getOrCreateJsObj, getRef, getScClassName, hasAutoAssignedID, hashCode, initNativeObject, internalSetID, internalSetID, isConfigOnly, isCreated, isFactoryCreated, onBind, onDestroy, onDraw, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setAttribute, setConfig, setConfigOnly, setDragTracker, setFactoryCreated, setID, setJavaScriptObject, setLogicalStructure, setNullProperty, setPosition, setProperty, setProperty, setProperty, setProperty, setProperty, setProperty, setProperty, setScClassName, toString
addAttachHandler, addBitlessDomHandler, addDomHandler, addHandler, asWidget, asWidgetOrNull, createHandlerManager, delegateEvent, doAttachChildren, doDetachChildren, fireEvent, getLayoutData, getParent, isAttached, isOrWasAttached, onBrowserEvent, onLoad, onUnload, removeFromParent, setLayoutData, sinkEvents
addStyleDependentName, ensureDebugId, ensureDebugId, ensureDebugId, getStyleElement, getStyleName, getStylePrimaryName, getStylePrimaryName, isVisible, onEnsureDebugId, removeStyleDependentName, removeStyleName, resolvePotentialElement, setElement, setPixelSize, setSize, setStyleDependentName, setStyleName, setStyleName, setStyleName, setStylePrimaryName, setStylePrimaryName, setVisible, sinkBitlessEvent, unsinkEvents
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
fireEvent
public FacetChart()
public FacetChart(JavaScriptObject jsObj)
public static FacetChart getOrCreateRef(JavaScriptObject jsObj)
public static void changeAutoChildDefaults(java.lang.String autoChildName, Canvas defaults)
autoChildName
.autoChildName
- name of an AutoChild to customize the defaults for.defaults
- Canvas defaults to apply. These defaults override any existing properties
without destroying or wiping out non-overridden properties.AutoChildUsage
public static void changeAutoChildDefaults(java.lang.String autoChildName, FormItem defaults)
autoChildName
.autoChildName
- name of an AutoChild to customize the defaults for.defaults
- FormItem defaults to apply. These defaults override any existing properties
without destroying or wiping out non-overridden properties.AutoChildUsage
protected JavaScriptObject create()
public void setAllowBubbleGradients(boolean allowBubbleGradients) throws java.lang.IllegalStateException
false
prevents the chart from drawing fill gradients into the bubbles of each data
point. This flag is required to be set for IE8 and earlier in order to draw bubble charts displaying high volumes of
data.allowBubbleGradients
- Default value is !(isc.Browser.isIE && isc.Browser.version <= 8)java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic boolean getAllowBubbleGradients()
false
prevents the chart from drawing fill gradients into the bubbles of each data
point. This flag is required to be set for IE8 and earlier in order to draw bubble charts displaying high volumes of
data.public void setAllowedChartTypes(ChartType... allowedChartTypes)
chart types
that the end user will be allowed to switch to, using the
built-in context menu. The actual list of ChartTypes displayed in the context menu may be a subset of
allowedChartTypes
, since the FacetChart will automatically disallow certain modes that are clearly invalid,
for example, not allowing switching to Pie mode if either canZoom
is enabled, or if the chart is multi-axis
.
allowedChartTypes
- Default value is nullpublic ChartType[] getAllowedChartTypes()
chart types
that the end user will be allowed to switch to, using the
built-in context menu. The actual list of ChartTypes displayed in the context menu may be a subset of
allowedChartTypes
, since the FacetChart will automatically disallow certain modes that are clearly invalid,
for example, not allowing switching to Pie mode if either canZoom
is enabled, or if the chart is multi-axis
.
public void setAutoRotateLabels(java.lang.Boolean autoRotateLabels) throws java.lang.IllegalStateException
rotateLabels
. Setting rotateLabels to "auto" is
equivalent to setting autoRotateLabels to true
. Setting rotateLabels to "never" is equivalent to setting
autoRotateLabels to false
.autoRotateLabels
- Default value is truejava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Boolean getAutoRotateLabels()
rotateLabels
. Setting rotateLabels to "auto" is
equivalent to setting autoRotateLabels to true
. Setting rotateLabels to "never" is equivalent to setting
autoRotateLabels to false
.public void setAutoSortBubblePoints(boolean autoSortBubblePoints) throws java.lang.IllegalStateException
point size
so that small values are less likely to be
completely occluded by larger values. Set this to false
to draw the data points in the same order that
they appear in the data.autoSortBubblePoints
- Default value is truejava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic boolean getAutoSortBubblePoints()
point size
so that small values are less likely to be
completely occluded by larger values. Set this to false
to draw the data points in the same order that
they appear in the data.public void setAxisStartValue(java.lang.Double axisStartValue) throws java.lang.IllegalStateException
Defaults to 0, or to a value that makes good use of vertical space
based on minDataSpreadPercent
.
For
multi-axis charts, Bubble charts, and Scatter charts, the facetChart.axisStartValue
affects only the
first axis of the chart. Start values for other axes of multi-axis charts can be set on a per-axis basis via
axisStartValue
. For Scatter charts, the
xAxisStartValue
property must be used to set the
start value of the x-axis.
axisStartValue
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Double getAxisStartValue()
Defaults to 0, or to a value that makes good use of vertical space
based on minDataSpreadPercent
.
For
multi-axis charts, Bubble charts, and Scatter charts, the facetChart.axisStartValue
affects only the
first axis of the chart. Start values for other axes of multi-axis charts can be set on a per-axis basis via
axisStartValue
. For Scatter charts, the
xAxisStartValue
property must be used to set the
start value of the x-axis.
public void setBackgroundBandProperties(DrawRect backgroundBandProperties) throws java.lang.IllegalStateException
backgroundBandProperties
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic DrawRect getBackgroundBandProperties()
public void setBandedBackground(java.lang.Boolean bandedBackground) throws java.lang.IllegalStateException
backgroundBandProperties
.bandedBackground
- Default value is truejava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Boolean getBandedBackground()
backgroundBandProperties
.public void setBandedStandardDeviations(java.lang.Boolean bandedStandardDeviations) throws java.lang.IllegalStateException
standard deviation
lines. Standard deviation bands are not available for pie or radar charts.
bandedStandardDeviations
- Default value is falsejava.lang.IllegalStateException
- this property cannot be changed after the component has been createdsetStandardDeviationBandProperties(com.smartgwt.client.widgets.drawing.DrawItem...)
public java.lang.Boolean getBandedStandardDeviations()
standard deviation
lines. Standard deviation bands are not available for pie or radar charts.
getStandardDeviationBandProperties()
public void setBarMargin(int barMargin) throws java.lang.IllegalStateException
minBarThickness
.barMargin
- Default value is 4java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic int getBarMargin()
minBarThickness
.public void setBarProperties(DrawRect barProperties)
barProperties
- Default value is nullpublic DrawRect getBarProperties()
public void setBubbleHoverMaxDistance(int bubbleHoverMaxDistance) throws java.lang.IllegalStateException
bubbleHoverMaxDistance
- Default value is 50java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic int getBubbleHoverMaxDistance()
public void setBubbleProperties(DrawItem bubbleProperties) throws java.lang.IllegalStateException
When either the pointSizeMetric
or the colorScaleMetric
is active the default
bubbleProperties
displays each data points with a linear gradient.
bubbleProperties
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic DrawItem getBubbleProperties()
When either the pointSizeMetric
or the colorScaleMetric
is active the default
bubbleProperties
displays each data points with a linear gradient.
public void setCanMoveAxes(java.lang.Boolean canMoveAxes) throws java.lang.IllegalStateException
canMoveAxes
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Boolean getCanMoveAxes()
public void setCanZoom(java.lang.Boolean canZoom) throws java.lang.IllegalStateException
second smaller chart
appears with slider controls
allowing a range to be selected for display in the main chart. A labelCollapseMode
is automatically enabled if unset
and is based on the type of the first non-null data value.
canZoom
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Boolean getCanZoom()
second smaller chart
appears with slider controls
allowing a range to be selected for display in the main chart. A labelCollapseMode
is automatically enabled if unset
and is based on the type of the first non-null data value.
public void setChartRectMargin(int chartRectMargin) throws java.lang.IllegalStateException
chartRectMargin
- Default value is 5java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic int getChartRectMargin()
public void setChartRectProperties(DrawRect chartRectProperties)
rounding
of the
chart rect. causes the gradation lines to be automatically inset from the edge so that they do not run right along the
curve. Set padChartRectByCornerRadius
to false
to change this default.chartRectProperties
- Default value is nullpublic DrawRect getChartRectProperties()
rounding
of the
chart rect. causes the gradation lines to be automatically inset from the edge so that they do not run right along the
curve. Set padChartRectByCornerRadius
to false
to change this default.public void setChartType(ChartType chartType)
ChartType
for a list of known types - Column, Bar, Line, Pie, Doughnut, Area, and
Radar charts are supported.
chartType
. Will redraw the chart if drawn. Will use default settings for the new chart type for stacked
and filled
if those values are null. Note that for multi-axis
charts this method changes the chartType
for the main value axis only.
chartType
- new chart type. Default value is "Column"public ChartType getChartType()
ChartType
for a list of known types - Column, Bar, Line, Pie, Doughnut, Area, and
Radar charts are supported.public void setClusterMarginRatio(float clusterMarginRatio) throws java.lang.IllegalStateException
clusterMarginRatio
- Default value is 4java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic float getClusterMarginRatio()
public void setColorMutePercent(java.lang.Float colorMutePercent) throws java.lang.IllegalStateException
colorMutePercent
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Float getColorMutePercent()
public void setColorScaleMetric(java.lang.String colorScaleMetric) throws java.lang.IllegalStateException
showDataPoints
is enabled, this
property specifies an additional metric (i.e. an "id" of a metric facet value) that causes the data points to be colored
from scaleStartColor
to scaleEndColor
based on a linear scale over the values of
this metric. Log-scaling for color scale is also supported with logScalePointColor
.colorScaleMetric
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.String getColorScaleMetric()
showDataPoints
is enabled, this
property specifies an additional metric (i.e. an "id" of a metric facet value) that causes the data points to be colored
from scaleStartColor
to scaleEndColor
based on a linear scale over the values of
this metric. Log-scaling for color scale is also supported with logScalePointColor
.public void setDataAxisLabelProperties(DrawLabel dataAxisLabelProperties)
dataAxisLabelProperties
- Default value is nullpublic DrawLabel getDataAxisLabelProperties()
public void setDataColors(java.lang.String... dataColors)
Colors must be in the format of a leading hash (#) plus 6 hexadecimal digits, for
example, "#FFFFFF" is white, "#FF0000" is pure red.
If this method is called after the component has been drawn/initialized:
Setter for dataColors
.
dataColors
- New set of data colors See CSSColor
. Default value is see belowpublic java.lang.String[] getDataColors()
Colors must be in the format of a leading hash (#) plus 6 hexadecimal digits, for example, "#FFFFFF" is white, "#FF0000" is pure red.
CSSColor
public void setDataLabelProperties(DrawLabel dataLabelProperties)
dataLabelProperties
- Default value is nullpublic DrawLabel getDataLabelProperties()
public void setDataLineProperties(DrawLine dataLineProperties) throws java.lang.IllegalStateException
dataLineProperties
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic DrawLine getDataLineProperties()
public void setDataLineType(DataLineType dataLineType)
DataLineType
. Does not apply to boundary lines for shapes in Area or Radar plots.
If this method is called after the component has been drawn/initialized:
Method to change the current dataLineType
. Will redraw the chart if drawn.
dataLineType
- ow to draw lines between adjacent data points in Line and Scatter charts. Default value is nullpublic DataLineType getDataLineType()
DataLineType
. Does not apply to boundary lines for shapes in Area or Radar plots.
public void setDataMargin(int dataMargin) throws java.lang.IllegalStateException
dataMargin
- Default value is 10java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic int getDataMargin()
public void setDataOutlineProperties(DrawItem dataOutlineProperties) throws java.lang.IllegalStateException
dataOutlineProperties
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic DrawItem getDataOutlineProperties()
public void setDataPointProperties(DrawItem dataPointProperties) throws java.lang.IllegalStateException
showDataPoints
).dataPointProperties
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic DrawItem getDataPointProperties()
showDataPoints
).public void setDataPointSize(int dataPointSize) throws java.lang.IllegalStateException
dataPointSize
- Default value is 5java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic int getDataPointSize()
public void setDataShapeProperties(DrawPath dataShapeProperties) throws java.lang.IllegalStateException
dataShapeProperties
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic DrawPath getDataShapeProperties()
public void setDecimalPrecision(int decimalPrecision) throws java.lang.IllegalStateException
decimalPrecision
- Default value is 2java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic int getDecimalPrecision()
public void setDiscontinuousLines(java.lang.Boolean discontinuousLines)
false
then null values are ignored. Defaults to true
for filled
charts and to false
for line charts.discontinuousLines
- Default value is nullpublic java.lang.Boolean getDiscontinuousLines()
false
then null values are ignored. Defaults to true
for filled
charts and to false
for line charts.public void setDoughnutHoleProperties(DrawOval doughnutHoleProperties)
doughnutHoleProperties
- Default value is nullpublic DrawOval getDoughnutHoleProperties()
public void setDoughnutRatio(float doughnutRatio) throws java.lang.IllegalStateException
showDoughnut
),
ratio of the size of the doughnut hole to the size of the overall pie chart, as a number between 0 to 1.doughnutRatio
- Default value is 0.2java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic float getDoughnutRatio()
showDoughnut
),
ratio of the size of the doughnut hole to the size of the overall pie chart, as a number between 0 to 1.public void setEditProxyConstructor(java.lang.String editProxyConstructor) throws java.lang.IllegalStateException
EditProxy
for this component when the component is
first placed into edit mode
.setEditProxyConstructor
in class DrawPane
editProxyConstructor
- See SCClassName
. Default value is "FacetChartEditProxy"java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.String getEditProxyConstructor()
EditProxy
for this component when the component is
first placed into edit mode
.getEditProxyConstructor
in class DrawPane
SCClassName
public void setErrorBarColorMutePercent(float errorBarColorMutePercent) throws java.lang.IllegalStateException
errorBarColorMutePercent
- Default value is -60java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic float getErrorBarColorMutePercent()
public void setErrorBarWidth(int errorBarWidth) throws java.lang.IllegalStateException
errorBarWidth
- Default value is 6java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic int getErrorBarWidth()
public void setErrorLineProperties(DrawLine errorLineProperties) throws java.lang.IllegalStateException
Note that the lineColor
property has no effect as the color of the error bars is derived from the color of the data line.
errorLineProperties
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdsetErrorBarColorMutePercent(float)
public DrawLine getErrorLineProperties()
Note that the lineColor
property has no effect as the color of the error bars is derived from the color of the data line.
getErrorBarColorMutePercent()
public void setExpectedValueLineProperties(DrawItem expectedValueLineProperties) throws java.lang.IllegalStateException
line drawn at the mean
value
. Note that for rectangular charts the properties are for a DrawLine
, and for radar charts the properties are for a DrawOval
.
expectedValueLineProperties
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic DrawItem getExpectedValueLineProperties()
line drawn at the mean
value
. Note that for rectangular charts the properties are for a DrawLine
, and for radar charts the properties are for a DrawOval
.
public void setExtraAxisMetrics(java.lang.String... extraAxisMetrics) throws java.lang.IllegalStateException
FacetChart
docs for an overview of how multi-axis charts are used. Each metric
corresponds to different value property of the data records and superimposes its drawn data onto the chart rectangle.
The value properties are called metrics, and they can be either the valueProperty
or the "id" of a FacetValue
of the inlined Facet
(which is
then called the metric facet). Each value axis has its own gradations that are shown as tick marks along the length of
the axis. This property, extraAxisMetrics, specifies the metrics to use for additional value axes to the main value
axis.
The additional value axis may have their own gradations, chart type, log scale, data colors and gradients, and
other chart properties. These properties are specified with the extraAxisSettings
property.
Value axes, including
the main value axis, are labelled in the legend along with representations of the charted data. The labels are taken
from the title
of each metric's FacetValue (or the valueTitle
if the metric is the valueProperty
).
The order of the metrics determines the position of the corresponding axes on the chart as well as the z-ordering of the corresponding data lines. The first and second extra value axes are placed to the right of the chart rectangle, and any remaining extra value axes are placed to the left of the main value axis (and therefore to the left of the chart rectangle).
extraAxisMetrics
- Default value is []java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.String[] getExtraAxisMetrics()
FacetChart
docs for an overview of how multi-axis charts are used. Each metric
corresponds to different value property of the data records and superimposes its drawn data onto the chart rectangle.
The value properties are called metrics, and they can be either the valueProperty
or the "id" of a FacetValue
of the inlined Facet
(which is
then called the metric facet). Each value axis has its own gradations that are shown as tick marks along the length of
the axis. This property, extraAxisMetrics, specifies the metrics to use for additional value axes to the main value
axis.
The additional value axis may have their own gradations, chart type, log scale, data colors and gradients, and
other chart properties. These properties are specified with the extraAxisSettings
property.
Value axes, including
the main value axis, are labelled in the legend along with representations of the charted data. The labels are taken
from the title
of each metric's FacetValue (or the valueTitle
if the metric is the valueProperty
).
The order of the metrics determines the position of the corresponding axes on the chart as well as the z-ordering of the corresponding data lines. The first and second extra value axes are placed to the right of the chart rectangle, and any remaining extra value axes are placed to the left of the main value axis (and therefore to the left of the chart rectangle).
public void setExtraAxisSettings(MetricSettings... extraAxisSettings) throws java.lang.IllegalStateException
extra axis metric
is plotted. See the main FacetChart
docs for an overview of how multi-axis charts are used. The chart of
each metric's values may be of any rectangular chart type that uses a vertical value axis ("Column", "Area", and
"Line"). Because the charts will be superimposed over the same drawing area, there can only be one "Column" chart and
one "Area" chart. The column chart is placed on the bottom followed by the area chart, and then the line charts are
drawn on top in the order of their metric in the extraAxisMetrics
array. If the chartType
s are
left unspecified then by default the first metric will be drawn as columns and the remaining will be drawn as lines.
extraAxisSettings
- Default value is []java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic MetricSettings[] getExtraAxisSettings()
extra axis metric
is plotted. See the main FacetChart
docs for an overview of how multi-axis charts are used. The chart of
each metric's values may be of any rectangular chart type that uses a vertical value axis ("Column", "Area", and
"Line"). Because the charts will be superimposed over the same drawing area, there can only be one "Column" chart and
one "Area" chart. The column chart is placed on the bottom followed by the area chart, and then the line charts are
drawn on top in the order of their metric in the extraAxisMetrics
array. If the chartType
s are
left unspecified then by default the first metric will be drawn as columns and the remaining will be drawn as lines.
public void setFacets(Facet... facets) throws java.lang.IllegalStateException
facets
, except
that: In all chart
types except "Bubble" and "Scatter", the chart displays a value for each discrete value of one facet (i.e. single-facet
charts) or it displays a value for each combination of discrete values of two facets (multi-facet charts). The two
discrete facets are the data label facet
and the
legend facet
. They are named based on where the
values
of the facet appear in the chart. The facet whose
values are rendered as labels along the data axis or in the main chart area is the data label facet, and the facet whose
values are rendered in the legend is the legend facet.
For single-facet charts, most chart types have a data label facet as the first facet but no legend facet. Single-facet Pie charts have a legend facet as the first facet but no data label facet. Bubble and Scatter plots may have a legend facet as the second facet, after the metric facet.
In all multi-facet charts, the data label facet is always first and the legend facet is second. In most chart types the data label facet and the legend facet may be swapped on the fly by the user clicking on the "Swap Facets" item of the context menu.
facets
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic Facet[] getFacets()
facets
, except
that: In all chart
types except "Bubble" and "Scatter", the chart displays a value for each discrete value of one facet (i.e. single-facet
charts) or it displays a value for each combination of discrete values of two facets (multi-facet charts). The two
discrete facets are the data label facet
and the
legend facet
. They are named based on where the
values
of the facet appear in the chart. The facet whose
values are rendered as labels along the data axis or in the main chart area is the data label facet, and the facet whose
values are rendered in the legend is the legend facet.
For single-facet charts, most chart types have a data label facet as the first facet but no legend facet. Single-facet Pie charts have a legend facet as the first facet but no data label facet. Bubble and Scatter plots may have a legend facet as the second facet, after the metric facet.
In all multi-facet charts, the data label facet is always first and the legend facet is second. In most chart types the data label facet and the legend facet may be swapped on the fly by the user clicking on the "Swap Facets" item of the context menu.
public void setFacets(Facet facets) throws java.lang.IllegalStateException
facets
, except
that: In all chart
types except "Bubble" and "Scatter", the chart displays a value for each discrete value of one facet (i.e. single-facet
charts) or it displays a value for each combination of discrete values of two facets (multi-facet charts). The two
discrete facets are the data label facet
and the
legend facet
. They are named based on where the
values
of the facet appear in the chart. The facet whose
values are rendered as labels along the data axis or in the main chart area is the data label facet, and the facet whose
values are rendered in the legend is the legend facet.
For single-facet charts, most chart types have a data label facet as the first facet but no legend facet. Single-facet Pie charts have a legend facet as the first facet but no data label facet. Bubble and Scatter plots may have a legend facet as the second facet, after the metric facet.
In all multi-facet charts, the data label facet is always first and the legend facet is second. In most chart types the data label facet and the legend facet may be swapped on the fly by the user clicking on the "Swap Facets" item of the context menu.
facets
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic Facet getFacetsAsFacet()
facets
, except
that: In all chart
types except "Bubble" and "Scatter", the chart displays a value for each discrete value of one facet (i.e. single-facet
charts) or it displays a value for each combination of discrete values of two facets (multi-facet charts). The two
discrete facets are the data label facet
and the
legend facet
. They are named based on where the
values
of the facet appear in the chart. The facet whose
values are rendered as labels along the data axis or in the main chart area is the data label facet, and the facet whose
values are rendered in the legend is the legend facet.
For single-facet charts, most chart types have a data label facet as the first facet but no legend facet. Single-facet Pie charts have a legend facet as the first facet but no data label facet. Bubble and Scatter plots may have a legend facet as the second facet, after the metric facet.
In all multi-facet charts, the data label facet is always first and the legend facet is second. In most chart types the data label facet and the legend facet may be swapped on the fly by the user clicking on the "Swap Facets" item of the context menu.
public void setFilled(java.lang.Boolean filled)
If unset, fills will be automatically used when there are multiple facets and stacking is active (so Line and Radar charts will show stacked regions).
You can explicitly set filled:false to
create multi-facet Line or Radar charts where translucent regions overlap, or filled:true to fill in a single-facet Line
or Radar chart.
If this method is called after the component has been drawn/initialized:
Method to change filled
. Use null to apply a default value for the current chartType
.
filled
- new value. Default value is nullpublic java.lang.Boolean getFilled()
If unset, fills will be automatically used when there are multiple facets and stacking is active (so Line and Radar charts will show stacked regions).
You can explicitly set filled:false to create multi-facet Line or Radar charts where translucent regions overlap, or filled:true to fill in a single-facet Line or Radar chart.
public void setGradationLabelProperties(DrawLabel gradationLabelProperties) throws java.lang.IllegalStateException
gradationLabelProperties
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic DrawLabel getGradationLabelProperties()
public void setGradationLineProperties(DrawLine gradationLineProperties) throws java.lang.IllegalStateException
gradationLineProperties
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic DrawLine getGradationLineProperties()
public void setGradationTickMarkLength(int gradationTickMarkLength) throws java.lang.IllegalStateException
extra value axes
.gradationTickMarkLength
- Default value is 5java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic int getGradationTickMarkLength()
extra value axes
.public void setGradationZeroLineProperties(DrawLine gradationZeroLineProperties) throws java.lang.IllegalStateException
gradationZeroLineProperties
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic DrawLine getGradationZeroLineProperties()
public void setHighErrorMetric(java.lang.String highErrorMetric) throws java.lang.IllegalStateException
lowErrorMetric
.highErrorMetric
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.String getHighErrorMetric()
lowErrorMetric
.public void setHoverLabelPadding(int hoverLabelPadding) throws java.lang.IllegalStateException
hoverLabel
when showValueOnHover
is enabled.
Note : This is an advanced setting
hoverLabelPadding
- Default value is 4java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic int getHoverLabelPadding()
hoverLabel
when showValueOnHover
is enabled.public void setHoverLabelProperties(DrawLabel hoverLabelProperties) throws java.lang.IllegalStateException
showValueOnHover
is enabled.hoverLabelProperties
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdsetHoverLabelPadding(int)
public DrawLabel getHoverLabelProperties()
showValueOnHover
is enabled.getHoverLabelPadding()
public void setHoverRectProperties(DrawRect hoverRectProperties) throws java.lang.IllegalStateException
showValueOnHover
for more details.hoverRectProperties
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic DrawRect getHoverRectProperties()
showValueOnHover
for more details.public void setLabelCollapseMode(LabelCollapseMode labelCollapseMode) throws java.lang.IllegalStateException
LabelCollapseMode
. Each of the possible strategies is re-applied when the user resizes the chart as a whole, so if labels are omitted the user can make them visible via resize or zoom.
If the labelCollapseMode is "numeric" then vertical lines will be drawn at gradation values automatically chosen by the chart.
If the labelCollapseMode is "time" then vertical lines are drawn to represent a sequence of significant datetime values on the x-axis, such as the first day of the month or week. The chart automatically chooses the sequence of Dates such that the spacing between them expresses the smallest granularity of time possible while still allowing the axis labels to make good use of the space. If, for example, the Date values in the data span a few years in time then the chart may select January 1 of the same year of the earliest data point and every January 1 thereafter (in range of the data) as the sequence of Dates and label each Date by the four-digit year. If the time span of the data values is on the order of minutes then the chart may select multiples of 15 minutes as the seqeunce of Dates. FacetChart currently supports the following granularities of time: years, quarters, months, weeks, days, hours, half-hours, quarter-hours, 5 minutes, minutes, 30 seconds, and 15 seconds.
The format of the Date labels is fixed by FacetChart.
In particular, FacetChart.formatAxisValue()
will
not be called on values for the x-axis. However, FacetChart uses the global array of abbreviated month names
for the time
granularities of quarters, months, and weeks, uses the default short time format
to format labels for time
granularities from minutes to hours, and uses the default time format
to format labels for the time
granularities of 15 seconds and 30 seconds. The label format can be customized by changing these three formatters.
Also note that for the time granularity of weeks the sequence of Dates will be the first day of each week, as specified
by com.smartgwt.client.util.DateUtil#setFirstDayOfWeek()
.
Note that if the labelCollapseMode is "time" or
"numeric" then the data
must be initially sorted with the
data label facet
's values in ascending order.
labelCollapseMode
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic LabelCollapseMode getLabelCollapseMode()
LabelCollapseMode
. Each of the possible strategies is re-applied when the user resizes the chart as a whole, so if labels are omitted the user can make them visible via resize or zoom.
If the labelCollapseMode is "numeric" then vertical lines will be drawn at gradation values automatically chosen by the chart.
If the labelCollapseMode is "time" then vertical lines are drawn to represent a sequence of significant datetime values on the x-axis, such as the first day of the month or week. The chart automatically chooses the sequence of Dates such that the spacing between them expresses the smallest granularity of time possible while still allowing the axis labels to make good use of the space. If, for example, the Date values in the data span a few years in time then the chart may select January 1 of the same year of the earliest data point and every January 1 thereafter (in range of the data) as the sequence of Dates and label each Date by the four-digit year. If the time span of the data values is on the order of minutes then the chart may select multiples of 15 minutes as the seqeunce of Dates. FacetChart currently supports the following granularities of time: years, quarters, months, weeks, days, hours, half-hours, quarter-hours, 5 minutes, minutes, 30 seconds, and 15 seconds.
The format of the Date labels is fixed by FacetChart.
In particular, FacetChart.formatAxisValue()
will
not be called on values for the x-axis. However, FacetChart uses the global array of abbreviated month names
for the time
granularities of quarters, months, and weeks, uses the default short time format
to format labels for time
granularities from minutes to hours, and uses the default time format
to format labels for the time
granularities of 15 seconds and 30 seconds. The label format can be customized by changing these three formatters.
Also note that for the time granularity of weeks the sequence of Dates will be the first day of each week, as specified
by com.smartgwt.client.util.DateUtil#setFirstDayOfWeek()
.
Note that if the labelCollapseMode is "time" or
"numeric" then the data
must be initially sorted with the
data label facet
's values in ascending order.
public void setLegendItemPadding(int legendItemPadding) throws java.lang.IllegalStateException
legendItemPadding
- Default value is 5java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic int getLegendItemPadding()
public void setLegendLabelProperties(DrawLabel legendLabelProperties) throws java.lang.IllegalStateException
legendLabelProperties
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic DrawLabel getLegendLabelProperties()
public void setLegendMargin(int legendMargin) throws java.lang.IllegalStateException
legendMargin
- Default value is 10java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic int getLegendMargin()
public void setLegendPadding(int legendPadding) throws java.lang.IllegalStateException
legendPadding
- Default value is 5java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic int getLegendPadding()
public void setLegendRectProperties(DrawRect legendRectProperties) throws java.lang.IllegalStateException
legendRectProperties
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic DrawRect getLegendRectProperties()
public void setLegendSwatchProperties(DrawRect legendSwatchProperties) throws java.lang.IllegalStateException
legendSwatchProperties
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic DrawRect getLegendSwatchProperties()
public void setLegendSwatchSize(int legendSwatchSize) throws java.lang.IllegalStateException
legendSwatchSize
- Default value is 16java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic int getLegendSwatchSize()
public void setLegendTextPadding(int legendTextPadding) throws java.lang.IllegalStateException
legendTextPadding
- Default value is 5java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic int getLegendTextPadding()
public void setLogBase(int logBase) throws java.lang.IllegalStateException
useLogGradations
, base value for
logarithmic gradation lines. Gradation lines will be shown at every power of this value plus intervening values
specified by logGradations
.logBase
- Default value is 10java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic int getLogBase()
useLogGradations
, base value for
logarithmic gradation lines. Gradation lines will be shown at every power of this value plus intervening values
specified by logGradations
.public void setLogGradations(float... logGradations) throws java.lang.IllegalStateException
useLogGradations
is set, gradation lines
to show in between powers,
expressed as a series of integer or float values between 1 and logBase
.
Some common possibilities (for base 10):
[ 1 ] // show only orders of magnitude (0.1, 1, 10, 100, etc) [ 1, 5 ] // show only orders of magnitude plus halfway mark [ 1, 2, 4, 8 ] // show powers of 2 between orders [ 1, 2.5, 5, 7.5 ] // show quartersOr base 2:
[ 1 ] [ 1, 1.5 ]
logGradations
- Default value is [ 1,2,4,6,8 ]java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic float[] getLogGradations()
useLogGradations
is set, gradation lines
to show in between powers,
expressed as a series of integer or float values between 1 and logBase
.
Some common possibilities (for base 10):
[ 1 ] // show only orders of magnitude (0.1, 1, 10, 100, etc) [ 1, 5 ] // show only orders of magnitude plus halfway mark [ 1, 2, 4, 8 ] // show powers of 2 between orders [ 1, 2.5, 5, 7.5 ] // show quartersOr base 2:
[ 1 ] [ 1, 1.5 ]
public void setLogScale(java.lang.Boolean logScale) throws java.lang.IllegalStateException
Logarithmic scale charts show an equivalent percentage increase as equivalent distance on the chart. That is, 10 and 100 are the same distance apart as 100 and 1000 (each being a 10 times or 1000% increase).
logScale
- Default value is falsejava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Boolean getLogScale()
Logarithmic scale charts show an equivalent percentage increase as equivalent distance on the chart. That is, 10 and 100 are the same distance apart as 100 and 1000 (each being a 10 times or 1000% increase).
public void setLogScalePointColor(boolean logScalePointColor) throws java.lang.IllegalStateException
color
scale
of the data points. Defaults to the value of logScale
.logScalePointColor
- Default value is falsejava.lang.IllegalStateException
- this property cannot be changed after the component has been createdsetPointColorLogBase(java.lang.Integer)
,
Color Scale Chart Examplepublic boolean getLogScalePointColor()
color
scale
of the data points. Defaults to the value of logScale
.getPointColorLogBase()
,
Color Scale Chart Examplepublic void setLogScalePointSize(boolean logScalePointSize) throws java.lang.IllegalStateException
data
point sizes
. Defaults to the value of logScale
.logScalePointSize
- Default value is falsejava.lang.IllegalStateException
- this property cannot be changed after the component has been createdsetPointSizeLogBase(java.lang.Integer)
,
Bubble Chart Examplepublic boolean getLogScalePointSize()
data
point sizes
. Defaults to the value of logScale
.getPointSizeLogBase()
,
Bubble Chart Examplepublic void setLowErrorMetric(java.lang.String lowErrorMetric) throws java.lang.IllegalStateException
lowErrorMetric
and highErrorMetric
can be used to cause error bars to appear above and below the main data point. lowErrorMetric
and
highErrorMetric
provide the name of an additional attributes that appears in each Record holding the low
error value and high error value respectively.
Error bars are supported for single-axis charts only.
lowErrorMetric
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.String getLowErrorMetric()
lowErrorMetric
and highErrorMetric
can be used to cause error bars to appear above and below the main data point. lowErrorMetric
and
highErrorMetric
provide the name of an additional attributes that appears in each Record holding the low
error value and high error value respectively.
Error bars are supported for single-axis charts only.
public void setMaxBarThickness(int maxBarThickness) throws java.lang.IllegalStateException
maxBarThickness
- Default value is 150java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic int getMaxBarThickness()
public void setMaxDataPointSize(double maxDataPointSize) throws java.lang.IllegalStateException
pointSizeMetric
.maxDataPointSize
- Default value is 14java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic double getMaxDataPointSize()
pointSizeMetric
.public void setMinBarThickness(int minBarThickness) throws java.lang.IllegalStateException
minBarThickness
- Default value is 4java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic int getMinBarThickness()
public void setMinDataPointSize(double minDataPointSize) throws java.lang.IllegalStateException
pointSizeMetric
.minDataPointSize
- Default value is 3java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic double getMinDataPointSize()
pointSizeMetric
.public void setMinDataSpreadPercent(int minDataSpreadPercent) throws java.lang.IllegalStateException
minDataSpreadPercent
of the axis, the start values
of axes will be automatically adjusted to make better use of space. For example, if a column chart has all data
values between 500,000 and 500,100, if the axis starts at 0, differences in column heights will be visually
indistinguishable. In this case, since all data values appear in well under 30% of the axis length, the default
minDataSpreadPercent
setting would cause the axis to start at a value that would make the column heights
obviously different (for example, starting the axis as 500,000).
Setting an explicit axisStartValue
disables this behavior, as does setting
minDataSpreadPercent
to 0.
For multi-axis charts, use minDataSpreadPercent
for per-axis settings.
For Bubble and Scatter charts, minDataSpreadPercent
affects only the y-axis of the chart. The property
minXDataSpreadPercent
must be used to
enable the corresponding feature for the x-axis.
minDataSpreadPercent
- Default value is 30java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic int getMinDataSpreadPercent()
minDataSpreadPercent
of the axis, the start values
of axes will be automatically adjusted to make better use of space. For example, if a column chart has all data
values between 500,000 and 500,100, if the axis starts at 0, differences in column heights will be visually
indistinguishable. In this case, since all data values appear in well under 30% of the axis length, the default
minDataSpreadPercent
setting would cause the axis to start at a value that would make the column heights
obviously different (for example, starting the axis as 500,000).
Setting an explicit axisStartValue
disables this behavior, as does setting
minDataSpreadPercent
to 0.
For multi-axis charts, use minDataSpreadPercent
for per-axis settings.
For Bubble and Scatter charts, minDataSpreadPercent
affects only the y-axis of the chart. The property
minXDataSpreadPercent
must be used to
enable the corresponding feature for the x-axis.
public void setMinLabelGap(java.lang.Integer minLabelGap) throws java.lang.IllegalStateException
labelCollapseMode
. Default is based on label orientation. If labels are vertical, the minimum gap is the height of half a line of text. If horizontal it's the width of 4 "X" letters.
minLabelGap
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Integer getMinLabelGap()
labelCollapseMode
. Default is based on label orientation. If labels are vertical, the minimum gap is the height of half a line of text. If horizontal it's the width of 4 "X" letters.
public void setMinXDataSpreadPercent(int minXDataSpreadPercent) throws java.lang.IllegalStateException
minXDataSpreadPercent
of the x-axis, the start
value of x-axis will be automatically adjusted to make better use of space. Setting an explicit xAxisStartValue
disables this behavior, as does setting
minXDataSpreadPercent
to 0.
minXDataSpreadPercent
- Default value is 30java.lang.IllegalStateException
- this property cannot be changed after the component has been createdsetMinDataSpreadPercent(int)
public int getMinXDataSpreadPercent()
minXDataSpreadPercent
of the x-axis, the start
value of x-axis will be automatically adjusted to make better use of space. Setting an explicit xAxisStartValue
disables this behavior, as does setting
minXDataSpreadPercent
to 0.
getMinDataSpreadPercent()
public void setPadChartRectByCornerRadius(boolean padChartRectByCornerRadius) throws java.lang.IllegalStateException
showChartRect
is enabled and if chartRectProperties
specifies a nonzero rounding
, whether the padding around the inside of the chart
rect. should include at least the radius of the rounded corner.padChartRectByCornerRadius
- Default value is truejava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic boolean getPadChartRectByCornerRadius()
showChartRect
is enabled and if chartRectProperties
specifies a nonzero rounding
, whether the padding around the inside of the chart
rect. should include at least the radius of the rounded corner.public void setPieBorderProperties(DrawOval pieBorderProperties) throws java.lang.IllegalStateException
pieBorderProperties
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic DrawOval getPieBorderProperties()
public void setPieLabelAngleStart(int pieLabelAngleStart) throws java.lang.IllegalStateException
pieLabelAngleStart
- Default value is 20java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic int getPieLabelAngleStart()
public void setPieLabelLineExtent(int pieLabelLineExtent) throws java.lang.IllegalStateException
pieLabelLineExtent
- Default value is 7java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic int getPieLabelLineExtent()
public void setPieLabelLineProperties(DrawLine pieLabelLineProperties)
pieLabelLineProperties
- Default value is nullpublic DrawLine getPieLabelLineProperties()
public void setPieRingBorderProperties(DrawOval pieRingBorderProperties) throws java.lang.IllegalStateException
pieRingBorderProperties
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic DrawOval getPieRingBorderProperties()
public void setPieSliceProperties(DrawSector pieSliceProperties) throws java.lang.IllegalStateException
pieSliceProperties
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic DrawSector getPieSliceProperties()
public void setPieStartAngle(java.lang.Integer pieStartAngle) throws java.lang.IllegalStateException
pieStartAngle
- Default value is 0java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Integer getPieStartAngle()
public void setPointColorLogBase(java.lang.Integer pointColorLogBase) throws java.lang.IllegalStateException
logScalePointColor
is true
,
this property specifies the base value for logarithmic color scale metric
values.pointColorLogBase
- Default value is 10java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Integer getPointColorLogBase()
logScalePointColor
is true
,
this property specifies the base value for logarithmic color scale metric
values.public void setPointShapes(PointShape... pointShapes) throws java.lang.IllegalStateException
showDataPoints
is enabled, this
property specifies an array of geometric shapes to draw for the data points of each series.pointShapes
- Default value is ["Oval", "Square", "Diamond", "Triangle"]java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic PointShape[] getPointShapes()
showDataPoints
is enabled, this
property specifies an array of geometric shapes to draw for the data points of each series.public void setPointSizeGradations(java.lang.Integer pointSizeGradations) throws java.lang.IllegalStateException
point size legend
is shown, this
property controls the number of gradations of the pointSizeMetric
that the chart tries to display. Note that if usePointSizeLogGradations
is set then the
number of gradations is not given by this property but rather by the entries of pointSizeLogGradations
.
pointSizeGradations
- Default value is 5java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Integer getPointSizeGradations()
point size legend
is shown, this
property controls the number of gradations of the pointSizeMetric
that the chart tries to display. Note that if usePointSizeLogGradations
is set then the
number of gradations is not given by this property but rather by the entries of pointSizeLogGradations
.
public void setPointSizeLogBase(java.lang.Integer pointSizeLogBase) throws java.lang.IllegalStateException
logScalePointSize
is true, base value for
logarithmic point size metric values.pointSizeLogBase
- Default value is 10java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Integer getPointSizeLogBase()
logScalePointSize
is true, base value for
logarithmic point size metric values.public void setPointSizeLogGradations(float... pointSizeLogGradations) throws java.lang.IllegalStateException
usePointSizeLogGradations
is set,
this property specifies the pointSizeMetric
value gradations to show in the point size
legend
in between powers, expressed as a series of integer or float values between 1 and pointSizeLogBase
.pointSizeLogGradations
- Default value is [1, 5]java.lang.IllegalStateException
- this property cannot be changed after the component has been createdsetLogGradations(float...)
public float[] getPointSizeLogGradations()
usePointSizeLogGradations
is set,
this property specifies the pointSizeMetric
value gradations to show in the point size
legend
in between powers, expressed as a series of integer or float values between 1 and pointSizeLogBase
.getLogGradations()
public void setPointSizeMetric(java.lang.String pointSizeMetric) throws java.lang.IllegalStateException
showDataPoints
is enabled, this
property specifies an additional metric (i.e. an "id" of a metric facet value) that determines the size of the data
points drawn. For example, when a circle is drawn to represent a data point then the size of the data point is the
diameter of the circle, in pixels. The size is calculated by linearly scaling the value of the
pointSizeMetric
of the point between the minDataPointSize
and maxDataPointSize
. The data point that has the lowest
value for the pointSizeMetric
will be drawn as a shape minDataPointSize
pixels in size, and
the data point that has the highest value for the pointSizeMetric
will be drawn as a shape
maxDataPointSize
pixels in size.
Using a log-scale to calulate the size of the data points is achieved
by enabling logScalePointSize
.
If the
ChartType
is "Bubble"
then the default pointSizeMetric
is
"pointSize"
.
Note that setting pointSizeMetric
to non-null
implicitly enables
showDataPoints
.
pointSizeMetric
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.String getPointSizeMetric()
showDataPoints
is enabled, this
property specifies an additional metric (i.e. an "id" of a metric facet value) that determines the size of the data
points drawn. For example, when a circle is drawn to represent a data point then the size of the data point is the
diameter of the circle, in pixels. The size is calculated by linearly scaling the value of the
pointSizeMetric
of the point between the minDataPointSize
and maxDataPointSize
. The data point that has the lowest
value for the pointSizeMetric
will be drawn as a shape minDataPointSize
pixels in size, and
the data point that has the highest value for the pointSizeMetric
will be drawn as a shape
maxDataPointSize
pixels in size.
Using a log-scale to calulate the size of the data points is achieved
by enabling logScalePointSize
.
If the
ChartType
is "Bubble"
then the default pointSizeMetric
is
"pointSize"
.
Note that setting pointSizeMetric
to non-null
implicitly enables
showDataPoints
.
public void setPrintZoomChart(boolean printZoomChart)
zoom chart
be printed with this
FacetChart
? If true
, then the SVG string returned by DrawPane.getSvgString()
will include the zoom chart's SVG as
well.
Note : This is an advanced setting
printZoomChart
- Default value is truePrinting overview and related methods
public boolean getPrintZoomChart()
zoom chart
be printed with this
FacetChart
? If true
, then the SVG string returned by DrawPane.getSvgString()
will include the zoom chart's SVG as
well.Printing overview and related methods
public void setProbabilityMetric(java.lang.String probabilityMetric) throws java.lang.IllegalStateException
FacetChart.getMean()
and FacetChart.getStdDev()
). The default value of this property is
null which causes the FacetChart to assign probabilities to the data records according to a uniform probability
distribution. Note that the FacetChart handles cases where the sum total of all probabilities in the data
is not exactly one by scaling the assigned probabilities.
probabilityMetric
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdgetMean(java.lang.String)
,
getMedian(java.lang.String)
,
getStdDev(java.lang.String, boolean)
,
getVariance(java.lang.String, boolean)
public java.lang.String getProbabilityMetric()
FacetChart.getMean()
and FacetChart.getStdDev()
). The default value of this property is
null which causes the FacetChart to assign probabilities to the data records according to a uniform probability
distribution. Note that the FacetChart handles cases where the sum total of all probabilities in the data
is not exactly one by scaling the assigned probabilities.
public void setProportional(java.lang.Boolean proportional)
Gradation labels will be switched to show percentage instead of absolute values.
This setting is valid only for
Column, Bar, Area and Radar chart types and only in stacked
mode. Stacked columns will be as tall as the chart rect and stacked bars will be as wide as the chart rect.
Area and Radar charts will be completely filled except for facet values where all values are 0.
If this method is called after the component has been drawn/initialized:
Setter for proportional
.
proportional
- Whether the chart should now use proportional mode.. Default value is nullpublic java.lang.Boolean getProportional()
Gradation labels will be switched to show percentage instead of absolute values.
This setting is valid only for
Column, Bar, Area and Radar chart types and only in stacked
mode. Stacked columns will be as tall as the chart rect and stacked bars will be as wide as the chart rect.
Area and Radar charts will be completely filled except for facet values where all values are 0.
public void setProportionalAxisLabel(java.lang.String proportionalAxisLabel) throws java.lang.IllegalStateException
proportional rendering mode
. This title will be used
unless the legend facet
defines a proportionalTitle
.proportionalAxisLabel
- Default value is "Percent"java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.String getProportionalAxisLabel()
proportional rendering mode
. This title will be used
unless the legend facet
defines a proportionalTitle
.public void setRadarBackgroundProperties(DrawOval radarBackgroundProperties) throws java.lang.IllegalStateException
radarBackgroundProperties
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic DrawOval getRadarBackgroundProperties()
public void setRadialLabelOffset(int radialLabelOffset) throws java.lang.IllegalStateException
radialLabelOffset
- Default value is 5java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic int getRadialLabelOffset()
public void setRegressionLineProperties(DrawLine regressionLineProperties) throws java.lang.IllegalStateException
regression line
.regressionLineProperties
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic DrawLine getRegressionLineProperties()
regression line
.public void setRegressionLineType(RegressionLineType regressionLineType)
regression
line
.
RegressionLineType
.regressionLineType
- New value for this.regressionLineType. Default value is "line"public RegressionLineType getRegressionLineType()
regression
line
.public void setRegressionPolynomialDegree(int regressionPolynomialDegree)
regressionPolynomialDegree
.regressionPolynomialDegree
- New value for this.regressionPolynomialDegree.. Default value is 3public int getRegressionPolynomialDegree()
public void setRotateLabels(LabelRotationMode rotateLabels) throws java.lang.IllegalStateException
rotateLabels
- Default value is "auto"java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic LabelRotationMode getRotateLabels()
public void setScaleEndColor(java.lang.String scaleEndColor)
color scale metric
. If neither this property nor the
scaleStartColor
is set then the whole color
range is used by default. Note that using CSS color shortcuts (e.g. "lightblue") is not allowed for this property.
If this method is called after the component has been drawn/initialized:
Setter for scaleEndColor
.
scaleEndColor
- The new end color for the color scale. See CSSColor
. Default value is nullpublic java.lang.String getScaleEndColor()
color scale metric
. If neither this property nor the
scaleStartColor
is set then the whole color
range is used by default. Note that using CSS color shortcuts (e.g. "lightblue") is not allowed for this property.
CSSColor
public void setScaleStartColor(java.lang.String scaleStartColor)
color scale metric
. If neither this property nor the
scaleEndColor
is set then the whole color range is
used by default. Note that using CSS color shortcuts (e.g. "lightblue") is not allowed for this property.
If this method is called after the component has been drawn/initialized:
Setter for scaleStartColor
.
scaleStartColor
- The new start color for the color scale. See CSSColor
. Default value is nullpublic java.lang.String getScaleStartColor()
color scale metric
. If neither this property nor the
scaleEndColor
is set then the whole color range is
used by default. Note that using CSS color shortcuts (e.g. "lightblue") is not allowed for this property.
CSSColor
public void setShadowProperties(DrawOval shadowProperties) throws java.lang.IllegalStateException
shadowProperties
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic DrawOval getShadowProperties()
public void setShowBubbleLegendPerShape(boolean showBubbleLegendPerShape) throws java.lang.IllegalStateException
Note
that this setting has no effect if useMultiplePointShapes
is disabled.
showBubbleLegendPerShape
- Default value is falsejava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic boolean getShowBubbleLegendPerShape()
Note
that this setting has no effect if useMultiplePointShapes
is disabled.
public void setShowChartRect(java.lang.Boolean showChartRect) throws java.lang.IllegalStateException
showChartRect
- Default value is falsejava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Boolean getShowChartRect()
public void setShowColorScaleLegend(java.lang.Boolean showColorScaleLegend) throws java.lang.IllegalStateException
true
if
a valid colorScaleMetric
is specified.showColorScaleLegend
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdsetScaleStartColor(java.lang.String)
,
setScaleEndColor(java.lang.String)
,
Color Scale Chart Examplepublic java.lang.Boolean getShowColorScaleLegend()
true
if
a valid colorScaleMetric
is specified.getScaleStartColor()
,
getScaleEndColor()
,
Color Scale Chart Examplepublic void setShowDataAxisLabel(java.lang.Boolean showDataAxisLabel) throws java.lang.IllegalStateException
title
for the data label facet will be shown as the label.
Automatically disabled for non-rectangular charts (eg Pie, Radar).
showDataAxisLabel
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Boolean getShowDataAxisLabel()
title
for the data label facet will be shown as the label.
Automatically disabled for non-rectangular charts (eg Pie, Radar).
public void setShowDataLabels(boolean showDataLabels) throws java.lang.IllegalStateException
false
, data labels for values are entirely omitted. This property would generally only be set
to false
if several small charts are shown together and the data labels are drawn elsewhere on the screen
(above an entire stack of charts, for instance) or are otherwise implicit.
showDataLabels
- Default value is truejava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic boolean getShowDataLabels()
false
, data labels for values are entirely omitted. This property would generally only be set
to false
if several small charts are shown together and the data labels are drawn elsewhere on the screen
(above an entire stack of charts, for instance) or are otherwise implicit.
public void setShowDataPoints(java.lang.Boolean showDataPoints) throws java.lang.IllegalStateException
If
shown, the FacetChart.pointClick()
and FacetChart.getPointHoverHTML()
APIs can be used to
create interactivity.
showDataPoints
- Default value is falsejava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Boolean getShowDataPoints()
If
shown, the FacetChart.pointClick()
and FacetChart.getPointHoverHTML()
APIs can be used to
create interactivity.
public void setShowDataValues(boolean showDataValues) throws java.lang.IllegalStateException
If set to false, then data values will not be shown.
If set to
true, data values will be shown unless the data density is high enough that labels will potentially overlap, in which
case, data values will not be shown and showValueOnHover
will be enabled instead.
showDataValues
- Default value is falsejava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic boolean getShowDataValues()
If set to false, then data values will not be shown.
If set to
true, data values will be shown unless the data density is high enough that labels will potentially overlap, in which
case, data values will not be shown and showValueOnHover
will be enabled instead.
public void setShowDoughnut(java.lang.Boolean showDoughnut) throws java.lang.IllegalStateException
showDoughnut
.showDoughnut
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Boolean getShowDoughnut()
showDoughnut
.public void setShowExpectedValueLine(java.lang.Boolean showExpectedValueLine) throws java.lang.IllegalStateException
mean value
. Note that this
expected value is computed using all of the data points, pooled across all facets. The computation relies only on the
values of the main value axis metric and the probability metric
.
showExpectedValueLine
- Default value is falsejava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Boolean getShowExpectedValueLine()
mean value
. Note that this
expected value is computed using all of the data points, pooled across all facets. The computation relies only on the
values of the main value axis metric and the probability metric
.
public void setShowGradationsOverData(java.lang.Boolean showGradationsOverData) throws java.lang.IllegalStateException
showGradationsOverData
- Default value is falsejava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Boolean getShowGradationsOverData()
public void setShowInlineLabels(java.lang.Boolean showInlineLabels) throws java.lang.IllegalStateException
showInlineLabels
- Default value is falsejava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Boolean getShowInlineLabels()
public void setShowLegend(java.lang.Boolean showLegend) throws java.lang.IllegalStateException
showLegend
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Boolean getShowLegend()
public void setShowPointSizeLegend(java.lang.Boolean showPointSizeLegend) throws java.lang.IllegalStateException
point size
. The default is true
for
bubble charts and false
for all other chart types.showPointSizeLegend
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdsetPointSizeGradations(java.lang.Integer)
,
setUsePointSizeLogGradations(java.lang.Boolean)
,
setPointSizeLogGradations(float...)
,
setShowBubbleLegendPerShape(boolean)
,
Bubble Chart Examplepublic java.lang.Boolean getShowPointSizeLegend()
point size
. The default is true
for
bubble charts and false
for all other chart types.public void setShowRadarGradationLabels(java.lang.Boolean showRadarGradationLabels) throws java.lang.IllegalStateException
showRadarGradationLabels
- Default value is truejava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Boolean getShowRadarGradationLabels()
public void setShowRegressionLine(java.lang.Boolean showRegressionLine)
The type of regression curve used depends on the RegressionLineType
property,
which can be:
regressionPolynomialDegree
).Note that the regression is computed using all of the data points and it does not depend on the values of any non-metric facets. For example, adding a legend facet will not change the regression curve.
See http://en.wikipedia.org/wiki/Simple_linear_regression.
See http://en.wikipedia.org/wiki/Polynomial_regression.
If this method is called after the component has been drawn/initialized:
Setter for showRegressionLine
.
showRegressionLine
- New value for this.showRegressionLine.. Default value is falsesetXAxisMetric(java.lang.String)
,
setYAxisMetric(java.lang.String)
,
setRegressionLineProperties(com.smartgwt.client.widgets.drawing.DrawLine)
public java.lang.Boolean getShowRegressionLine()
The type of regression curve used depends on the RegressionLineType
property,
which can be:
regressionPolynomialDegree
).Note that the regression is computed using all of the data points and it does not depend on the values of any non-metric facets. For example, adding a legend facet will not change the regression curve.
See http://en.wikipedia.org/wiki/Simple_linear_regression. See http://en.wikipedia.org/wiki/Polynomial_regression.
getXAxisMetric()
,
getYAxisMetric()
,
getRegressionLineProperties()
public void setShowScatterLines(java.lang.Boolean showScatterLines)
DataLineType
for enabling smoothing.
showScatterLines
. Will redraw the chart if drawn.showScatterLines
- whether to draw lines between adjacent data points in "Scatter" plots. Default value is falsepublic java.lang.Boolean getShowScatterLines()
DataLineType
for enabling smoothing.public void setShowShadows(java.lang.Boolean showShadows) throws java.lang.IllegalStateException
showShadows
- Default value is truejava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Boolean getShowShadows()
public void setShowStandardDeviationLines(java.lang.Boolean showStandardDeviationLines) throws java.lang.IllegalStateException
standard deviations
away from the mean
as lines. The exact deviations to display can be customized with standardDeviations
. Note that these standard
deviations are computed using all of the data points, pooled across all facets. The computation relies only on the
values of the main value axis metric and the probability metric
.
showStandardDeviationLines
- Default value is falsejava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Boolean getShowStandardDeviationLines()
standard deviations
away from the mean
as lines. The exact deviations to display can be customized with standardDeviations
. Note that these standard
deviations are computed using all of the data points, pooled across all facets. The computation relies only on the
values of the main value axis metric and the probability metric
.
public void setShowStatisticsOverData(java.lang.Boolean showStatisticsOverData) throws java.lang.IllegalStateException
mean line
, standard deviation lines
, standard deviation bands
, and regression curves
are drawn on top of the data
rather than underneath.showStatisticsOverData
- Default value is falsejava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Boolean getShowStatisticsOverData()
mean line
, standard deviation lines
, standard deviation bands
, and regression curves
are drawn on top of the data
rather than underneath.public void setShowTitle(java.lang.Boolean showTitle)
showTitle
- Default value is truepublic java.lang.Boolean getShowTitle()
public void setShowValueAxisLabel(java.lang.Boolean showValueAxisLabel) throws java.lang.IllegalStateException
valueTitle
(or, in the case of
proportional rendering mode
, the proportionalAxisLabel
) as a label on the value
axis. Automatically disabled for non-rectangular charts (eg Pie, Radar).
showValueAxisLabel
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Boolean getShowValueAxisLabel()
valueTitle
(or, in the case of
proportional rendering mode
, the proportionalAxisLabel
) as a label on the value
axis. Automatically disabled for non-rectangular charts (eg Pie, Radar).
public void setShowValueOnHover(java.lang.Boolean showValueOnHover) throws java.lang.IllegalStateException
Calculates nearest value based on FacetChart.getNearestDrawnValue()
.
The data value
will be formatted using FacetChart.formatDataValue()
. The label's appearance is controlled by hoverLabelProperties
.
showValueOnHover
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Boolean getShowValueOnHover()
Calculates nearest value based on FacetChart.getNearestDrawnValue()
.
The data value
will be formatted using FacetChart.formatDataValue()
. The label's appearance is controlled by hoverLabelProperties
.
public void setStacked(java.lang.Boolean stacked)
stacked
. Use null to apply a default value for the current chartType
.stacked
- new value. Default value is nullpublic java.lang.Boolean getStacked()
public void setStandardDeviationBandProperties(DrawItem... standardDeviationBandProperties) throws java.lang.IllegalStateException
standard deviation lines
. The length of the
Array must be one less than the length of the standardDeviations
Array. Having no band between certain standard deviations from the mean can be specified by having a null element at the corresponding index of this Array.
Note that if useSymmetricStandardDeviations
is set
then for each standard deviation band that is drawn a corresponding band will also be drawn on the opposite side of the
mean line.
standardDeviationBandProperties
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic DrawItem[] getStandardDeviationBandProperties()
standard deviation lines
. The length of the
Array must be one less than the length of the standardDeviations
Array. Having no band between certain standard deviations from the mean can be specified by having a null element at the corresponding index of this Array.
Note that if useSymmetricStandardDeviations
is set
then for each standard deviation band that is drawn a corresponding band will also be drawn on the opposite side of the
mean line.
public void setStandardDeviationLineProperties(DrawItem standardDeviationLineProperties) throws java.lang.IllegalStateException
standard deviation
lines
. Note that for rectangular charts the properties are for a DrawLine
, and for radar charts the properties are for a DrawOval
.
standardDeviationLineProperties
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic DrawItem getStandardDeviationLineProperties()
standard deviation
lines
. Note that for rectangular charts the properties are for a DrawLine
, and for radar charts the properties are for a DrawOval
.
public void setStandardDeviations(float... standardDeviations) throws java.lang.IllegalStateException
showStandardDeviationLines
is
set, the number of standard deviation lines drawn
and their respective standard deviation away from the mean are specified by this property.
The default is to display lines corresponding to the mean plus or minus one standard
deviation.
Note that having zero in this list of standard deviations is identical to drawing a line at the mean.
For example assume that chart1 and chart2 both plot data with mean 1 and standard deviation 0.1. chart1 will draw a blue line at the value 1 and two red lines at the values 0.7 and 1.2. chart2 will draw three red lines at values 0.9, 1.0, and 1.1.
DrawLine blueLine = new DrawLine(), redLine = new DrawLine(); blueLine.setLineColor("blue"); redLine.setLineColor("red"); FacetChart chart1 = new FacetChart(); chart1.setID("chart1"); chart1.setStandardDeviations(new Float[] { -3f, 2f }); chart1.setShowExpectedValueLine(true); chart1.setShowStandardDeviationLines(true); chart1.setExpectedValueLineProperties(blueLine); chart1.setStandardDeviationLineProperties(redLine); chart1.setUseSymmetricStandardDeviations(false); // ... FacetChart chart2 = new FacetChart(); chart2.setID("chart2"); chart2.setStandardDeviations(new Float[] { -1f, 0f, 1f }); chart2.setShowExpectedValueLine(false); chart2.setShowStandardDeviationLines(true); chart2.setExpectedValueLineProperties(blueLine); chart2.setStandardDeviationLineProperties(redLine); chart2.setUseSymmetricStandardDeviations(false); // ... chart1.draw(); chart2.draw();
standardDeviations
- Default value is [-1, 1]java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic float[] getStandardDeviations()
showStandardDeviationLines
is
set, the number of standard deviation lines drawn
and their respective standard deviation away from the mean are specified by this property.
The default is to display lines corresponding to the mean plus or minus one standard
deviation.
Note that having zero in this list of standard deviations is identical to drawing a line at the mean.
For example assume that chart1 and chart2 both plot data with mean 1 and standard deviation 0.1. chart1 will draw a blue line at the value 1 and two red lines at the values 0.7 and 1.2. chart2 will draw three red lines at values 0.9, 1.0, and 1.1.
DrawLine blueLine = new DrawLine(), redLine = new DrawLine(); blueLine.setLineColor("blue"); redLine.setLineColor("red"); FacetChart chart1 = new FacetChart(); chart1.setID("chart1"); chart1.setStandardDeviations(new Float[] { -3f, 2f }); chart1.setShowExpectedValueLine(true); chart1.setShowStandardDeviationLines(true); chart1.setExpectedValueLineProperties(blueLine); chart1.setStandardDeviationLineProperties(redLine); chart1.setUseSymmetricStandardDeviations(false); // ... FacetChart chart2 = new FacetChart(); chart2.setID("chart2"); chart2.setStandardDeviations(new Float[] { -1f, 0f, 1f }); chart2.setShowExpectedValueLine(false); chart2.setShowStandardDeviationLines(true); chart2.setExpectedValueLineProperties(blueLine); chart2.setStandardDeviationLineProperties(redLine); chart2.setUseSymmetricStandardDeviations(false); // ... chart1.draw(); chart2.draw();
public void setStyleName(java.lang.String styleName)
setStyleName
in class Canvas
styleName
- See CSSStyleName
. Default value is "scChart"Appearance overview and related methods
,
CSS styles Examplepublic java.lang.String getStyleName()
getStyleName
in class Canvas
CSSStyleName
Appearance overview and related methods
,
CSS styles Examplepublic void setTickMarkToValueAxisMargin(int tickMarkToValueAxisMargin) throws java.lang.IllegalStateException
extra value axes
.tickMarkToValueAxisMargin
- Default value is 7java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic int getTickMarkToValueAxisMargin()
extra value axes
.public void setTitle(java.lang.String title)
public java.lang.String getTitle()
public void setTitleProperties(DrawLabel titleProperties)
titleProperties
- Default value is nullpublic DrawLabel getTitleProperties()
public void setUseAutoGradients(java.lang.Boolean useAutoGradients) throws java.lang.IllegalStateException
dataColors
but specify chart-specific gradients based on the primary data color per chart type.useAutoGradients
- Default value is truejava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Boolean getUseAutoGradients()
dataColors
but specify chart-specific gradients based on the primary data color per chart type.public void setUseLogGradations(java.lang.Boolean useLogGradations) throws java.lang.IllegalStateException
Default gradations can be overridden via logBase
and
logGradations
.
useLogGradations
- Default value is falsejava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Boolean getUseLogGradations()
Default gradations can be overridden via logBase
and
logGradations
.
public void setUseMultiplePointShapes(java.lang.Boolean useMultiplePointShapes)
true
then the chart is allowed
to use all supported shapes
: circles, squares,
diamonds, and triangles. If set to false
then just the first supported shape (circles, for example) will
be used. The default is false
for bubble charts and color scale charts
and true
for all other
chart types.
useMultiplePointShapes
.useMultiplePointShapes
- Whether the chart should now use multiple shapes to show data points.. Default value is nullpublic java.lang.Boolean getUseMultiplePointShapes()
true
then the chart is allowed
to use all supported shapes
: circles, squares,
diamonds, and triangles. If set to false
then just the first supported shape (circles, for example) will
be used. The default is false
for bubble charts and color scale charts
and true
for all other
chart types.public void setUsePointSizeLogGradations(java.lang.Boolean usePointSizeLogGradations) throws java.lang.IllegalStateException
pointSizeMetric
values displayed in the point size legend
.
Gradations also begin and end on an order of magnitude. For example, 1, 2, 4, 6, 8, 10, 20, 40, 60, 80, 100.
Default gradations can be overridden via pointSizeLogBase
and pointSizeLogGradations
.
usePointSizeLogGradations
- Default value is falsejava.lang.IllegalStateException
- this property cannot be changed after the component has been createdsetUseLogGradations(java.lang.Boolean)
public java.lang.Boolean getUsePointSizeLogGradations()
pointSizeMetric
values displayed in the point size legend
.
Gradations also begin and end on an order of magnitude. For example, 1, 2, 4, 6, 8, 10, 20, 40, 60, 80, 100.
Default gradations can be overridden via pointSizeLogBase
and pointSizeLogGradations
.
getUseLogGradations()
public void setUseSymmetricStandardDeviations(java.lang.Boolean useSymmetricStandardDeviations) throws java.lang.IllegalStateException
standard deviations
.useSymmetricStandardDeviations
- Default value is truejava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Boolean getUseSymmetricStandardDeviations()
standard deviations
.public void setValueAxisLabelProperties(DrawLabel valueAxisLabelProperties)
valueAxisLabelProperties
- Default value is nullpublic DrawLabel getValueAxisLabelProperties()
public void setValueAxisMargin(int valueAxisMargin) throws java.lang.IllegalStateException
multiple value axes
.valueAxisMargin
- Default value is 10java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic int getValueAxisMargin()
multiple value axes
.public void setValueLineProperties(DrawLine valueLineProperties) throws java.lang.IllegalStateException
valueLineProperties
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic DrawLine getValueLineProperties()
public void setValueProperty(java.lang.String valueProperty) throws java.lang.IllegalStateException
Not used if there is an inline facet, see data.
valueProperty
- Default value is "_value"java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.String getValueProperty()
Not used if there is an inline facet, see data.
public void setValueTitle(java.lang.String valueTitle) throws java.lang.IllegalStateException
valueTitle
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.String getValueTitle()
public void setXAxisMetric(java.lang.String xAxisMetric) throws java.lang.IllegalStateException
The default x-axis metric is the second value of the metric facet.
xAxisMetric
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.String getXAxisMetric()
The default x-axis metric is the second value of the metric facet.
public void setXAxisStartValue(java.lang.Double xAxisStartValue) throws java.lang.IllegalStateException
Defaults to 0, or to a value that makes good use
of horizontal space based on minXDataSpreadPercent
.
xAxisStartValue
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdsetAxisStartValue(java.lang.Double)
public java.lang.Double getXAxisStartValue()
Defaults to 0, or to a value that makes good use
of horizontal space based on minXDataSpreadPercent
.
getAxisStartValue()
public void setYAxisMetric(java.lang.String yAxisMetric) throws java.lang.IllegalStateException
The default y-axis metric is the first value of the metric facet.
yAxisMetric
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.String getYAxisMetric()
The default y-axis metric is the first value of the metric facet.
public FacetChart getZoomChart() throws java.lang.IllegalStateException
canZoom
is
enabled. This chart automatically has certain visual tweaks applied, including showInlineLabels
, muted colors
and logarithmic scaling
. It can be further configured via
zoomChartProperties
.
The selected range
from this chart defaults to being shown with distinct styling as well (if zoomShowSelection
is set), which can be controlled
via zoomSelectionChartProperties
.
For an overview of how to use and configure AutoChildren, see Using AutoChildren
.
java.lang.IllegalStateException
- if this widget has not yet been rendered.public void setZoomChartHeight(double zoomChartHeight) throws java.lang.IllegalStateException
zoomChart
. The zoomChart is always as
wide as the main chart.zoomChartHeight
- Default value is 100java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic double getZoomChartHeight()
zoomChart
. The zoomChart is always as
wide as the main chart.public void setZoomChartProperties(FacetChart zoomChartProperties) throws java.lang.IllegalStateException
zoomChart
.zoomChartProperties
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic FacetChart getZoomChartProperties()
zoomChart
.public RangeSlider getZoomChartSlider() throws java.lang.IllegalStateException
canZoom
is enabled.
For an overview of how to use and configure AutoChildren, see Using AutoChildren
.
java.lang.IllegalStateException
- if this widget has not yet been rendered.public void setZoomLogScale(java.lang.Boolean zoomLogScale) throws java.lang.IllegalStateException
canZoom
is enabled, the zoomChart
uses logarithmic scaling so that spikes in the data
don't result in a zoomed chart that is mostly a flat line. Logarithmic scaling is automatically disabled if the dataset spans zero (eg, has negative and positive values) as this can't be shown in a logarithmic scale.
Set
zoomLogScale
to explicitly enable or disable logarithmic scaling.
zoomLogScale
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Boolean getZoomLogScale()
canZoom
is enabled, the zoomChart
uses logarithmic scaling so that spikes in the data
don't result in a zoomed chart that is mostly a flat line. Logarithmic scaling is automatically disabled if the dataset spans zero (eg, has negative and positive values) as this can't be shown in a logarithmic scale.
Set
zoomLogScale
to explicitly enable or disable logarithmic scaling.
public void setZoomMutePercent(float zoomMutePercent) throws java.lang.IllegalStateException
colorMutePercent
to use for the zoomChart
.zoomMutePercent
- Default value is -35java.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic float getZoomMutePercent()
colorMutePercent
to use for the zoomChart
.public FacetChart getZoomSelectionChart() throws java.lang.IllegalStateException
canZoom
is enabled. This chart
represents the currently selected range of data shown in the main chart.
For an overview of how to use and configure AutoChildren, see Using AutoChildren
.
java.lang.IllegalStateException
- if this widget has not yet been rendered.public void setZoomSelectionChartProperties(FacetChart zoomSelectionChartProperties) throws java.lang.IllegalStateException
zoomSelectionChart
.zoomSelectionChartProperties
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic FacetChart getZoomSelectionChartProperties()
zoomSelectionChart
.public void setZoomShowSelection(java.lang.Boolean zoomShowSelection) throws java.lang.IllegalStateException
zoomSelectionChartProperties
. This has
performance consequences and makes the rendering of the mini-chart slightly slower.zoomShowSelection
- Default value is truejava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic java.lang.Boolean getZoomShowSelection()
zoomSelectionChartProperties
. This has
performance consequences and makes the rendering of the mini-chart slightly slower.public void setZoomStartPosition(ZoomStartPosition zoomStartPosition) throws java.lang.IllegalStateException
zoomed chart
, determines what portion of the
overall dataset should be initially shown in the main chart. Default is to show the end of the dataset if the X axis shows time and includes today's date, otherwise to show the start of the dataset.
Set this property to override this
default, or use zoomStartValue
and zoomEndValue
to start with a particular range.
zoomStartPosition
- Default value is nulljava.lang.IllegalStateException
- this property cannot be changed after the component has been createdpublic ZoomStartPosition getZoomStartPosition()
zoomed chart
, determines what portion of the
overall dataset should be initially shown in the main chart. Default is to show the end of the dataset if the X axis shows time and includes today's date, otherwise to show the start of the dataset.
Set this property to override this
default, or use zoomStartValue
and zoomEndValue
to start with a particular range.
public HandlerRegistration addChartBackgroundDrawnHandler(ChartBackgroundDrawnHandler handler)
Called when most elements of the chart other than data data have been drawn, including gradations and legend.
This notification will be fired each time the chart is redrawn (due to resize, data change, etc). If you want to draw
additional information on the chart using DrawPane
(FacetChart's superclass)
and various DrawItem
s, you should do in response to this notification. Due
to auto-sizing, APIs that are typically used to position custom DrawItems (such as FacetChart.getChartLeft()
) may return bad values if called at
other times.
Additional DrawItems added in this method will appear underneath data elements such as bars or columns.
See FacetChart.chartDrawn()
for placing
DrawItems on top of data elements.
addChartBackgroundDrawnHandler
in interface HasChartBackgroundDrawnHandlers
handler
- the chartBackgroundDrawn handlerHandlerRegistration
used to remove this handlerpublic HandlerRegistration addChartDrawnHandler(ChartDrawnHandler handler)
Called when all elements of the chart (data lines / shapes, gradations, legend, labels etc) have completed drawing.
See FacetChart.chartBackgroundDrawn()
for usage information.
addChartDrawnHandler
in interface HasChartDrawnHandlers
handler
- the chartDrawn handlerHandlerRegistration
used to remove this handlerpublic HandlerRegistration addDataLabelClickHandler(DataLabelClickHandler handler)
Fires when the user clicks on a data label, that is, a text label showing values from the first facet. For example, the labels underneath the X-axis of a column chart, labelling each column.
addDataLabelClickHandler
in interface HasDataLabelClickHandlers
handler
- the dataLabelClick handlerHandlerRegistration
used to remove this handlerpublic HandlerRegistration addDataLabelHoverHandler(DataLabelHoverHandler handler)
Fires when the mouse hovers over a data label, that is, a text label showing values from the first facet. For example, the labels underneath the X-axis of a column chart, labelling each column.
addDataLabelHoverHandler
in interface HasDataLabelHoverHandlers
handler
- the dataLabelHover handlerHandlerRegistration
used to remove this handlerpublic java.lang.Boolean drawnValueContainsPoint(DrawnValue drawnValue)
DrawnValue
contains a point. The point's X and Y
coordinates may be passed into this method, or, if unspecified, the coordinates used are the current mouse event
coordinates. For Area, Bubble, Line, Radar, and Scatter charts, a DrawnValue is considered to contain a point if the
Euclidean distance from the DrawnValue's center (x
, y
) to the point is less than this.dataPointSize
. For Pie charts, the DrawnValue is
considered to contain a point if the point is within the pie slice. Similarly, for Doughnut charts, the DrawnValue is
considered to contain a point if the point is within the pie slice and not in the doughnut hole. For Bar and Column
charts, the DrawnValue is considered to contain a point if the point is within the bar or column, respectively. Note
that for stacked Bar and Column charts, the point must also be in the stacked portion as opposed to anywhere within the
bar or column.
drawnValue
- the DrawnValue to check. The DrawnValue must be a valid DrawnValue from this chart.public java.lang.Boolean drawnValueContainsPoint(DrawnValue drawnValue, java.lang.Integer x)
public java.lang.Boolean drawnValueContainsPoint(DrawnValue drawnValue, java.lang.Integer x, java.lang.Integer y)
DrawnValue
contains a point. The point's X and Y
coordinates may be passed into this method, or, if unspecified, the coordinates used are the current mouse event
coordinates. For Area, Bubble, Line, Radar, and Scatter charts, a DrawnValue is considered to contain a point if the
Euclidean distance from the DrawnValue's center (x
, y
) to the point is less than this.dataPointSize
. For Pie charts, the DrawnValue is
considered to contain a point if the point is within the pie slice. Similarly, for Doughnut charts, the DrawnValue is
considered to contain a point if the point is within the pie slice and not in the doughnut hole. For Bar and Column
charts, the DrawnValue is considered to contain a point if the point is within the bar or column, respectively. Note
that for stacked Bar and Column charts, the point must also be in the stacked portion as opposed to anywhere within the
bar or column.
drawnValue
- the DrawnValue to check. The DrawnValue must be a valid DrawnValue from this chart.x
- X coordinate of the point. If this parameter is specified, then y
is a required parameter.y
- Y coordinate of the pointpublic Point getChartCenter()
Note that unstacked pie charts draw multiple pies, each with their own centers.
This is only allowed to be called when FacetChart.chartDrawn()
fires.
public float getChartHeight(boolean recalc)
GwtFloatVsDouble
This is only allowed to be called when FacetChart.chartDrawn()
fires.
recalc
- if false then cached value will be returned, otherwise will be recalculated.public double getChartHeightAsDouble(boolean recalc)
This is only allowed to be called when FacetChart.chartDrawn()
fires.
recalc
- if false then cached value will be returned, otherwise will be recalculated.public float getChartLeft()
GwtFloatVsDouble
This is only allowed to be called when
FacetChart.chartDrawn()
fires.
public double getChartLeftAsDouble()
This is only allowed to be called when
FacetChart.chartDrawn()
fires.
public float getChartRadius()
GwtFloatVsDouble
Note that unstacked pie charts draw multiple pies, each with their own radii.
This is only allowed to be called when
FacetChart.chartDrawn()
fires.
public double getChartRadiusAsDouble()
Note that unstacked pie charts draw multiple pies, each with their own radii.
This is only allowed to be called when
FacetChart.chartDrawn()
fires.
public float getChartTop()
GwtFloatVsDouble
This is only allowed to be called
when FacetChart.chartDrawn()
fires.
public double getChartTopAsDouble()
This is only allowed to be called
when FacetChart.chartDrawn()
fires.
public float getChartWidth(boolean recalc)
GwtFloatVsDouble
This is only allowed to be called when FacetChart.chartDrawn()
fires.
recalc
- if false then cached value will be returned, otherwise will be recalculated.public double getChartWidthAsDouble(boolean recalc)
This is only allowed to be called when FacetChart.chartDrawn()
fires.
recalc
- if false then cached value will be returned, otherwise will be recalculated.public java.lang.String getDataColor(int index)
dataColors
Arrayindex
- index of the visual element to be coloredpublic Facet getDataLabelFacet()
Facet
in the list of facets
whose values
are rendered as labels along the data axis of the chart or in
the main chart area. Most single-facet charts and all multi-facet charts have the data label facet as their first facet. The exceptions are that single-facet Pie/Doughnut charts and Bubble and Scatter charts do not have data label facets.
Note that the user may swap the data label facet and the legend facet
in most chart types using the context menu.
null
if there is no such facetgetFacets()
public java.lang.String getDataLabelHoverHTML(FacetValue facetValue)
facetValue
- facetValue that was hoveredpublic DrawnValue getDrawnValue(FacetValueMap facetValues)
If called before FacetChart.chartDrawn()
, logs a warning and returns
null.
facetValues
- facet values of desired data valuepublic DrawnValue getDrawnValueAtPoint()
DrawnValue
object for the data value that is shown nearest to the
passed coordinates only if it's under the given coordinates, or under the current mouse event coordinates if no
coordinates are passed. This method is similar to FacetChart.getNearestDrawnValue()
, but the DrawnValue
is only returned if it's under the coordinates. See FacetChart.drawnValueContainsPoint()
for the
criteria that determine whether a DrawnValue is under (contains) the coordinates.
public DrawnValue getDrawnValueAtPoint(java.lang.Integer x)
getDrawnValueAtPoint()
public DrawnValue getDrawnValueAtPoint(java.lang.Integer x, java.lang.Integer y)
getDrawnValueAtPoint()
public DrawnValue getDrawnValueAtPoint(java.lang.Integer x, java.lang.Integer y, java.lang.String metric)
DrawnValue
object for the data value that is shown nearest to the
passed coordinates only if it's under the given coordinates, or under the current mouse event coordinates if no
coordinates are passed. This method is similar to FacetChart.getNearestDrawnValue()
, but the DrawnValue
is only returned if it's under the coordinates. See FacetChart.drawnValueContainsPoint()
for the
criteria that determine whether a DrawnValue is under (contains) the coordinates.
x
- X coordinate. If this parameter is specified, then y
is a required parameter.y
- Y coordinatemetric
- metric over which to determine the drawn valuepublic DrawnValue[] getDrawnValues()
If called before FacetChart.chartDrawn()
, logs a warning and returns
null.
public DrawnValue[] getDrawnValues(FacetValueMap facetValues)
If called before FacetChart.chartDrawn()
, logs a warning and returns
null.
facetValues
- facet values of desired DrawnValues. If no FacetValueMap is provided, then all DrawnValues are returned.public DrawnValue[] getDrawnValuesAtPoint()
DrawnValue
objects for the data values of each metric that
are shown nearest to the passed coordinates, but only if they're under the given coordinates, or under the current mouse
event coordinates if no coordinates are passed. This method is similar to FacetChart.getNearestDrawnValues()
, but DrawnValues
are only included in the returned array if they're under the coordinates. See FacetChart.drawnValueContainsPoint()
for the
criteria that determine whether a DrawnValue is under (contains) the coordinates.
public DrawnValue[] getDrawnValuesAtPoint(java.lang.Integer x)
getDrawnValuesAtPoint()
public DrawnValue[] getDrawnValuesAtPoint(java.lang.Integer x, java.lang.Integer y)
DrawnValue
objects for the data values of each metric that
are shown nearest to the passed coordinates, but only if they're under the given coordinates, or under the current mouse
event coordinates if no coordinates are passed. This method is similar to FacetChart.getNearestDrawnValues()
, but DrawnValues
are only included in the returned array if they're under the coordinates. See FacetChart.drawnValueContainsPoint()
for the
criteria that determine whether a DrawnValue is under (contains) the coordinates.
x
- X coordinate. If this parameter is specified, then y
is a required parameter.y
- Y coordinatepublic Facet getFacet(java.lang.String facetId)
facetId
- the id of the facet to retrieveFacet
public FacetValue getFacetValue(java.lang.String facetId, java.lang.String facetValueId)
facetId
- the id of the facet to retrievefacetValueId
- the id of the facet value to retrieveFacetValue
public float[] getGradations()
FacetChart.getXCoord()
/ FacetChart.getYCoord()
(depending on the orientation of the
chart) to discover the coordinates where gradations are drawn. This is only allowed to be called when FacetChart.chartDrawn()
fires.
public Facet getLegendFacet()
Facet
in the list of facets
whose values
are rendered in the chart's legend. Most single-facet charts do not have a legend facet. The exceptions are that single-facet Pie/Doughnut charts have a legend facet as the first facet and Bubble and Scatter charts may optionally have a legend facet as the second facet, after the metric facet.
In all multi-facet charts, the legend facet is the second facet.
Note that the user may swap the legend
facet and the data label facet
in most chart
types using the context menu.
null
if there is no such facetgetFacets()
public java.lang.String getLegendHoverHTML(FacetValue facetValue, FacetValue metricFacetValue)
The FacetValue
that the user is hovering over is provided. If the chart is a multi-axis chart
, the FacetValue
for the hovered-over metric will also be provided.
facetValue
- facetValue that the mouse is overmetricFacetValue
- for a multi-axis chart, facetValue representing the hovered-over metric. Null if chart is not multi-axispublic DrawnValue getNearestDrawnValue()
DrawnValue
object. Passed X and Y coordinates should be relative to the
FacetChart. If neither an X or Y coordinate is passed, both X and Y will use the current Canvas.getOffsetX()
and Canvas.getOffsetY()
.
If called before FacetChart.chartDrawn()
, logs a warning and returns
null. For a chart with multiple vertical axes, returns the nearest point from the first metric only (see FacetChart overview
). For scatter charts, returns a DrawnValue where the
value
is from the y-axis metric
.
To get the nearest DrawnValue only if it
contains the given coordinates, you can either use the FacetChart.getDrawnValueAtPoint()
API or call FacetChart.drawnValueContainsPoint()
on the return
value.
Behavior for different chart types is as follows:
Returns the centerpoint of the end of the nearest bar or column by considering the Y coordinate (bar) or X coordinate (column) only.
Returns the nearest point based on which data label is nearest to the passed X coordinate. For multi-series charts, if Y coordinate is not passed the data point returned is from the series that has the highest value at the data label.
Returns the data point nearest the passed coordinates by straight line
distance. Passing only one coordinate will cause a warning to be logged and null to be returned; passing neither
coordinate is allowed (getOffsetX/Y
will be used).
Returns the data point for the segment that would be hit if a line were drawn from the passed coordinates to the center of the pie.
If there are multiple stacked pies, uses the pie that contains the passed coordinates, otherwise the outermost pie.
If there are multiple non-stacked pies, uses the pie that is nearest the passed coordinates by straight-line distance to the center of the pie.
Passing only one coordinate will cause a warning to be logged and null to be returned; passing neither
coordinate is allowed (getOffsetX/Y
will be used).
If the chart is a multi-axis chart
then this method takes an optional
parameter, metric
, which causes this method to return a DrawnValue
from the specified metric.
If a metric is not passed then the first metric of the metric facet will be used (or just the valueProperty
if there is no metric facet).
public DrawnValue getNearestDrawnValue(java.lang.Integer x)
getNearestDrawnValue()
public DrawnValue getNearestDrawnValue(java.lang.Integer x, java.lang.Integer y)
getNearestDrawnValue()
public DrawnValue getNearestDrawnValue(java.lang.Integer x, java.lang.Integer y, java.lang.String metric)
DrawnValue
object. Passed X and Y coordinates should be relative to the
FacetChart. If neither an X or Y coordinate is passed, both X and Y will use the current Canvas.getOffsetX()
and Canvas.getOffsetY()
.
If called before FacetChart.chartDrawn()
, logs a warning and returns
null. For a chart with multiple vertical axes, returns the nearest point from the first metric only (see FacetChart overview
). For scatter charts, returns a DrawnValue where the
value
is from the y-axis metric
.
To get the nearest DrawnValue only if it
contains the given coordinates, you can either use the FacetChart.getDrawnValueAtPoint()
API or call FacetChart.drawnValueContainsPoint()
on the return
value.
Behavior for different chart types is as follows:
Returns the centerpoint of the end of the nearest bar or column by considering the Y coordinate (bar) or X coordinate (column) only.
Returns the nearest point based on which data label is nearest to the passed X coordinate. For multi-series charts, if Y coordinate is not passed the data point returned is from the series that has the highest value at the data label.
Returns the data point nearest the passed coordinates by straight line
distance. Passing only one coordinate will cause a warning to be logged and null to be returned; passing neither
coordinate is allowed (getOffsetX/Y
will be used).
Returns the data point for the segment that would be hit if a line were drawn from the passed coordinates to the center of the pie.
If there are multiple stacked pies, uses the pie that contains the passed coordinates, otherwise the outermost pie.
If there are multiple non-stacked pies, uses the pie that is nearest the passed coordinates by straight-line distance to the center of the pie.
Passing only one coordinate will cause a warning to be logged and null to be returned; passing neither
coordinate is allowed (getOffsetX/Y
will be used).
If the chart is a multi-axis chart
then this method takes an optional
parameter, metric
, which causes this method to return a DrawnValue
from the specified metric.
If a metric is not passed then the first metric of the metric facet will be used (or just the valueProperty
if there is no metric facet).
x
- X coordinate. If this parameter is specified, then y
is a required parameter.y
- Y coordinatemetric
- metric over which to determine the drawn valuepublic DrawnValue[] getNearestDrawnValues()
DrawnValue
objects containing rendering information for
the data values having each metric that are shown nearest to the passed coordinates. Passed X and Y coordinates
should be relative to the FacetChart. If neither an X or Y coordinate is passed, both X and Y will use the current
Canvas.getOffsetX()
and Canvas.getOffsetY()
.
The behavior for different chart types is the
same as FacetChart.getNearestDrawnValue()
.
This method also logs a warning and returns null if called before FacetChart.chartDrawn()
.
To get the nearest
DrawnValues only if they contain the given coordinates, you can either use the FacetChart.getDrawnValuesAtPoint()
API or check
whether each DrawnValue in the returned array contains the point by calling FacetChart.drawnValueContainsPoint()
.
getDrawnValuesAtPoint()
public DrawnValue[] getNearestDrawnValues(java.lang.Integer x)
getNearestDrawnValues()
public DrawnValue[] getNearestDrawnValues(java.lang.Integer x, java.lang.Integer y)
DrawnValue
objects containing rendering information for
the data values having each metric that are shown nearest to the passed coordinates. Passed X and Y coordinates
should be relative to the FacetChart. If neither an X or Y coordinate is passed, both X and Y will use the current
Canvas.getOffsetX()
and Canvas.getOffsetY()
.
The behavior for different chart types is the
same as FacetChart.getNearestDrawnValue()
.
This method also logs a warning and returns null if called before FacetChart.chartDrawn()
.
To get the nearest
DrawnValues only if they contain the given coordinates, you can either use the FacetChart.getDrawnValuesAtPoint()
API or check
whether each DrawnValue in the returned array contains the point by calling FacetChart.drawnValueContainsPoint()
.
x
- X coordinate. If this parameter is specified, then y
is a required parameter.y
- Y coordinategetDrawnValuesAtPoint()
public java.lang.Integer getNumDataPoints()
public java.lang.Integer getNumDataPoints(FacetValueMap criteria)
criteria
- a set of facetValues describing a slice of the datapublic void getPolynomialRegressionFunction()
public void getPolynomialRegressionFunction(java.lang.Integer degree)
getPolynomialRegressionFunction()
public void getPolynomialRegressionFunction(java.lang.Integer degree, java.lang.String xMetric)
getPolynomialRegressionFunction()
public void getPolynomialRegressionFunction(java.lang.Integer degree, java.lang.String xMetric, java.lang.String yMetric)
degree
- the degree of the polynomial. Defaults to regressionPolynomialDegree
.xMetric
- ID of an inlined facet value to use as the independent variable. Defaults to the x-axis metric
.yMetric
- ID of an inlined facet value to use as the dependent variable. Defaults to the y-axis metric
.public void getSimpleLinearRegressionFunction()
public void getSimpleLinearRegressionFunction(java.lang.String xMetric)
getSimpleLinearRegressionFunction()
public void getSimpleLinearRegressionFunction(java.lang.String xMetric, java.lang.String yMetric)
xMetric
- ID of an inlined facet value to use as the independent variable. Defaults to the x-axis metric
.yMetric
- ID of an inlined facet value to use as the dependent variable. Defaults to the y-axis metric
.public HandlerRegistration addLegendClickHandler(LegendClickHandler handler)
Fires when the user clicks on the legend area of the chart.
If the user specifically clicks on a color swatch or
it's label, the FacetValue
clicked on will be provided.
If the chart is a
multi-axis chart
, the FacetValue
for the clicked-on metric will also be provided.
addLegendClickHandler
in interface HasLegendClickHandlers
handler
- the legendClick handlerHandlerRegistration
used to remove this handlerpublic HandlerRegistration addLegendHoverHandler(LegendHoverHandler handler)
Fires when the mouse hovers over a color swatch or its label in the legend area of the chart.
The FacetValue
that the user is hovering over is provided. If the chart is a multi-axis chart
, the FacetValue
for the hovered-over metric will also be provided.
addLegendHoverHandler
in interface HasLegendHoverHandlers
handler
- the legendHover handlerHandlerRegistration
used to remove this handlerpublic HandlerRegistration addValueClickHandler(ValueClickHandler handler)
Fires when a data value is clicked, and provides information about the data value that was clicked as a DrawnValue
object.
Specifically, this fires for clicks on pie slices, bars or columns, areas, lines or points (in a Bubble or Scatter plot).
If there are multiple data values at the clicked
position, you can use FacetChart.getNearestDrawnValues()
to discover the full list of values at the current coordinate (pass in getOffsetX/Y()
for the coordinates).
If you want to create behaviors
for clicking or moving near shapes without requiring a direct hit, implement a standard Canvas.click()
handler on the FacetChart as a whole and use FacetChart.getNearestDrawnValue()
to discover the
nearest data values.
addValueClickHandler
in interface HasValueClickHandlers
handler
- the valueClick handlerHandlerRegistration
used to remove this handlerpublic HandlerRegistration addZoomChangedHandler(ZoomChangedHandler handler)
Fires when the end user changes the zoom position in a zoomed chart
.
addZoomChangedHandler
in interface HasZoomChangedHandlers
handler
- the zoomChanged handlerHandlerRegistration
used to remove this handlerpublic void zoomTo(java.lang.Object startValue, java.lang.Object endValue)
startValue
- starting value for the data range shown in the main chartendValue
- ending value for the data range shown in the main chartpublic static void setDefaultProperties(FacetChart facetChartProperties)
Note: This method is intended for setting default attributes only and will affect all instances of the underlying class (including those automatically generated in JavaScript). This method should not be used to apply standard EventHandlers or override methods for a class - use a custom subclass instead. Calling this method after instances have been created can result in undefined behavior, since it bypasses any setters and a class instance may have already examined a particular property and not be expecting any changes through this route.
facetChartProperties
- properties that should be used as new defaults when instances of this class are createdpublic void setData(Record[] records)
Data should be specified as an array of Records where each record contains one data value. Each record also contains a property named after each facetId whose value is a facetValueId from that facet.
For example, with
a facet with id "regions" and facetValues "west", "north" and "east", and
with valueProperty
with it's default value
"_value", the
data
property
could be:
isc.Chart.create({ facets:[{ id:"regions" }], data : [ {regions:"west", _value:4}, {regions:"north", _value:2}, {regions:"east", _value:5} ] })If there were a second facet with id "product" and facetValues "cars" and "trucks", a Chart with a complete set of values would be:
isc.Chart.create({ facets:[{ id:"regions" }, { id:"product" }], data : [ {product:"cars", regions:"west", _value:4}, {product:"cars", regions:"north", _value:2}, {product:"cars", regions:"east", _value:5}, {product:"trucks", regions:"west", _value:1}, {product:"trucks", regions:"north", _value:9}, {product:"trucks", regions:"east", _value:3} ] })This 2 facet (or "2 dimensional") dataset, if rendered as a bar chart, would use stacked or clustered bars and a legend.
data
- data Default value is nullpublic void setData(RecordList records)
public Record[] getRecords()
public RecordList getDataAsRecordList()
public void setPointHoverCustomizer(ChartPointHoverCustomizer hoverCustomizer)
showDataPoints
is true and the mouse hovers
over a point.hoverCustomizer
- public void setDataLabelHoverHTMLCustomizer(DataLabelHoverCustomizer dataLabelHoverHTMLCustomizer)
dataLabelHoverHTMLCustomizer
- public void setLegendHoverCustomizer(LegendHoverCustomizer legendHoverHTMLCustomizer)
The +link{FacetValue} that the user is hovering over is provided. If the chart is a +link{facetChart.extraAxisMetrics,multi-axis chart}, the +link{FacetValue} for the hovered-over metric will also be provided.
facetValue
- (FacetValue) facetValue that the mouse is overmetricFacetValue
- (FacetValue) for a multi-axis chart, facetValue representing
the hovered-over metric. Null if chart is not multi-axispublic void setPointClickHandler(ChartPointClickHandler handler)
showDataPoints
is true,
and the user clicks on a point.handler
- public java.lang.String getPrintHTML(PrintProperties printProperties, PrintHTMLCallback callback)
By default any Canvas with children will simply collect the printable HTML of its
children by calling getPrintHTML() on each child that is considered
printable
.
If overriding this method for a custom component, you should either return a String of printable HTML string directly or return null, and fire the callback (if provided).
To return an empty print representation, return an empty string ("") rather than null.
The printProperties
argument, if passed, must be passed to any subcomponents on
which getPrintHTML()
is called.
Notes on printing
To print a FacetChart
for export on IE8 and earlier, it is
PrintProperties
with printForExport
:true:
final PrintProperties pp = new PrintProperties(); pp.setPrintForExport(true); final String exportHTML = chart.getPrintHTML(pp, null);
Note: this is an override point.
getPrintHTML
in class DrawPane
printProperties
- properties to configure printing behavior - may be null.callback
- optional callback to fire. Generated HTML should be passed to the
PrintHTMLCallback.setHTML(String)
method of the callback.Printing overview and related methods
public void setZoomStartValue(java.lang.Object zoomStartValue)
zoomed chart
, start value of the data range shown
in the main chart. If zoomEndValue
is not also
set, the range shown will be from zoomStartValue
to the end of the dataset. The value provided should
be a value in the range of the facet for the X axis, for example, for a time-based axis, a Date instance, for a numeric
axis, a Number, for an axis that just has text labels (such as city names), a String.
If this method is called after the component has been drawn/initialized:
Setter for zoomStartValue
.
Note that the zoomStartValue
and zoomEndValue
may be set simultaneously using FacetChart.zoomTo
.
zoomStartValue
- New start value for the data range shown in the main chart. Default value is nullpublic java.lang.Object getZoomStartValue()
zoomed chart
, start value of the data range shown
in the main chart. If zoomEndValue
is not also
set, the range shown will be from zoomStartValue
to the end of the dataset. The value provided should be a value in the range of the facet for the X axis, for example, for a time-based axis, a Date instance, for a numeric axis, a Number, for an axis that just has text labels (such as city names), a String.
public void setZoomEndValue(java.lang.Object zoomEndValue)
zoomed chart
, end value of the data range shown in
the main chart. If zoomStartValue
is not also
set, the range shown will be from the beginning of the dataset up to zoomEndValue
The value provided
should be a value in the range of the facet for the X axis, for example, for a time-based axis, a Date instance, for a
numeric axis, a Number, for an axis that just has text labels (such as city names), a String.
If this method is called after the component has been drawn/initialized:
Setter for zoomEndValue
.
Note that the zoomStartValue
and zoomEndValue
may be set simultaneously using FacetChart.zoomTo
.
zoomEndValue
- New end value for the data range shown in the main chart. Default value is nullpublic java.lang.Object getZoomEndValue()
zoomed chart
, end value of the data range shown in
the main chart. If zoomStartValue
is not also
set, the range shown will be from the beginning of the dataset up to zoomEndValue
The value provided should be a value in the range of the facet for the X axis, for example, for a time-based axis, a Date instance, for a numeric axis, a Number, for an axis that just has text labels (such as city names), a String.
public void setAxisValueFormatter(ValueFormatter formatter)
formatter
- Formatter to apply to values displayed in the gradation labelspublic void setXAxisValueFormatter(ValueFormatter formatter)
formatter
- Formatter to apply to values displayed in the gradation labelspublic void setYAxisValueFormatter(ValueFormatter formatter)
formatter
- Formatter to apply to values displayed in the gradation labelspublic void setDataValueFormatter(ValueFormatter formatter)
formatter
- Formatter to apply to values displayed in the hover labels and other value labelspublic float getXCoord(FacetValueMap criteria)
This is only allowed to be called when FacetChart.chartDrawn
fires.
Note that this method is only applicable to area
, column
, and
line
charts.
criteria
- A complete mapping of the data facets to specify the unique data cell of the value to be drawn.public float getXCoord(float value)
This is only allowed to be called when FacetChart.chartDrawn
fires.
Note that this method is only applicable to bar
and scatter
charts.
value
- the value to be drawn.public float getYCoord(FacetValueMap criteria)
This is only allowed to be
called when FacetChart.chartDrawn
fires.
Note that this method is only applicable to bar
charts.
criteria
- A complete mapping of the data facets to specify the unique data cell of the value to be drawn.public float getYCoord(float value)
This is only allowed to be
called when FacetChart.chartDrawn
fires.
Note that this method is only applicable to area
, column
,
line
, and ChartType.SCATTER
charts.
value
- the value to be drawn.public java.lang.Float getMean(java.lang.String criteria)
The first
argument, criteria, determines which metric is used to calculate the mean. The criteria may be a String that is the "id"
of some FacetValue
of the metric facet, or a FacetValueMap
that contains an entry for the metric facet, or null to use the valueProperty
. A FacetValueMap criteria may also be used
to restrict the calculation to a slice of the data.
criteria
- the "id" of a metric facet value, or a set of mappings describing the data over which to calculate, or nullpublic java.lang.Float getMean(FacetValueMap criteria)
The first
argument, criteria, determines which metric is used to calculate the mean. The criteria may be a String that is the "id"
of some FacetValue
of the metric facet, or a FacetValueMap
that contains an entry for the metric facet, or null to use the valueProperty
. A FacetValueMap criteria may also be used
to restrict the calculation to a slice of the data.
criteria
- the "id" of a metric facet value, or a set of mappings describing the data over which to calculate, or nullpublic java.lang.Float getMedian(java.lang.String criteria)
The first argument, criteria,
determines which metric is used to calculate the median. The criteria may be a String that is the "id" of some FacetValue
of the metric facet, or a FacetValueMap
that contains an entry for the metric facet, or null to use the valueProperty
. A FacetValueMap criteria may also be used
to restrict the calculation to a slice of the data.
criteria
- the "id" of a metric facet value, or a set of mappings describing the data over which to calculate, or nullpublic java.lang.Float getMedian(FacetValueMap criteria)
The first argument, criteria,
determines which metric is used to calculate the median. The criteria may be a String that is the "id" of some FacetValue
of the metric facet, or a FacetValueMap
that contains an entry for the metric facet, or null to use the valueProperty
. A FacetValueMap criteria may also be used
to restrict the calculation to a slice of the data.
criteria
- the "id" of a metric facet value, or a set of mappings describing the data over which to calculate, or nullpublic java.lang.Float getPercentile(java.lang.String criteria, float percentile)
The first argument,
criteria, determines which metric is used to calculate a percentile. The criteria may be a String that is the "id" of
some FacetValue
of the metric facet, or a FacetValueMap
that contains an entry for the metric facet, or null to use the valueProperty
. A FacetValueMap criteria may also be used
to restrict the calculation to a slice of the data.
The second argument is the percentile to calculate and it must be a number from 0 to 100.
criteria
- the "id" of a metric facet value, or a set of mappings describing the data over which to calculate, or nullpercentile
- the percentile to calculatepublic java.lang.Float getPercentile(FacetValueMap criteria, float percentile)
The first argument,
criteria, determines which metric is used to calculate a percentile. The criteria may be a String that is the "id" of
some FacetValue
of the metric facet, or a FacetValueMap
that contains an entry for the metric facet, or null to use the valueProperty
. A FacetValueMap criteria may also be used
to restrict the calculation to a slice of the data.
The second argument is the percentile to calculate and it must be a number from 0 to 100.
criteria
- the "id" of a metric facet value, or a set of mappings describing the data over which to calculate, or nullpercentile
- the percentile to calculatepublic java.lang.Float getRange(java.lang.String criteria)
The first argument, criteria, determines which metric is used
to calculate the range. The criteria may be a String that is the "id" of some FacetValue
of the metric facet, or a FacetValueMap
that contains an entry for the metric facet, or null to use the valueProperty
. A FacetValueMap criteria may also be used
to restrict the calculation to a slice of the data.
criteria
- the "id" of a metric facet value, or a set of mappings describing the data over which to calculate, or nullpublic java.lang.Float getRange(FacetValueMap criteria)
The first argument, criteria, determines which metric is used
to calculate the range. The criteria may be a String that is the "id" of some FacetValue
of the metric facet, or a FacetValueMap
that contains an entry for the metric facet, or null to use the valueProperty
. A FacetValueMap criteria may also be used
to restrict the calculation to a slice of the data.
criteria
- the "id" of a metric facet value, or a set of mappings describing the data over which to calculate, or nullpublic java.lang.Float getStdDev(java.lang.String criteria, boolean population)
The
first argument, criteria, determines which metric is used to calculate the standard deviation. The criteria may be a
String that is the "id" of some FacetValue
of the metric facet, or a FacetValueMap
that contains an entry for the metric facet, or null to use the valueProperty
. A FacetValueMap criteria may also be used
to restrict the calculation to a slice of the data.
criteria
- the "id" of a metric facet value, or a set of mappings describing the data over which to calculate, or nullpopulation
- false to calculate a sample standard deviation, true to calculate a population standard deviationpublic java.lang.Float getStdDev(FacetValueMap criteria, boolean population)
The
first argument, criteria, determines which metric is used to calculate the standard deviation. The criteria may be a
String that is the "id" of some FacetValue
of the metric facet, or a FacetValueMap
that contains an entry for the metric facet, or null to use the valueProperty
. A FacetValueMap criteria may also be used
to restrict the calculation to a slice of the data.
criteria
- the "id" of a metric facet value, or a set of mappings describing the data over which to calculate, or nullpopulation
- false to calculate a sample standard deviation, true to calculate a population standard deviationpublic java.lang.Float getVariance(java.lang.String criteria, boolean population)
The first argument,
criteria, determines which metric is used to calculate the variance. The criteria may be a String that is the "id" of
some FacetValue
of the metric facet, or a FacetValueMap
that contains an entry for the metric facet, or null to use the valueProperty
. A FacetValueMap criteria may also be used
to restrict the calculation to a slice of the data.
criteria
- the "id" of a metric facet value, or a set of mappings describing the data over which to calculate, or nullpopulation
- false to calculate a sample variance, true to calculate a population variancepublic java.lang.Float getVariance(FacetValueMap criteria, boolean population)
The first argument,
criteria, determines which metric is used to calculate the variance. The criteria may be a String that is the "id" of
some FacetValue
of the metric facet, or a FacetValueMap
that contains an entry for the metric facet, or null to use the valueProperty
. A FacetValueMap criteria may also be used
to restrict the calculation to a slice of the data.
criteria
- the "id" of a metric facet value, or a set of mappings describing the data over which to calculate, or nullpopulation
- false to calculate a sample variance, true to calculate a population variancepublic java.lang.Float getMax(java.lang.String criteria)
The first argument, criteria, determines which metric is
used to calculate the maximum. The criteria may be a String that is the "id" of some FacetValue
of the metric facet, or a FacetValueMap
that contains an entry for the metric facet, or null to use the valueProperty
. A FacetValueMap criteria may also be used
to restrict the calculation to a slice of the data.
criteria
- the "id" of a metric facet value, or a set of mappings describing the data over which to calculate, or nullpublic java.lang.Float getMax(FacetValueMap criteria)
The first argument, criteria, determines which metric is
used to calculate the maximum. The criteria may be a String that is the "id" of some FacetValue
of the metric facet, or a FacetValueMap
that contains an entry for the metric facet, or null to use the valueProperty
. A FacetValueMap criteria may also be used
to restrict the calculation to a slice of the data.
criteria
- the "id" of a metric facet value, or a set of mappings describing the data over which to calculate, or nullpublic java.lang.Float getMin(java.lang.String criteria)
The first argument, criteria, determines which metric is
used to calculate the minimum. The criteria may be a String that is the "id" of some FacetValue
of the metric facet, or a FacetValueMap
that contains an entry for the metric facet, or null to use the valueProperty
. A FacetValueMap criteria may also be used
to restrict the calculation to a slice of the data.
criteria
- the "id" of a metric facet value, or a set of mappings describing the data over which to calculate, or nullpublic java.lang.Float getMin(FacetValueMap criteria)
The first argument, criteria, determines which metric is
used to calculate the minimum. The criteria may be a String that is the "id" of some FacetValue
of the metric facet, or a FacetValueMap
that contains an entry for the metric facet, or null to use the valueProperty
. A FacetValueMap criteria may also be used
to restrict the calculation to a slice of the data.
criteria
- the "id" of a metric facet value, or a set of mappings describing the data over which to calculate, or nullpublic com.smartgwt.logicalstructure.core.LogicalStructureObject setLogicalStructure(com.smartgwt.logicalstructure.widgets.chart.FacetChartLogicalStructure s)
LogicalStructure
interface,
which supports Eclipse's logical structure debugging facility.public com.smartgwt.logicalstructure.core.LogicalStructureObject getLogicalStructure()
LogicalStructure
interface,
which supports Eclipse's logical structure debugging facility.getLogicalStructure
in interface LogicalStructure
getLogicalStructure
in class DrawPane