diff --git a/lib/index.js b/lib/index.js
index 77d07357c88..d702fd1ba4d 100644
--- a/lib/index.js
+++ b/lib/index.js
@@ -50,6 +50,7 @@ Plotly.register([
require('./scatterpolar'),
require('./scatterpolargl'),
require('./barpolar'),
+ require('./scattersmith'),
// transforms
require('./aggregate'),
diff --git a/lib/scattersmith.js b/lib/scattersmith.js
new file mode 100644
index 00000000000..93e87bfbbf3
--- /dev/null
+++ b/lib/scattersmith.js
@@ -0,0 +1,3 @@
+'use strict';
+
+module.exports = require('../src/traces/scattersmith');
diff --git a/src/components/modebar/manage.js b/src/components/modebar/manage.js
index 718a790f5e3..e75c1c34409 100644
--- a/src/components/modebar/manage.js
+++ b/src/components/modebar/manage.js
@@ -110,6 +110,7 @@ function getButtonGroups(gd) {
var hasTernary = fullLayout._has('ternary');
var hasMapbox = fullLayout._has('mapbox');
var hasPolar = fullLayout._has('polar');
+ var hasSmith = fullLayout._has('smith');
var hasSankey = fullLayout._has('sankey');
var allAxesFixed = areAllAxesFixed(fullLayout);
var hasUnifiedHoverLabel = isUnifiedHover(fullLayout.hovermode);
@@ -152,7 +153,7 @@ function getButtonGroups(gd) {
var resetGroup = [];
var dragModeGroup = [];
- if((hasCartesian || hasGL2D || hasPie || hasFunnelarea || hasTernary) + hasGeo + hasGL3D + hasMapbox + hasPolar > 1) {
+ if((hasCartesian || hasGL2D || hasPie || hasFunnelarea || hasTernary) + hasGeo + hasGL3D + hasMapbox + hasPolar + hasSmith > 1) {
// graphs with more than one plot types get 'union buttons'
// which reset the view or toggle hover labels across all subplots.
hoverGroup = ['toggleHover'];
@@ -175,7 +176,7 @@ function getButtonGroups(gd) {
} else if(hasSankey) {
hoverGroup = ['hoverClosestCartesian', 'hoverCompareCartesian'];
resetGroup = ['resetViewSankey'];
- } else { // hasPolar, hasTernary
+ } else { // hasPolar, hasSmith, hasTernary
// always show at least one hover icon.
hoverGroup = ['toggleHover'];
}
diff --git a/src/plot_api/plot_api.js b/src/plot_api/plot_api.js
index 2848063d2e4..1a9386a3915 100644
--- a/src/plot_api/plot_api.js
+++ b/src/plot_api/plot_api.js
@@ -3729,6 +3729,9 @@ function makePlotFramework(gd) {
// single polar layer for the whole plot
fullLayout._polarlayer = fullLayout._paper.append('g').classed('polarlayer', true);
+ // single smith layer for the whole plot
+ fullLayout._smithlayer = fullLayout._paper.append('g').classed('smithlayer', true);
+
// single ternary layer for the whole plot
fullLayout._ternarylayer = fullLayout._paper.append('g').classed('ternarylayer', true);
diff --git a/src/plots/cartesian/axes.js b/src/plots/cartesian/axes.js
index dd35b78a28f..6f03bfc517b 100644
--- a/src/plots/cartesian/axes.js
+++ b/src/plots/cartesian/axes.js
@@ -1462,7 +1462,7 @@ function formatDate(ax, out, hover, extraPrecision) {
dateStr += '
' + headStr;
} else {
var isInside = insideTicklabelposition(ax);
- var side = ax._realSide || ax.side; // polar mocks the side of the radial axis
+ var side = ax._trueSide || ax.side; // polar mocks the side of the radial axis
if(
(!isInside && side === 'top') ||
(isInside && side === 'bottom')
@@ -3269,7 +3269,7 @@ axes.drawLabels = function(gd, ax, opts) {
var pad = !isAligned ? 0 :
(ax.tickwidth || 0) + 2 * TEXTPAD;
- var rotate90 = (tickSpacing < maxFontSize * 2.5) || ax.type === 'multicategory';
+ var rotate90 = (tickSpacing < maxFontSize * 2.5) || ax.type === 'multicategory' || ax._name === 'realaxis';
// any overlap at all - set 30 degrees or 90 degrees
for(i = 0; i < lbbArray.length - 1; i++) {
diff --git a/src/plots/cartesian/set_convert.js b/src/plots/cartesian/set_convert.js
index 31a274811c8..c8d00c9bbde 100644
--- a/src/plots/cartesian/set_convert.js
+++ b/src/plots/cartesian/set_convert.js
@@ -449,6 +449,7 @@ module.exports = function setConvert(ax, fullLayout) {
if(ax.type === 'date') dflt = Lib.dfltRange(ax.calendar);
else if(axLetter === 'y') dflt = constants.DFLTRANGEY;
+ else if(ax._name === 'realaxis') dflt = [0, 1];
else dflt = opts.dfltRange || constants.DFLTRANGEX;
// make sure we don't later mutate the defaults
diff --git a/src/plots/cartesian/tick_label_defaults.js b/src/plots/cartesian/tick_label_defaults.js
index ce09aba6a04..6097ae1d2b2 100644
--- a/src/plots/cartesian/tick_label_defaults.js
+++ b/src/plots/cartesian/tick_label_defaults.js
@@ -27,7 +27,8 @@ module.exports = function handleTickLabelDefaults(containerIn, containerOut, coe
size: font.size,
color: dfltFontColor
});
- coerce('tickangle');
+
+ if(!options.noAng) coerce('tickangle');
if(axType !== 'category') {
var tickFormat = coerce('tickformat');
@@ -41,7 +42,7 @@ module.exports = function handleTickLabelDefaults(containerIn, containerOut, coe
delete containerOut.tickformatstops;
}
- if(!tickFormat && axType !== 'date') {
+ if(!options.noExp && !tickFormat && axType !== 'date') {
coerce('showexponent', showAttrDflt);
coerce('exponentformat');
coerce('minexponent');
diff --git a/src/plots/cartesian/tick_mark_defaults.js b/src/plots/cartesian/tick_mark_defaults.js
index 88e499decd0..6a76c37142b 100644
--- a/src/plots/cartesian/tick_mark_defaults.js
+++ b/src/plots/cartesian/tick_mark_defaults.js
@@ -8,7 +8,7 @@ var layoutAttributes = require('./layout_attributes');
/**
* options: inherits outerTicks from axes.handleAxisDefaults
*/
-module.exports = function handleTickDefaults(containerIn, containerOut, coerce, options) {
+module.exports = function handleTickMarkDefaults(containerIn, containerOut, coerce, options) {
var tickLen = Lib.coerce2(containerIn, containerOut, layoutAttributes, 'ticklen');
var tickWidth = Lib.coerce2(containerIn, containerOut, layoutAttributes, 'tickwidth');
var tickColor = Lib.coerce2(containerIn, containerOut, layoutAttributes, 'tickcolor', containerOut.color);
diff --git a/src/plots/polar/layout_defaults.js b/src/plots/polar/layout_defaults.js
index cbcf08cc9d4..dbcaece4794 100644
--- a/src/plots/polar/layout_defaults.js
+++ b/src/plots/polar/layout_defaults.js
@@ -62,14 +62,6 @@ function handleDefaults(contIn, contOut, coerce, opts) {
coerceAxis('uirevision', contOut.uirevision);
- var dfltColor;
- var dfltFontColor;
-
- if(visible) {
- dfltColor = coerceAxis('color');
- dfltFontColor = (dfltColor === axIn.color) ? dfltColor : opts.font.color;
- }
-
// We don't want to make downstream code call ax.setScale,
// as both radial and angular axes don't have a set domain.
// Furthermore, angular axes don't have a set range.
@@ -91,18 +83,6 @@ function handleDefaults(contIn, contOut, coerce, opts) {
coerceAxis('range');
axOut.cleanRange('range', {dfltRange: [0, 1]});
-
- if(visible) {
- coerceAxis('side');
- coerceAxis('angle', sector[0]);
-
- coerceAxis('title.text');
- Lib.coerceFont(coerceAxis, 'title.font', {
- family: opts.font.family,
- size: Lib.bigFont(opts.font.size),
- color: dfltFontColor
- });
- }
break;
case 'angularaxis':
@@ -142,20 +122,27 @@ function handleDefaults(contIn, contOut, coerce, opts) {
});
if(visible) {
+ var dfltColor;
+ var dfltFontColor;
+ var dfltFontSize;
+ var dfltFontFamily;
+ var font = opts.font || {};
+
+ dfltColor = coerceAxis('color');
+ dfltFontColor = (dfltColor === axIn.color) ? dfltColor : font.color;
+ dfltFontSize = font.size;
+ dfltFontFamily = font.family;
+
handleTickValueDefaults(axIn, axOut, coerceAxis, axOut.type);
- handleTickLabelDefaults(axIn, axOut, coerceAxis, axOut.type);
- handleTickMarkDefaults(axIn, axOut, coerceAxis, {outerTicks: true});
+ handleTickLabelDefaults(axIn, axOut, coerceAxis, axOut.type, {
+ font: {
+ color: dfltFontColor,
+ size: dfltFontSize,
+ family: dfltFontFamily
+ }
+ });
- var showTickLabels = coerceAxis('showticklabels');
- if(showTickLabels) {
- Lib.coerceFont(coerceAxis, 'tickfont', {
- family: opts.font.family,
- size: opts.font.size,
- color: dfltFontColor
- });
- coerceAxis('tickangle');
- coerceAxis('tickformat');
- }
+ handleTickMarkDefaults(axIn, axOut, coerceAxis, {outerTicks: true});
handleLineGridDefaults(axIn, axOut, coerceAxis, {
dfltColor: dfltColor,
@@ -170,6 +157,18 @@ function handleDefaults(contIn, contOut, coerce, opts) {
});
coerceAxis('layer');
+
+ if(axName === 'radialaxis') {
+ coerceAxis('side');
+ coerceAxis('angle', sector[0]);
+
+ coerceAxis('title.text');
+ Lib.coerceFont(coerceAxis, 'title.font', {
+ color: dfltFontColor,
+ size: Lib.bigFont(dfltFontSize),
+ family: dfltFontFamily
+ });
+ }
}
if(axType !== 'category') coerceAxis('hoverformat');
diff --git a/src/plots/polar/polar.js b/src/plots/polar/polar.js
index a94f42baa22..30cc3f0608c 100644
--- a/src/plots/polar/polar.js
+++ b/src/plots/polar/polar.js
@@ -29,12 +29,19 @@ var MID_SHIFT = require('../../constants/alignment').MID_SHIFT;
var constants = require('./constants');
var helpers = require('./helpers');
+var smithHelpers = require('../smith/helpers');
+var smith = smithHelpers.smith;
+var reactanceArc = smithHelpers.reactanceArc;
+var resistanceArc = smithHelpers.resistanceArc;
+var smithTransform = smithHelpers.smithTransform;
+
var _ = Lib._;
var mod = Lib.mod;
var deg2rad = Lib.deg2rad;
var rad2deg = Lib.rad2deg;
-function Polar(gd, id) {
+function Polar(gd, id, isSmith) {
+ this.isSmith = isSmith || false;
this.id = id;
this.gd = gd;
@@ -55,45 +62,70 @@ function Polar(gd, id) {
.attr('id', this.clipIds.forTraces);
this.clipPaths.forTraces.append('path');
- this.framework = fullLayout._polarlayer.append('g')
+ this.framework = fullLayout['_' + (isSmith ? 'smith' : 'polar') + 'layer'].append('g')
.attr('class', id);
- // unfortunately, we have to keep track of some axis tick settings
- // as polar subplots do not implement the 'ticks' editType
- this.radialTickLayout = null;
- this.angularTickLayout = null;
+ this.getHole = function(s) {
+ return this.isSmith ? 0 : s.hole;
+ };
+
+ this.getSector = function(s) {
+ return this.isSmith ? [0, 360] : s.sector;
+ };
+
+ this.getRadial = function(s) {
+ return this.isSmith ? s.realaxis : s.radialaxis;
+ };
+
+ this.getAngular = function(s) {
+ return this.isSmith ? s.imaginaryaxis : s.angularaxis;
+ };
+
+ if(!isSmith) {
+ // unfortunately, we have to keep track of some axis tick settings
+ // as polar subplots do not implement the 'ticks' editType
+ this.radialTickLayout = null;
+ this.angularTickLayout = null;
+ }
}
var proto = Polar.prototype;
-module.exports = function createPolar(gd, id) {
- return new Polar(gd, id);
+module.exports = function createPolar(gd, id, isSmith) {
+ return new Polar(gd, id, isSmith);
};
proto.plot = function(polarCalcData, fullLayout) {
var _this = this;
var polarLayout = fullLayout[_this.id];
- _this._hasClipOnAxisFalse = false;
+ var found = false;
for(var i = 0; i < polarCalcData.length; i++) {
var trace = polarCalcData[i][0].trace;
if(trace.cliponaxis === false) {
- _this._hasClipOnAxisFalse = true;
+ found = true;
break;
}
}
+ _this._hasClipOnAxisFalse = found;
_this.updateLayers(fullLayout, polarLayout);
_this.updateLayout(fullLayout, polarLayout);
Plots.generalUpdatePerTraceModule(_this.gd, _this, polarCalcData, polarLayout);
_this.updateFx(fullLayout, polarLayout);
+
+ if(_this.isSmith) {
+ delete polarLayout.realaxis.range;
+ delete polarLayout.imaginaryaxis.range;
+ }
};
proto.updateLayers = function(fullLayout, polarLayout) {
var _this = this;
+ var isSmith = _this.isSmith;
var layers = _this.layers;
- var radialLayout = polarLayout.radialaxis;
- var angularLayout = polarLayout.angularaxis;
+ var radialLayout = _this.getRadial(polarLayout);
+ var angularLayout = _this.getAngular(polarLayout);
var layerNames = constants.layerNames;
var frontPlotIndex = layerNames.indexOf('frontplot');
@@ -113,18 +145,22 @@ proto.updateLayers = function(fullLayout, polarLayout) {
if(!isAngularAxisBelowTraces) layerData.push('angular-axis');
if(!isRadialAxisBelowTraces) layerData.push('radial-axis');
- var join = _this.framework.selectAll('.polarsublayer')
+ var subLayer = (isSmith ? 'smith' : 'polar') + 'sublayer';
+
+ var join = _this.framework.selectAll('.' + subLayer)
.data(layerData, String);
join.enter().append('g')
- .attr('class', function(d) { return 'polarsublayer ' + d;})
+ .attr('class', function(d) { return subLayer + ' ' + d;})
.each(function(d) {
var sel = layers[d] = d3.select(this);
switch(d) {
case 'frontplot':
// TODO add option to place in 'backplot' layer??
- sel.append('g').classed('barlayer', true);
+ if(!isSmith) {
+ sel.append('g').classed('barlayer', true);
+ }
sel.append('g').classed('scatterlayer', true);
break;
case 'backplot':
@@ -153,12 +189,12 @@ proto.updateLayers = function(fullLayout, polarLayout) {
/* Polar subplots juggle with 6 'axis objects' (!), these are:
*
- * - polarLayout.radialaxis (aka radialLayout in this file):
- * - polarLayout.angularaxis (aka angularLayout in this file):
+ * - getRadial(polarLayout) (aka radialLayout in this file):
+ * - getAngular(polarLayout) (aka angularLayout in this file):
* used for data -> calcdata conversions (aka d2c) during the calc step
*
* - this.radialAxis
- * extends polarLayout.radialaxis, adds mocked 'domain' and
+ * extends getRadial(polarLayout), adds mocked 'domain' and
* few other keys in order to reuse Cartesian doAutoRange and the Axes
* drawing routines.
* used for calcdata -> geometric conversions (aka c2g) during the plot step
@@ -166,7 +202,7 @@ proto.updateLayers = function(fullLayout, polarLayout) {
* + setScale setups ax._m,ax._b for given ax.range
*
* - this.angularAxis
- * extends polarLayout.angularaxis, adds mocked 'range' and 'domain' and
+ * extends getAngular(polarLayout), adds mocked 'range' and 'domain' and
* a few other keys in order to reuse the Axes drawing routines.
* used for calcdata -> geometric conversions (aka c2g) during the plot step
* + setGeometry setups ax.c2g given ax.rotation, ax.direction & ax._categories,
@@ -184,8 +220,8 @@ proto.updateLayout = function(fullLayout, polarLayout) {
var gs = fullLayout._size;
// axis attributes
- var radialLayout = polarLayout.radialaxis;
- var angularLayout = polarLayout.angularaxis;
+ var radialLayout = _this.getRadial(polarLayout);
+ var angularLayout = _this.getAngular(polarLayout);
// layout domains
var xDomain = polarLayout.domain.x;
var yDomain = polarLayout.domain.y;
@@ -196,7 +232,7 @@ proto.updateLayout = function(fullLayout, polarLayout) {
var xLength = _this.xLength = gs.w * (xDomain[1] - xDomain[0]);
var yLength = _this.yLength = gs.h * (yDomain[1] - yDomain[0]);
// sector to plot
- var sector = polarLayout.sector;
+ var sector = _this.getSector(polarLayout);
_this.sectorInRad = sector.map(deg2rad);
var sectorBBox = _this.sectorBBox = computeSectorBBox(sector);
var dxSectorBBox = sectorBBox[2] - sectorBBox[0];
@@ -231,7 +267,7 @@ proto.updateLayout = function(fullLayout, polarLayout) {
// circle radius in px
var radius = _this.radius = xLength2 / dxSectorBBox;
// 'inner' radius in px (when polar.hole is set)
- var innerRadius = _this.innerRadius = polarLayout.hole * radius;
+ var innerRadius = _this.innerRadius = _this.getHole(polarLayout) * radius;
// circle center position in px
var cx = _this.cx = xOffset2 - radius * sectorBBox[0];
var cy = _this.cy = yOffset2 + radius * sectorBBox[3];
@@ -239,16 +275,23 @@ proto.updateLayout = function(fullLayout, polarLayout) {
var cxx = _this.cxx = cx - xOffset2;
var cyy = _this.cyy = cy - yOffset2;
+ var side = radialLayout.side;
+ var trueSide;
+ if(side === 'counterclockwise') {
+ trueSide = side;
+ side = 'top';
+ } else if(side === 'clockwise') {
+ trueSide = side;
+ side = 'bottom';
+ }
+
_this.radialAxis = _this.mockAxis(fullLayout, polarLayout, radialLayout, {
// make this an 'x' axis to make positioning (especially rotation) easier
_id: 'x',
// convert to 'x' axis equivalent
- side: {
- counterclockwise: 'top',
- clockwise: 'bottom'
- }[radialLayout.side],
+ side: side,
// keep track of real side
- _realSide: radialLayout.side,
+ _trueSide: trueSide,
// spans length 1 radius
domain: [innerRadius / gs.w, radius / gs.w]
});
@@ -302,6 +345,7 @@ proto.mockAxis = function(fullLayout, polarLayout, axLayout, opts) {
proto.mockCartesianAxis = function(fullLayout, polarLayout, opts) {
var _this = this;
+ var isSmith = _this.isSmith;
var axId = opts._id;
var ax = Lib.extendFlat({type: 'linear'}, opts);
@@ -316,23 +360,25 @@ proto.mockCartesianAxis = function(fullLayout, polarLayout, opts) {
var sectorBBox = _this.sectorBBox;
var ind = bboxIndices[axId];
var rl = _this.radialAxis._rl;
- var drl = (rl[1] - rl[0]) / (1 - polarLayout.hole);
+ var drl = (rl[1] - rl[0]) / (1 - _this.getHole(polarLayout));
ax.range = [sectorBBox[ind[0]] * drl, sectorBBox[ind[1]] * drl];
};
- ax.isPtWithinRange = axId === 'x' ?
+ ax.isPtWithinRange = axId === 'x' && !isSmith ?
function(d) { return _this.isPtInside(d); } :
function() { return true; };
ax.setRange();
ax.setScale();
+
return ax;
};
proto.doAutoRange = function(fullLayout, polarLayout) {
- var gd = this.gd;
- var radialAxis = this.radialAxis;
- var radialLayout = polarLayout.radialaxis;
+ var _this = this;
+ var gd = _this.gd;
+ var radialAxis = _this.radialAxis;
+ var radialLayout = _this.getRadial(polarLayout);
doAutoRange(gd, radialAxis);
@@ -354,15 +400,18 @@ proto.updateRadialAxis = function(fullLayout, polarLayout) {
var innerRadius = _this.innerRadius;
var cx = _this.cx;
var cy = _this.cy;
- var radialLayout = polarLayout.radialaxis;
- var a0 = mod(polarLayout.sector[0], 360);
+ var radialLayout = _this.getRadial(polarLayout);
+ var a0 = mod(_this.getSector(polarLayout)[0], 360);
var ax = _this.radialAxis;
var hasRoomForIt = innerRadius < radius;
- _this.fillViewInitialKey('radialaxis.angle', radialLayout.angle);
- _this.fillViewInitialKey('radialaxis.range', ax.range.slice());
+ var isSmith = _this.isSmith;
+ if(!isSmith) {
+ _this.fillViewInitialKey('radialaxis.angle', radialLayout.angle);
+ _this.fillViewInitialKey('radialaxis.range', ax.range.slice());
- ax.setGeometry();
+ ax.setGeometry();
+ }
// rotate auto tick labels by 180 if in quadrant II and III to make them
// readable from left-to-right
@@ -373,14 +422,23 @@ proto.updateRadialAxis = function(fullLayout, polarLayout) {
}
// easier to set rotate angle with custom translate function
- var transFn = function(d) {
- return strTranslate(ax.l2p(d.x) + innerRadius, 0);
- };
+ var transFn = isSmith ?
+ function(d) {
+ var t = smithTransform(_this, smith([d.x, 0]));
+ return strTranslate(t[0] - cx, t[1] - cy);
+ } :
+ function(d) {
+ return strTranslate(ax.l2p(d.x) + innerRadius, 0);
+ };
// set special grid path function
- var gridPathFn = function(d) {
- return _this.pathArc(ax.r2p(d.x) + innerRadius);
- };
+ var gridPathFn = isSmith ?
+ function(d) {
+ return resistanceArc(_this, d.x, -Infinity, Infinity);
+ } :
+ function(d) {
+ return _this.pathArc(ax.r2p(d.x) + innerRadius);
+ };
var newTickLayout = strTickLayout(radialLayout);
if(_this.radialTickLayout !== newTickLayout) {
@@ -391,9 +449,30 @@ proto.updateRadialAxis = function(fullLayout, polarLayout) {
if(hasRoomForIt) {
ax.setScale();
- var vals = Axes.calcTicks(ax);
- var valsClipped = Axes.clipEnds(ax, vals);
+ var labelShift = 0;
+
+ var vals = isSmith ?
+ (ax.tickvals || []).filter(function(x) {
+ // filter negative
+ return x >= 0;
+ }).map(function(x) {
+ return Axes.tickText(ax, x, true, false);
+ }) : Axes.calcTicks(ax);
+
+ var valsClipped = isSmith ? vals : Axes.clipEnds(ax, vals);
var tickSign = Axes.getTickSigns(ax)[2];
+ if(isSmith) {
+ if(
+ (ax.ticks === 'top' && ax.side === 'bottom') ||
+ (ax.ticks === 'bottom' && ax.side === 'top')
+ ) {
+ // invert sign
+ tickSign = -tickSign;
+ }
+
+ if(ax.ticks === 'top' && ax.side === 'top') labelShift = -ax.ticklen;
+ if(ax.ticks === 'bottom' && ax.side === 'bottom') labelShift = ax.ticklen;
+ }
Axes.drawTicks(gd, ax, {
vals: vals,
@@ -415,7 +494,7 @@ proto.updateRadialAxis = function(fullLayout, polarLayout) {
vals: vals,
layer: layers['radial-axis'],
transFn: transFn,
- labelFns: Axes.makeLabelFns(ax, 0)
+ labelFns: Axes.makeLabelFns(ax, labelShift)
});
}
@@ -436,14 +515,14 @@ proto.updateRadialAxis = function(fullLayout, polarLayout) {
updateElement(
layers['radial-grid'],
hasRoomForIt && radialLayout.showgrid,
- {transform: tLayer}
+ {transform: isSmith ? '' : tLayer}
);
updateElement(
layers['radial-line'].select('line'),
hasRoomForIt && radialLayout.showline,
{
- x1: innerRadius,
+ x1: isSmith ? -radius : innerRadius,
y1: 0,
x2: radius,
y2: 0,
@@ -455,19 +534,16 @@ proto.updateRadialAxis = function(fullLayout, polarLayout) {
};
proto.updateRadialAxisTitle = function(fullLayout, polarLayout, _angle) {
+ if(this.isSmith) return;
+
var _this = this;
var gd = _this.gd;
var radius = _this.radius;
var cx = _this.cx;
var cy = _this.cy;
- var radialLayout = polarLayout.radialaxis;
+ var radialLayout = _this.getRadial(polarLayout);
var titleClass = _this.id + 'title';
- var angle = _angle !== undefined ? _angle : _this.radialAxisAngle;
- var angleRad = deg2rad(angle);
- var cosa = Math.cos(angleRad);
- var sina = Math.sin(angleRad);
-
var pad = 0;
// Hint: no need to check if there is in fact a title.text set
@@ -476,18 +552,30 @@ proto.updateRadialAxisTitle = function(fullLayout, polarLayout, _angle) {
if(radialLayout.title) {
var h = Drawing.bBox(_this.layers['radial-axis'].node()).height;
var ts = radialLayout.title.font.size;
- pad = radialLayout.side === 'counterclockwise' ?
- -h - ts * 0.4 :
- h + ts * 0.8;
+ var side = radialLayout.side;
+ pad =
+ side === 'top' ? ts :
+ side === 'counterclockwise' ?
+ -(h + ts * 0.4) :
+ h + ts * 0.8;
}
+ var angle = _angle !== undefined ? _angle : _this.radialAxisAngle;
+
+ var angleRad = deg2rad(angle);
+ var cosa = Math.cos(angleRad);
+ var sina = Math.sin(angleRad);
+
+ var x = cx + (radius / 2) * cosa + pad * sina;
+ var y = cy - (radius / 2) * sina + pad * cosa;
+
_this.layers['radial-axis-title'] = Titles.draw(gd, titleClass, {
propContainer: radialLayout,
propName: _this.id + '.radialaxis.title',
placeholder: _(gd, 'Click to enter radial axis title'),
attributes: {
- x: cx + (radius / 2) * cosa + pad * sina,
- y: cy - (radius / 2) * sina + pad * cosa,
+ x: x,
+ y: y,
'text-anchor': 'middle'
},
transform: {rotate: -angle}
@@ -502,16 +590,24 @@ proto.updateAngularAxis = function(fullLayout, polarLayout) {
var innerRadius = _this.innerRadius;
var cx = _this.cx;
var cy = _this.cy;
- var angularLayout = polarLayout.angularaxis;
+ var angularLayout = _this.getAngular(polarLayout);
var ax = _this.angularAxis;
- _this.fillViewInitialKey('angularaxis.rotation', angularLayout.rotation);
+ var isSmith = _this.isSmith;
+ if(!isSmith) {
+ _this.fillViewInitialKey('angularaxis.rotation', angularLayout.rotation);
- ax.setGeometry();
- ax.setScale();
+ ax.setGeometry();
+ ax.setScale();
+ }
// 't'ick to 'g'eometric radians is used all over the place here
- var t2g = function(d) { return ax.t2g(d.x); };
+ var t2g = isSmith ?
+ function(d) {
+ var t = smithTransform(_this, smith([0, d.x]));
+ return Math.atan2(t[0] - cx, t[1] - cy) - Math.PI / 2;
+ } :
+ function(d) { return ax.t2g(d.x); };
// run rad2deg on tick0 and ditck for thetaunit: 'radians' axes
if(ax.type === 'linear' && ax.thetaunit === 'radians') {
@@ -523,22 +619,37 @@ proto.updateAngularAxis = function(fullLayout, polarLayout) {
return strTranslate(cx + radius * Math.cos(rad), cy - radius * Math.sin(rad));
};
- var transFn = function(d) {
- return _transFn(t2g(d));
- };
-
- var transFn2 = function(d) {
- var rad = t2g(d);
- return _transFn(rad) + strRotate(-rad2deg(rad));
- };
-
- var gridPathFn = function(d) {
- var rad = t2g(d);
- var cosRad = Math.cos(rad);
- var sinRad = Math.sin(rad);
- return 'M' + [cx + innerRadius * cosRad, cy - innerRadius * sinRad] +
- 'L' + [cx + radius * cosRad, cy - radius * sinRad];
- };
+ var transFn = isSmith ?
+ function(d) {
+ var t = smithTransform(_this, smith([0, d.x]));
+ return strTranslate(t[0], t[1]);
+ } :
+ function(d) {
+ return _transFn(t2g(d));
+ };
+
+ var transFn2 = isSmith ?
+ function(d) {
+ var t = smithTransform(_this, smith([0, d.x]));
+ var rad = Math.atan2(t[0] - cx, t[1] - cy) - Math.PI / 2;
+ return strTranslate(t[0], t[1]) + strRotate(-rad2deg(rad));
+ } :
+ function(d) {
+ var rad = t2g(d);
+ return _transFn(rad) + strRotate(-rad2deg(rad));
+ };
+
+ var gridPathFn = isSmith ?
+ function(d) {
+ return reactanceArc(_this, d.x, 0, Infinity);
+ } :
+ function(d) {
+ var rad = t2g(d);
+ var cosRad = Math.cos(rad);
+ var sinRad = Math.sin(rad);
+ return 'M' + [cx + innerRadius * cosRad, cy - innerRadius * sinRad] +
+ 'L' + [cx + radius * cosRad, cy - radius * sinRad];
+ };
var out = Axes.makeLabelFns(ax, 0);
var labelStandoff = out.labelStandoff;
@@ -575,7 +686,15 @@ proto.updateAngularAxis = function(fullLayout, polarLayout) {
_this.angularTickLayout = newTickLayout;
}
- var vals = Axes.calcTicks(ax);
+ var vals = isSmith ?
+ [Infinity].concat(ax.tickvals || []).map(function(x) {
+ return Axes.tickText(ax, x, true, false);
+ }) : Axes.calcTicks(ax);
+
+ if(isSmith) {
+ vals[0].text = '∞';
+ vals[0].fontSize *= 1.75;
+ }
// angle of polygon vertices in geometric radians (null means circles)
// TODO what to do when ax.period > ax._categories ??
@@ -604,6 +723,7 @@ proto.updateAngularAxis = function(fullLayout, polarLayout) {
if(ax.visible) {
var tickSign = ax.ticks === 'inside' ? -1 : 1;
+
var pad = (ax.linewidth || 1) / 2;
Axes.drawTicks(gd, ax, {
@@ -644,15 +764,19 @@ proto.updateAngularAxis = function(fullLayout, polarLayout) {
proto.updateFx = function(fullLayout, polarLayout) {
if(!this.gd._context.staticPlot) {
- this.updateAngularDrag(fullLayout);
- this.updateRadialDrag(fullLayout, polarLayout, 0);
- this.updateRadialDrag(fullLayout, polarLayout, 1);
- this.updateMainDrag(fullLayout);
+ var hasDrag = !this.isSmith;
+ if(hasDrag) {
+ this.updateAngularDrag(fullLayout);
+ this.updateRadialDrag(fullLayout, polarLayout, 0);
+ this.updateRadialDrag(fullLayout, polarLayout, 1);
+ }
+ this.updateHoverAndMainDrag(fullLayout);
}
};
-proto.updateMainDrag = function(fullLayout) {
+proto.updateHoverAndMainDrag = function(fullLayout) {
var _this = this;
+ var isSmith = _this.isSmith;
var gd = _this.gd;
var layers = _this.layers;
var zoomlayer = fullLayout._zoomlayer;
@@ -682,6 +806,17 @@ proto.updateMainDrag = function(fullLayout) {
.attr('d', _this.pathSubplot())
.attr('transform', strTranslate(cx, cy));
+ mainDrag.onmousemove = function(evt) {
+ Fx.hover(gd, evt, _this.id);
+ gd._fullLayout._lasthover = mainDrag;
+ gd._fullLayout._hoversubplot = _this.id;
+ };
+
+ mainDrag.onmouseout = function(evt) {
+ if(gd._dragging) return;
+ dragElement.unhover(gd, evt);
+ };
+
var dragOpts = {
element: mainDrag,
gd: gd,
@@ -954,14 +1089,18 @@ proto.updateMainDrag = function(fullLayout) {
switch(dragModeNow) {
case 'zoom':
- if(vangles) {
- dragOpts.moveFn = zoomMoveForPolygons;
- } else {
- dragOpts.moveFn = zoomMove;
- }
dragOpts.clickFn = zoomClick;
- dragOpts.doneFn = zoomDone;
- zoomPrep(evt, startX, startY);
+
+ if(!isSmith) {
+ if(vangles) {
+ dragOpts.moveFn = zoomMoveForPolygons;
+ } else {
+ dragOpts.moveFn = zoomMove;
+ }
+
+ dragOpts.doneFn = zoomDone;
+ zoomPrep(evt, startX, startY);
+ }
break;
case 'select':
case 'lasso':
@@ -970,17 +1109,6 @@ proto.updateMainDrag = function(fullLayout) {
}
};
- mainDrag.onmousemove = function(evt) {
- Fx.hover(gd, evt, _this.id);
- gd._fullLayout._lasthover = mainDrag;
- gd._fullLayout._hoversubplot = _this.id;
- };
-
- mainDrag.onmouseout = function(evt) {
- if(gd._dragging) return;
- dragElement.unhover(gd, evt);
- };
-
dragElement.init(dragOpts);
};
@@ -1003,7 +1131,7 @@ proto.updateRadialDrag = function(fullLayout, polarLayout, rngIndex) {
var rl0 = rl[0];
var rl1 = rl[1];
var rbase = rl[rngIndex];
- var m = 0.75 * (rl[1] - rl[0]) / (1 - polarLayout.hole) / radius;
+ var m = 0.75 * (rl[1] - rl[0]) / (1 - _this.getHole(polarLayout)) / radius;
var tx, ty, className;
if(rngIndex) {
@@ -1312,6 +1440,8 @@ proto.updateAngularDrag = function(fullLayout) {
};
proto.isPtInside = function(d) {
+ if(this.isSmith) return true;
+
var sectorInRad = this.sectorInRad;
var vangles = this.vangles;
var thetag = this.angularAxis.c2g(d.theta);
diff --git a/src/plots/smith/constants.js b/src/plots/smith/constants.js
new file mode 100644
index 00000000000..24357fc29a5
--- /dev/null
+++ b/src/plots/smith/constants.js
@@ -0,0 +1,12 @@
+'use strict';
+
+module.exports = {
+ attr: 'subplot',
+ name: 'smith',
+
+ axisNames: [
+ 'realaxis',
+ 'imaginaryaxis' // imaginary axis should be second here so that the `tickvals` defaults could be inherited from realaxis
+ ],
+ axisName2dataArray: {imaginaryaxis: 'imag', realaxis: 'real'},
+};
diff --git a/src/plots/smith/helpers.js b/src/plots/smith/helpers.js
new file mode 100644
index 00000000000..d6db7b4e7dd
--- /dev/null
+++ b/src/plots/smith/helpers.js
@@ -0,0 +1,93 @@
+'use strict';
+
+function sign(x) {
+ return (
+ x < 0 ? -1 :
+ x > 0 ? 1 : 0
+ );
+}
+
+// adapted from Mike Bostock's https://observablehq.com/@mbostock/smith-chart
+function smith(a) {
+ var R = a[0];
+ var X = a[1];
+
+ if(!isFinite(R) || !isFinite(X)) return [1, 0];
+
+ var D = (R + 1) * (R + 1) + X * X;
+ return [(R * R + X * X - 1) / D, 2 * X / D];
+}
+
+function transform(subplot, a) {
+ var x = a[0];
+ var y = a[1];
+
+ return [
+ x * subplot.radius + subplot.cx,
+ -y * subplot.radius + subplot.cy
+ ];
+}
+
+function scale(subplot, r) {
+ return r * subplot.radius;
+}
+
+function reactanceArc(subplot, X, R1, R2) {
+ var t1 = transform(subplot, smith([R1, X]));
+ var x1 = t1[0];
+ var y1 = t1[1];
+
+ var t2 = transform(subplot, smith([R2, X]));
+ var x2 = t2[0];
+ var y2 = t2[1];
+
+ if(X === 0) {
+ return [
+ 'M' + x1 + ',' + y1,
+ 'L' + x2 + ',' + y2
+ ].join(' ');
+ }
+
+ var r = scale(subplot, 1 / Math.abs(X));
+
+ return [
+ 'M' + x1 + ',' + y1,
+ 'A' + r + ',' + r + ' 0 0,' + (X < 0 ? 1 : 0) + ' ' + x2 + ',' + y2
+ ].join(' ');
+}
+
+function resistanceArc(subplot, R, X1, X2) {
+ var r = scale(subplot, 1 / (R + 1));
+
+ var t1 = transform(subplot, smith([R, X1]));
+ var x1 = t1[0];
+ var y1 = t1[1];
+
+ var t2 = transform(subplot, smith([R, X2]));
+ var x2 = t2[0];
+ var y2 = t2[1];
+
+ if(sign(X1) !== sign(X2)) {
+ var t0 = transform(subplot, smith([R, 0]));
+ var x0 = t0[0];
+ var y0 = t0[1];
+
+ return [
+ 'M' + x1 + ',' + y1,
+ 'A' + r + ',' + r + ' 0 0,' + (0 < X1 ? 0 : 1) + ' ' + x0 + ',' + y0,
+ 'A' + r + ',' + r + ' 0 0,' + (X2 < 0 ? 0 : 1) + x2 + ',' + y2,
+ ].join(' ');
+ }
+
+ return [
+ 'M' + x1 + ',' + y1,
+ 'A' + r + ',' + r + ' 0 0,' + (X2 < X1 ? 0 : 1) + ' ' + x2 + ',' + y2
+ ].join(' ');
+}
+
+module.exports = {
+ smith: smith,
+ reactanceArc: reactanceArc,
+ resistanceArc: resistanceArc,
+ smithTransform: transform
+};
diff --git a/src/plots/smith/index.js b/src/plots/smith/index.js
new file mode 100644
index 00000000000..fdad79f653f
--- /dev/null
+++ b/src/plots/smith/index.js
@@ -0,0 +1,73 @@
+'use strict';
+
+var getSubplotCalcData = require('../get_data').getSubplotCalcData;
+var counterRegex = require('../../lib').counterRegex;
+
+var createPolar = require('../polar/polar');
+var constants = require('./constants');
+
+var attr = constants.attr;
+var name = constants.name;
+var counter = counterRegex(name);
+
+var attributes = {};
+attributes[attr] = {
+ valType: 'subplotid',
+ dflt: name,
+ editType: 'calc',
+ description: [
+ 'Sets a reference between this trace\'s data coordinates and',
+ 'a smith subplot.',
+ 'If *smith* (the default value), the data refer to `layout.smith`.',
+ 'If *smith2*, the data refer to `layout.smith2`, and so on.'
+ ].join(' ')
+};
+
+function plot(gd) {
+ var fullLayout = gd._fullLayout;
+ var calcData = gd.calcdata;
+ var subplotIds = fullLayout._subplots[name];
+
+ for(var i = 0; i < subplotIds.length; i++) {
+ var id = subplotIds[i];
+ var subplotCalcData = getSubplotCalcData(calcData, name, id);
+ var subplot = fullLayout[id]._subplot;
+
+ if(!subplot) {
+ subplot = createPolar(gd, id, true);
+ fullLayout[id]._subplot = subplot;
+ }
+
+ subplot.plot(subplotCalcData, fullLayout, gd._promises);
+ }
+}
+
+function clean(newFullData, newFullLayout, oldFullData, oldFullLayout) {
+ var oldIds = oldFullLayout._subplots[name] || [];
+ for(var i = 0; i < oldIds.length; i++) {
+ var id = oldIds[i];
+ var oldSubplot = oldFullLayout[id]._subplot;
+
+ if(!newFullLayout[id] && !!oldSubplot) {
+ oldSubplot.framework.remove();
+
+ for(var k in oldSubplot.clipPaths) {
+ oldSubplot.clipPaths[k].remove();
+ }
+ }
+ }
+}
+
+module.exports = {
+ attr: attr,
+ name: name,
+ idRoot: name,
+ idRegex: counter,
+ attrRegex: counter,
+ attributes: attributes,
+ layoutAttributes: require('./layout_attributes'),
+ supplyLayoutDefaults: require('./layout_defaults'),
+ plot: plot,
+ clean: clean,
+ toSVG: require('../cartesian').toSVG
+};
diff --git a/src/plots/smith/layout_attributes.js b/src/plots/smith/layout_attributes.js
new file mode 100644
index 00000000000..b6ac6c25c3f
--- /dev/null
+++ b/src/plots/smith/layout_attributes.js
@@ -0,0 +1,103 @@
+'use strict';
+
+var colorAttrs = require('../../components/color/attributes');
+var axesAttrs = require('../cartesian/layout_attributes');
+var domainAttrs = require('../domain').attributes;
+var extendFlat = require('../../lib').extendFlat;
+var overrideAll = require('../../plot_api/edit_types').overrideAll;
+
+var axisLineGridAttr = overrideAll({
+ color: axesAttrs.color,
+ showline: extendFlat({}, axesAttrs.showline, {dflt: true}),
+ linecolor: axesAttrs.linecolor,
+ linewidth: axesAttrs.linewidth,
+ showgrid: extendFlat({}, axesAttrs.showgrid, {dflt: true}),
+ gridcolor: axesAttrs.gridcolor,
+ gridwidth: axesAttrs.gridwidth
+}, 'plot', 'from-root');
+
+var axisTickAttrs = overrideAll({
+ ticklen: axesAttrs.ticklen,
+ tickwidth: extendFlat({}, axesAttrs.tickwidth, {dflt: 2}),
+ tickcolor: axesAttrs.tickcolor,
+ showticklabels: axesAttrs.showticklabels,
+ showtickprefix: axesAttrs.showtickprefix,
+ tickprefix: axesAttrs.tickprefix,
+ showticksuffix: axesAttrs.showticksuffix,
+ ticksuffix: axesAttrs.ticksuffix,
+ tickfont: axesAttrs.tickfont,
+ tickformat: axesAttrs.tickformat,
+ hoverformat: axesAttrs.hoverformat,
+ layer: axesAttrs.layer
+}, 'plot', 'from-root');
+
+var realAxisAttrs = extendFlat({
+ visible: extendFlat({}, axesAttrs.visible, {dflt: true}),
+
+ tickvals: {
+ dflt: [0.2, 0.5, 1, 2, 5],
+ valType: 'data_array',
+ editType: 'plot',
+ description: 'Sets the values at which ticks on this axis appear.'
+ },
+
+ tickangle: extendFlat({}, axesAttrs.tickangle, {dflt: 90}),
+
+ ticks: {
+ valType: 'enumerated',
+ values: ['top', 'bottom', ''],
+ editType: 'ticks',
+ description: [
+ 'Determines whether ticks are drawn or not.',
+ 'If **, this axis\' ticks are not drawn.',
+ 'If *top* (*bottom*), this axis\' are drawn above (below)',
+ 'the axis line.'
+ ].join(' ')
+ },
+
+ side: {
+ valType: 'enumerated',
+ values: ['top', 'bottom'],
+ dflt: 'top',
+ editType: 'plot',
+ description: [
+ 'Determines on which side of real axis line',
+ 'the tick and tick labels appear.'
+ ].join(' ')
+ },
+
+ editType: 'calc',
+}, axisLineGridAttr, axisTickAttrs);
+
+var imaginaryAxisAttrs = extendFlat({
+ visible: extendFlat({}, axesAttrs.visible, {dflt: true}),
+
+ tickvals: {
+ valType: 'data_array',
+ editType: 'plot',
+ description: [
+ 'Sets the values at which ticks on this axis appear.',
+ 'Defaults to `realaxis.tickvals` plus the same as negatives and zero.'
+ ].join(' ')
+ },
+
+ ticks: axesAttrs.ticks,
+
+ editType: 'calc'
+}, axisLineGridAttr, axisTickAttrs);
+
+module.exports = {
+ domain: domainAttrs({name: 'smith', editType: 'plot'}),
+
+ bgcolor: {
+ valType: 'color',
+ editType: 'plot',
+ dflt: colorAttrs.background,
+ description: 'Set the background color of the subplot'
+ },
+
+ realaxis: realAxisAttrs,
+ imaginaryaxis: imaginaryAxisAttrs,
+
+ editType: 'calc'
+};
diff --git a/src/plots/smith/layout_defaults.js b/src/plots/smith/layout_defaults.js
new file mode 100644
index 00000000000..fc332959a41
--- /dev/null
+++ b/src/plots/smith/layout_defaults.js
@@ -0,0 +1,134 @@
+'use strict';
+
+var Lib = require('../../lib');
+var Color = require('../../components/color');
+var Template = require('../../plot_api/plot_template');
+
+var handleSubplotDefaults = require('../subplot_defaults');
+var getSubplotData = require('../get_data').getSubplotData;
+
+var handlePrefixSuffixDefaults = require('../cartesian/prefix_suffix_defaults');
+var handleTickLabelDefaults = require('../cartesian/tick_label_defaults');
+var handleLineGridDefaults = require('../cartesian/line_grid_defaults');
+var setConvertCartesian = require('../cartesian/set_convert');
+
+var layoutAttributes = require('./layout_attributes');
+var constants = require('./constants');
+var axisNames = constants.axisNames;
+
+function handleDefaults(contIn, contOut, coerce, opts) {
+ var bgColor = coerce('bgcolor');
+ opts.bgColor = Color.combine(bgColor, opts.paper_bgcolor);
+
+ var subplotData = getSubplotData(opts.fullData, constants.name, opts.id);
+ var layoutOut = opts.layoutOut;
+ var axName;
+
+ function coerceAxis(attr, dflt) {
+ return coerce(axName + '.' + attr, dflt);
+ }
+
+ for(var i = 0; i < axisNames.length; i++) {
+ axName = axisNames[i];
+
+ if(!Lib.isPlainObject(contIn[axName])) {
+ contIn[axName] = {};
+ }
+
+ var axIn = contIn[axName];
+ var axOut = Template.newContainer(contOut, axName);
+ axOut._id = axOut._name = axName;
+ axOut._attr = opts.id + '.' + axName;
+ axOut._traceIndices = subplotData.map(function(t) { return t._expandedIndex; });
+
+ var visible = coerceAxis('visible');
+
+ axOut.type = 'linear';
+ setConvertCartesian(axOut, layoutOut);
+
+ handlePrefixSuffixDefaults(axIn, axOut, coerceAxis, axOut.type);
+
+ if(visible) {
+ var isRealAxis = axName === 'realaxis';
+ if(isRealAxis) coerceAxis('side');
+
+ if(isRealAxis) {
+ coerceAxis('tickvals');
+ } else {
+ var realTickvals = contOut.realaxis.tickvals || layoutAttributes.realaxis.tickvals.dflt;
+ var imagTickvalsDflt =
+ realTickvals.slice().reverse().map(function(x) { return -x; })
+ .concat([0])
+ .concat(realTickvals);
+
+ coerceAxis('tickvals', imagTickvalsDflt);
+ }
+
+ var dfltColor;
+ var dfltFontColor;
+ var dfltFontSize;
+ var dfltFontFamily;
+ var font = opts.font || {};
+
+ if(visible) {
+ dfltColor = coerceAxis('color');
+ dfltFontColor = (dfltColor === axIn.color) ? dfltColor : font.color;
+ dfltFontSize = font.size;
+ dfltFontFamily = font.family;
+ }
+
+ handleTickLabelDefaults(axIn, axOut, coerceAxis, axOut.type, {
+ noAng: !isRealAxis,
+ noExp: true,
+ font: {
+ color: dfltFontColor,
+ size: dfltFontSize,
+ family: dfltFontFamily
+ }
+ });
+
+ Lib.coerce2(contIn, contOut, layoutAttributes, axName + '.ticklen');
+ Lib.coerce2(contIn, contOut, layoutAttributes, axName + '.tickwidth');
+ Lib.coerce2(contIn, contOut, layoutAttributes, axName + '.tickcolor', contOut.color);
+ var showTicks = coerceAxis('ticks');
+ if(!showTicks) {
+ delete contOut[axName].ticklen;
+ delete contOut[axName].tickwidth;
+ delete contOut[axName].tickcolor;
+ }
+
+ handleLineGridDefaults(axIn, axOut, coerceAxis, {
+ dfltColor: dfltColor,
+ bgColor: opts.bgColor,
+ // default grid color is darker here (60%, vs cartesian default ~91%)
+ // because the grid is not square so the eye needs heavier cues to follow
+ blend: 60,
+ showLine: true,
+ showGrid: true,
+ noZeroLine: true,
+ attributes: layoutAttributes[axName]
+ });
+
+ coerceAxis('layer');
+ }
+
+ coerceAxis('hoverformat');
+
+ delete axOut.type;
+
+ axOut._input = axIn;
+ }
+}
+
+module.exports = function supplyLayoutDefaults(layoutIn, layoutOut, fullData) {
+ handleSubplotDefaults(layoutIn, layoutOut, fullData, {
+ noUirevision: true,
+ type: constants.name,
+ attributes: layoutAttributes,
+ handleDefaults: handleDefaults,
+ font: layoutOut.font,
+ paper_bgcolor: layoutOut.paper_bgcolor,
+ fullData: fullData,
+ layoutOut: layoutOut
+ });
+};
diff --git a/src/plots/subplot_defaults.js b/src/plots/subplot_defaults.js
index 9c665278444..46651b1e848 100644
--- a/src/plots/subplot_defaults.js
+++ b/src/plots/subplot_defaults.js
@@ -58,11 +58,7 @@ module.exports = function handleSubplotDefaults(layoutIn, layoutOut, fullData, o
subplotLayoutOut = Template.newContainer(layoutOut, id, baseId);
- // All subplot containers get a `uirevision` inheriting from the base.
- // Currently all subplots containers have some user interaction
- // attributes, but if we ever add one that doesn't, we would need an
- // option to skip this step.
- coerce('uirevision', layoutOut.uirevision);
+ if(!opts.noUirevision) coerce('uirevision', layoutOut.uirevision);
var dfltDomains = {};
dfltDomains[partition] = [i / idsLength, (i + 1) / idsLength];
diff --git a/src/traces/scattersmith/attributes.js b/src/traces/scattersmith/attributes.js
new file mode 100644
index 00000000000..90311398341
--- /dev/null
+++ b/src/traces/scattersmith/attributes.js
@@ -0,0 +1,80 @@
+'use strict';
+
+var hovertemplateAttrs = require('../../plots/template_attributes').hovertemplateAttrs;
+var texttemplateAttrs = require('../../plots/template_attributes').texttemplateAttrs;
+var extendFlat = require('../../lib/extend').extendFlat;
+var scatterAttrs = require('../scatter/attributes');
+var baseAttrs = require('../../plots/attributes');
+var lineAttrs = scatterAttrs.line;
+
+module.exports = {
+ mode: scatterAttrs.mode,
+
+ real: {
+ valType: 'data_array',
+ editType: 'calc+clearAxisTypes',
+ description: [
+ 'Sets the real component of the data, in units of normalized impedance',
+ 'such that real=1, imag=0 is the center of the chart.'
+ ].join(' ')
+ },
+
+ imag: {
+ valType: 'data_array',
+ editType: 'calc+clearAxisTypes',
+ description: [
+ 'Sets the imaginary component of the data, in units of normalized impedance',
+ 'such that real=1, imag=0 is the center of the chart.'
+ ].join(' ')
+ },
+
+ text: scatterAttrs.text,
+ texttemplate: texttemplateAttrs({editType: 'plot'}, {
+ keys: ['real', 'imag', 'text']
+ }),
+ hovertext: scatterAttrs.hovertext,
+
+ line: {
+ color: lineAttrs.color,
+ width: lineAttrs.width,
+ dash: lineAttrs.dash,
+ shape: extendFlat({}, lineAttrs.shape, {
+ values: ['linear', 'spline']
+ }),
+ smoothing: lineAttrs.smoothing,
+ editType: 'calc'
+ },
+ connectgaps: scatterAttrs.connectgaps,
+
+ marker: scatterAttrs.marker,
+ cliponaxis: extendFlat({}, scatterAttrs.cliponaxis, {dflt: false}),
+
+ textposition: scatterAttrs.textposition,
+ textfont: scatterAttrs.textfont,
+
+ fill: extendFlat({}, scatterAttrs.fill, {
+ values: ['none', 'toself', 'tonext'],
+ dflt: 'none',
+ description: [
+ 'Sets the area to fill with a solid color.',
+ 'Use with `fillcolor` if not *none*.',
+ 'scattersmith has a subset of the options available to scatter.',
+ '*toself* connects the endpoints of the trace (or each segment',
+ 'of the trace if it has gaps) into a closed shape.',
+ '*tonext* fills the space between two traces if one completely',
+ 'encloses the other (eg consecutive contour lines), and behaves like',
+ '*toself* if there is no trace before it. *tonext* should not be',
+ 'used if one trace does not enclose the other.'
+ ].join(' ')
+ }),
+ fillcolor: scatterAttrs.fillcolor,
+
+ hoverinfo: extendFlat({}, baseAttrs.hoverinfo, {
+ flags: ['real', 'imag', 'text', 'name']
+ }),
+ hoveron: scatterAttrs.hoveron,
+ hovertemplate: hovertemplateAttrs(),
+
+ selected: scatterAttrs.selected,
+ unselected: scatterAttrs.unselected
+};
diff --git a/src/traces/scattersmith/calc.js b/src/traces/scattersmith/calc.js
new file mode 100644
index 00000000000..cfd22f61c9c
--- /dev/null
+++ b/src/traces/scattersmith/calc.js
@@ -0,0 +1,40 @@
+'use strict';
+
+var isNumeric = require('fast-isnumeric');
+var BADNUM = require('../../constants/numerical').BADNUM;
+
+var calcColorscale = require('../scatter/colorscale_calc');
+var arraysToCalcdata = require('../scatter/arrays_to_calcdata');
+var calcSelection = require('../scatter/calc_selection');
+var calcMarkerSize = require('../scatter/calc').calcMarkerSize;
+
+module.exports = function calc(gd, trace) {
+ var fullLayout = gd._fullLayout;
+ var subplotId = trace.subplot;
+ var realAxis = fullLayout[subplotId].realaxis;
+ var imaginaryAxis = fullLayout[subplotId].imaginaryaxis;
+ var realArray = realAxis.makeCalcdata(trace, 'real');
+ var imagArray = imaginaryAxis.makeCalcdata(trace, 'imag');
+ var len = trace._length;
+ var cd = new Array(len);
+
+ for(var i = 0; i < len; i++) {
+ var real = realArray[i];
+ var imag = imagArray[i];
+ var cdi = cd[i] = {};
+
+ if(isNumeric(real) && isNumeric(imag)) {
+ cdi.real = real;
+ cdi.imag = imag;
+ } else {
+ cdi.real = BADNUM;
+ }
+ }
+
+ calcMarkerSize(trace, len);
+ calcColorscale(gd, trace);
+ arraysToCalcdata(cd, trace);
+ calcSelection(cd, trace);
+
+ return cd;
+};
diff --git a/src/traces/scattersmith/defaults.js b/src/traces/scattersmith/defaults.js
new file mode 100644
index 00000000000..ad00da49fd4
--- /dev/null
+++ b/src/traces/scattersmith/defaults.js
@@ -0,0 +1,80 @@
+'use strict';
+
+var Lib = require('../../lib');
+
+var subTypes = require('../scatter/subtypes');
+var handleMarkerDefaults = require('../scatter/marker_defaults');
+var handleLineDefaults = require('../scatter/line_defaults');
+var handleLineShapeDefaults = require('../scatter/line_shape_defaults');
+var handleTextDefaults = require('../scatter/text_defaults');
+var handleFillColorDefaults = require('../scatter/fillcolor_defaults');
+var PTS_LINESONLY = require('../scatter/constants').PTS_LINESONLY;
+
+var attributes = require('./attributes');
+
+module.exports = function supplyDefaults(traceIn, traceOut, defaultColor, layout) {
+ function coerce(attr, dflt) {
+ return Lib.coerce(traceIn, traceOut, attributes, attr, dflt);
+ }
+
+ var len = handleRealImagDefaults(traceIn, traceOut, layout, coerce);
+ if(!len) {
+ traceOut.visible = false;
+ return;
+ }
+
+ coerce('mode', len < PTS_LINESONLY ? 'lines+markers' : 'lines');
+ coerce('text');
+ coerce('hovertext');
+ if(traceOut.hoveron !== 'fills') coerce('hovertemplate');
+
+ if(subTypes.hasLines(traceOut)) {
+ handleLineDefaults(traceIn, traceOut, defaultColor, layout, coerce);
+ handleLineShapeDefaults(traceIn, traceOut, coerce);
+ coerce('connectgaps');
+ }
+
+ if(subTypes.hasMarkers(traceOut)) {
+ handleMarkerDefaults(traceIn, traceOut, defaultColor, layout, coerce, {gradient: true});
+ }
+
+ if(subTypes.hasText(traceOut)) {
+ coerce('texttemplate');
+ handleTextDefaults(traceIn, traceOut, layout, coerce);
+ }
+
+ var dfltHoverOn = [];
+
+ if(subTypes.hasMarkers(traceOut) || subTypes.hasText(traceOut)) {
+ coerce('cliponaxis');
+ coerce('marker.maxdisplayed');
+ dfltHoverOn.push('points');
+ }
+
+ coerce('fill');
+
+ if(traceOut.fill !== 'none') {
+ handleFillColorDefaults(traceIn, traceOut, defaultColor, coerce);
+ if(!subTypes.hasLines(traceOut)) handleLineShapeDefaults(traceIn, traceOut, coerce);
+ }
+
+ if(traceOut.fill === 'tonext' || traceOut.fill === 'toself') {
+ dfltHoverOn.push('fills');
+ }
+ coerce('hoveron', dfltHoverOn.join('+') || 'points');
+
+ Lib.coerceSelectionMarkerOpacity(traceOut, coerce);
+};
+
+function handleRealImagDefaults(traceIn, traceOut, layout, coerce) {
+ var real = coerce('real');
+ var imag = coerce('imag');
+ var len;
+
+ if(real && imag) {
+ len = Math.min(real.length, imag.length);
+ }
+
+ traceOut._length = len;
+ return len;
+}
diff --git a/src/traces/scattersmith/format_labels.js b/src/traces/scattersmith/format_labels.js
new file mode 100644
index 00000000000..019e3ab26b8
--- /dev/null
+++ b/src/traces/scattersmith/format_labels.js
@@ -0,0 +1,14 @@
+'use strict';
+
+var Axes = require('../../plots/cartesian/axes');
+
+module.exports = function formatLabels(cdi, trace, fullLayout) {
+ var labels = {};
+
+ var subplot = fullLayout[trace.subplot]._subplot;
+
+ labels.realLabel = Axes.tickText(subplot.radialAxis, cdi.real, true).text;
+ labels.imagLabel = Axes.tickText(subplot.angularAxis, cdi.imag, true).text;
+
+ return labels;
+};
diff --git a/src/traces/scattersmith/hover.js b/src/traces/scattersmith/hover.js
new file mode 100644
index 00000000000..350f4dc6d2d
--- /dev/null
+++ b/src/traces/scattersmith/hover.js
@@ -0,0 +1,66 @@
+'use strict';
+
+var scatterHover = require('../scatter/hover');
+
+function hoverPoints(pointData, xval, yval, hovermode) {
+ var scatterPointData = scatterHover(pointData, xval, yval, hovermode);
+ if(!scatterPointData || scatterPointData[0].index === false) return;
+
+ var newPointData = scatterPointData[0];
+
+ // hovering on fill case
+ if(newPointData.index === undefined) {
+ return scatterPointData;
+ }
+
+ var subplot = pointData.subplot;
+ var cdi = newPointData.cd[newPointData.index];
+ var trace = newPointData.trace;
+
+ if(!subplot.isPtInside(cdi)) return;
+
+ newPointData.xLabelVal = undefined;
+ newPointData.yLabelVal = undefined;
+ makeHoverPointText(cdi, trace, subplot, newPointData);
+ newPointData.hovertemplate = trace.hovertemplate;
+ return scatterPointData;
+}
+
+function makeHoverPointText(cdi, trace, subplot, pointData) {
+ var realAxis = subplot.radialAxis;
+ var imaginaryAxis = subplot.angularAxis;
+ realAxis._hovertitle = 'real';
+ imaginaryAxis._hovertitle = 'imag';
+
+ var fullLayout = {};
+ fullLayout[trace.subplot] = {_subplot: subplot};
+ var labels = trace._module.formatLabels(cdi, trace, fullLayout);
+ pointData.realLabel = labels.realLabel;
+ pointData.imagLabel = labels.imagLabel;
+
+ var hoverinfo = cdi.hi || trace.hoverinfo;
+ var text = [];
+ function textPart(ax, val) {
+ text.push(ax._hovertitle + ': ' + val);
+ }
+
+ if(!trace.hovertemplate) {
+ var parts = hoverinfo.split('+');
+
+ if(parts.indexOf('all') !== -1) parts = ['real', 'imag', 'text'];
+ if(parts.indexOf('real') !== -1) textPart(realAxis, pointData.realLabel);
+ if(parts.indexOf('imag') !== -1) textPart(imaginaryAxis, pointData.imagLabel);
+
+ if(parts.indexOf('text') !== -1 && pointData.text) {
+ text.push(pointData.text);
+ delete pointData.text;
+ }
+
+ pointData.extraText = text.join('
');
+ }
+}
+
+module.exports = {
+ hoverPoints: hoverPoints,
+ makeHoverPointText: makeHoverPointText
+};
diff --git a/src/traces/scattersmith/index.js b/src/traces/scattersmith/index.js
new file mode 100644
index 00000000000..39716b39e02
--- /dev/null
+++ b/src/traces/scattersmith/index.js
@@ -0,0 +1,33 @@
+'use strict';
+
+module.exports = {
+ moduleType: 'trace',
+ name: 'scattersmith',
+ basePlotModule: require('../../plots/smith'),
+ categories: ['smith', 'symbols', 'showLegend', 'scatter-like'],
+
+ attributes: require('./attributes'),
+ supplyDefaults: require('./defaults'),
+ colorbar: require('../scatter/marker_colorbar'),
+ formatLabels: require('./format_labels'),
+ calc: require('./calc'),
+ plot: require('./plot'),
+ style: require('../scatter/style').style,
+ styleOnSelect: require('../scatter/style').styleOnSelect,
+ hoverPoints: require('./hover').hoverPoints,
+ selectPoints: require('../scatter/select'),
+
+ meta: {
+ hrName: 'scatter_smith',
+ description: [
+ // TODO: improve me!
+ 'The scattersmith trace type encompasses line charts, scatter charts, text charts, and bubble charts',
+ 'in smith coordinates.',
+ 'The data visualized as scatter point or lines is set in',
+ '`real` and `imag` (imaginary) coordinates',
+ 'Text (appearing either on the chart or on hover only) is via `text`.',
+ 'Bubble charts are achieved by setting `marker.size` and/or `marker.color`',
+ 'to numerical arrays.'
+ ].join(' ')
+ }
+};
diff --git a/src/traces/scattersmith/plot.js b/src/traces/scattersmith/plot.js
new file mode 100644
index 00000000000..5a9c12a3bcf
--- /dev/null
+++ b/src/traces/scattersmith/plot.js
@@ -0,0 +1,39 @@
+'use strict';
+
+var scatterPlot = require('../scatter/plot');
+var BADNUM = require('../../constants/numerical').BADNUM;
+var helpers = require('../../plots/smith/helpers');
+var smith = helpers.smith;
+
+module.exports = function plot(gd, subplot, moduleCalcData) {
+ var mlayer = subplot.layers.frontplot.select('g.scatterlayer');
+
+ var plotinfo = {
+ xaxis: subplot.xaxis,
+ yaxis: subplot.yaxis,
+ plot: subplot.framework,
+ layerClipId: subplot._hasClipOnAxisFalse ? subplot.clipIds.forTraces : null
+ };
+
+ // convert:
+ // 'c' (real,imag) -> (x,y)
+ for(var i = 0; i < moduleCalcData.length; i++) {
+ var cdi = moduleCalcData[i];
+
+ for(var j = 0; j < cdi.length; j++) {
+ var cd = cdi[j];
+ var real = cd.real;
+
+ if(real === BADNUM) {
+ cd.x = cd.y = BADNUM;
+ } else {
+ var t = smith([real, cd.imag]);
+
+ cd.x = t[0];
+ cd.y = t[1];
+ }
+ }
+ }
+
+ scatterPlot(gd, plotinfo, moduleCalcData, mlayer);
+};
diff --git a/tasks/test_mock.js b/tasks/test_mock.js
index 82cf6aeabcc..f78359acc12 100644
--- a/tasks/test_mock.js
+++ b/tasks/test_mock.js
@@ -80,6 +80,7 @@ function notBlackListed(name) {
// has transforms See https://github.com/plotly/plotly.js/issues/4759
'gl2d_transforms',
'polar_transforms',
+ 'smith_transforms',
'transforms',
// has contourcarpet See https://github.com/plotly/plotly.js/issues/5669
diff --git a/test/image/baselines/smith_basic.png b/test/image/baselines/smith_basic.png
new file mode 100644
index 00000000000..c6c147affa0
Binary files /dev/null and b/test/image/baselines/smith_basic.png differ
diff --git a/test/image/baselines/smith_blank.png b/test/image/baselines/smith_blank.png
new file mode 100644
index 00000000000..ef07af29a22
Binary files /dev/null and b/test/image/baselines/smith_blank.png differ
diff --git a/test/image/baselines/smith_fills.png b/test/image/baselines/smith_fills.png
new file mode 100644
index 00000000000..de41124d90b
Binary files /dev/null and b/test/image/baselines/smith_fills.png differ
diff --git a/test/image/baselines/smith_gaps.png b/test/image/baselines/smith_gaps.png
new file mode 100644
index 00000000000..0b5efb1a5d5
Binary files /dev/null and b/test/image/baselines/smith_gaps.png differ
diff --git a/test/image/baselines/smith_modes.png b/test/image/baselines/smith_modes.png
new file mode 100644
index 00000000000..386a6b6eef3
Binary files /dev/null and b/test/image/baselines/smith_modes.png differ
diff --git a/test/image/baselines/smith_subplots.png b/test/image/baselines/smith_subplots.png
new file mode 100644
index 00000000000..4add0337fc3
Binary files /dev/null and b/test/image/baselines/smith_subplots.png differ
diff --git a/test/image/baselines/smith_template.png b/test/image/baselines/smith_template.png
new file mode 100644
index 00000000000..fad15bfe01d
Binary files /dev/null and b/test/image/baselines/smith_template.png differ
diff --git a/test/image/baselines/smith_transforms.png b/test/image/baselines/smith_transforms.png
new file mode 100644
index 00000000000..de9db8ffcef
Binary files /dev/null and b/test/image/baselines/smith_transforms.png differ
diff --git a/test/image/export_test.js b/test/image/export_test.js
index 5b8e53119bc..3fb1c90cf57 100644
--- a/test/image/export_test.js
+++ b/test/image/export_test.js
@@ -27,6 +27,7 @@ var DEFAULT_LIST = [
'gl2d_no-clustering2',
'gl3d_surface-heatmap-treemap_transparent-colorscale',
'mapbox_stamen-style',
+ 'smith_modes',
'zsmooth_methods',
'fonts',
'mathjax'
diff --git a/test/image/make_exports.py b/test/image/make_exports.py
index 721468f87f3..0e7ccd604db 100644
--- a/test/image/make_exports.py
+++ b/test/image/make_exports.py
@@ -28,6 +28,7 @@
'gl2d_no-clustering2',
'gl3d_surface-heatmap-treemap_transparent-colorscale',
'mapbox_stamen-style',
+ 'smith_modes',
'zsmooth_methods',
'fonts',
'worldcup',
diff --git a/test/image/mocks/smith_basic.json b/test/image/mocks/smith_basic.json
new file mode 100644
index 00000000000..463a03a83ca
--- /dev/null
+++ b/test/image/mocks/smith_basic.json
@@ -0,0 +1,31 @@
+{
+ "data": [
+ {
+ "type": "scattersmith",
+ "real": [0, 0, 1, 1, 2, 5, 10],
+ "imag": [0, 1, 0, -2, -2, -5, -10],
+ "mode": "lines+markers",
+ "marker": {
+ "size": 20,
+ "opacity": 0.5
+ }
+ }
+ ],
+ "layout": {
+ "showlegend": false,
+ "paper_bgcolor": "lightgray",
+ "margin": {
+ "t": 40,
+ "b": 40,
+ "r": 40,
+ "l": 40
+ },
+ "width": 800,
+ "height": 800,
+ "smith": {
+ "realaxis": {
+ "tickvals": [0.2, 0.4, 0.6, 0.8, 1, 1.5, 2, 3, 4, 5, 10, 20]
+ }
+ }
+ }
+}
diff --git a/test/image/mocks/smith_blank.json b/test/image/mocks/smith_blank.json
new file mode 100644
index 00000000000..4bafc91ba6c
--- /dev/null
+++ b/test/image/mocks/smith_blank.json
@@ -0,0 +1,107 @@
+{
+ "data": [{
+ "type": "scattersmith",
+ "real": [],
+ "imag": []
+ }, {
+ "type": "scattersmith",
+ "real": [],
+ "imag": [],
+ "subplot": "smith2"
+ }, {
+ "type": "scattersmith",
+ "real": [],
+ "imag": [],
+ "subplot": "smith3"
+ }, {
+ "type": "scattersmith",
+ "mode": "markers+text",
+ "real": [0, 1, 1, 0],
+ "imag": [0, 0, 1, 1],
+ "marker": {
+ "size": 20,
+ "color": ["red", "green", "blue", "orange"]
+ },
+ "text": ["red", "green", "blue", "orange"],
+ "textposition": ["right", "bottom", "left", "top"],
+ "textfont": {
+ "color": ["red", "green", "blue", "orange"]
+ },
+ "cliponaxis": false,
+ "subplot": "smith4"
+ }, {
+ "type": "scattersmith",
+ "real": [1],
+ "imag": [0],
+ "subplot": "smith5"
+ }],
+ "layout": {
+ "smith": {
+ "domain": {
+ "x": [0, 0.46],
+ "y": [0.56, 1]
+ },
+ "realaxis": {
+ "side": "top"
+ }
+ },
+ "smith2": {
+ "domain": {
+ "x": [0, 0.46],
+ "y": [0, 0.44]
+ },
+ "imaginaryaxis": {
+ "showline": true,
+ "showgrid": false,
+ "showticklabels": false,
+ "ticks": ""
+ },
+ "realaxis": {
+ "showline": false,
+ "showgrid": false,
+ "showticklabels": false,
+ "ticks": ""
+ }
+ },
+ "smith3": {
+ "domain": {
+ "x": [0.54, 1],
+ "y": [0.56, 1]
+ },
+ "realaxis": {
+ "ticks": "top",
+ "side": "bottom"
+ },
+ "imaginaryaxis": {"visible": false}
+ },
+ "smith4": {
+ "domain": {
+ "x": [0.54, 1],
+ "y": [0, 0.44]
+ },
+ "realaxis": {"visible": false}
+ },
+ "smith5": {
+ "domain": {
+ "x": [0.12, 0.34],
+ "y": [0.11, 0.34]
+ },
+ "realaxis": {
+ "ticks": "",
+ "tickvals": [0, 1, 2, 3]
+ },
+ "imaginaryaxis": {
+ "tickvals": [-3, -2, -1, 0, 1, 2, 3]
+ }
+ },
+ "showlegend": false,
+ "width": 500,
+ "height": 500,
+ "margin": {
+ "t": 30,
+ "b": 30,
+ "l": 30,
+ "r": 30
+ }
+ }
+}
diff --git a/test/image/mocks/smith_fills.json b/test/image/mocks/smith_fills.json
new file mode 100644
index 00000000000..284301bca8f
--- /dev/null
+++ b/test/image/mocks/smith_fills.json
@@ -0,0 +1,66 @@
+{
+ "data": [{
+ "type": "scattersmith",
+ "mode": "lines",
+ "real": [1, 0.1, 0.1, 1, 1],
+ "imag": [1, 1, 0.2, 0.2, 1],
+ "fill": "toself",
+ "hoveron": "fills"
+ }, {
+ "type": "scattersmith",
+ "mode": "lines",
+ "real": [1, 0.1, 0.1, 1, 1],
+ "imag": [-1, -1, -0.2, -0.2, -1],
+ "line": { "shape": "spline" },
+ "fill": "toself",
+ "hoveron": "fills"
+ }, {
+ "type": "scattersmith",
+ "mode": "markers+lines",
+ "real": [1, 0.1, 0.1, 1, 1],
+ "imag": [1, 1, 0.2, 0.2, 1],
+ "fill": "toself",
+ "hoveron": "fills",
+ "subplot": "smith2"
+ }, {
+ "type": "scattersmith",
+ "mode": "markers",
+ "real": [1, 0.1, 0.1, 1, 1],
+ "imag": [-1, -1, -0.2, -0.2, -1],
+ "fill": "toself",
+ "hoveron": "fills",
+ "subplot": "smith2"
+ }],
+ "layout": {
+ "smith": {
+ "domain": {
+ "x": [0, 1],
+ "y": [0, 0.46]
+ },
+ "realaxis": {
+ "ticks": "top",
+ "side": "bottom"
+ },
+ "imaginaryaxis": {
+ "ticks": "outside"
+ }
+ },
+ "smith2": {
+ "domain": {
+ "x": [0, 1],
+ "y": [0.54, 1]
+ },
+ "realaxis": {
+ "ticks": "top",
+ "side": "top"
+ },
+ "imaginaryaxis": {
+ "ticks": "inside"
+ }
+ },
+ "showlegend": false,
+ "margin": {"t": 40, "b": 40},
+ "width": 500,
+ "height": 800
+ }
+}
diff --git a/test/image/mocks/smith_gaps.json b/test/image/mocks/smith_gaps.json
new file mode 100644
index 00000000000..f1c64de8cd1
--- /dev/null
+++ b/test/image/mocks/smith_gaps.json
@@ -0,0 +1,65 @@
+{
+ "data": [
+ {
+ "type": "scattersmith",
+ "name": "gaps",
+ "real": [
+ 0, 0.2, 0.4, null, 0.8, 1, null, 2, 3, null, 5
+ ],
+ "imag": [
+ 0, 0.2, 0.4, null, 0.8, 1, null, 2, 3, null, 5
+ ],
+ "mode": "markers+lines",
+ "line": { "shape": "spline" }
+ },
+ {
+ "type": "scattersmith",
+ "name": "connectgaps",
+ "connectgaps": true,
+ "real": [
+ 0, 0.2, 0.4, null, 0.8, 1, null, 2, 3, null, 5
+ ],
+ "imag": [
+ 0, 0.2, 0.4, null, 0.8, 1, null, 2, 3, null, 5
+ ],
+ "mode": "markers+lines",
+ "line": { "shape": "spline" },
+ "subplot": "smith2"
+ }
+ ],
+ "layout": {
+ "smith": {
+ "domain": {
+ "x": [
+ 0,
+ 1
+ ],
+ "y": [
+ 0,
+ 0.45
+ ]
+ }
+ },
+ "smith2": {
+ "domain": {
+ "x": [
+ 0,
+ 1
+ ],
+ "y": [
+ 0.55,
+ 1
+ ]
+ }
+ },
+ "legend": { "orientation": "h" },
+ "margin": {
+ "t": 30,
+ "b": 30,
+ "r": 30,
+ "l": 30
+ },
+ "width": 300,
+ "height": 600
+ }
+}
diff --git a/test/image/mocks/smith_modes.json b/test/image/mocks/smith_modes.json
new file mode 100644
index 00000000000..6608552bc7d
--- /dev/null
+++ b/test/image/mocks/smith_modes.json
@@ -0,0 +1,134 @@
+{
+ "data": [
+ {
+ "type": "scattersmith",
+ "real": [0, 1, 0, 1],
+ "imag": [0, 0, 1, 1],
+ "mode": "markers",
+ "marker": {
+ "symbol": ["arrow-left", "arrow-down", "arrow-up", "arrow-right"],
+ "color": ["#F70", "red", "green", "blue"],
+ "size": 20
+ }
+ },
+ {
+ "type": "scattersmith",
+ "real": [0, 1, 0, 1],
+ "imag": [0, 0, 1, 1],
+ "text": ["A", "B", "C", "D"],
+ "mode": "markers+lines+text",
+ "marker": {
+ "size": 20,
+ "opacity": 0.5
+ },
+ "line": {
+ "width": 3,
+ "dash": "dot"
+ },
+ "cliponaxis": true,
+ "subplot": "smith2"
+ },
+ {
+ "type": "scattersmith",
+ "real": [],
+ "imag": [],
+ "subplot": "smith3"
+ },
+ {
+ "type": "scattersmith",
+ "real": [0, 1, 0, 1],
+ "imag": [0, 0, 1, 1],
+ "mode": "markers+text",
+ "marker": {
+ "symbol": "x",
+ "size": 10
+ },
+ "textposition": ["right", "top", "bottom", "left"],
+ "texttemplate": "[%{real}, %{imag}]",
+ "textfont": { "size": 20 },
+ "subplot": "smith4"
+ }
+ ],
+ "layout": {
+ "smith": {
+ "domain": {
+ "x": [
+ 0,
+ 0.46
+ ],
+ "y": [
+ 0.56,
+ 1
+ ]
+ }
+ },
+ "smith2": {
+ "domain": {
+ "x": [
+ 0,
+ 0.46
+ ],
+ "y": [
+ 0,
+ 0.44
+ ]
+ }
+ },
+ "smith3": {
+ "domain": {
+ "x": [
+ 0.54,
+ 1
+ ],
+ "y": [
+ 0.56,
+ 1
+ ]
+ },
+ "realaxis": {
+ "side": "bottom",
+ "ticks": "bottom",
+ "tickfont": {
+ "color": "white"
+ },
+ "gridcolor": "blue",
+ "linecolor": "white",
+ "linewidth": 3,
+ "gridwidth": 2
+ },
+ "imaginaryaxis": {
+ "ticks": "inside",
+ "tickcolor": "white",
+ "gridcolor": "darkred",
+ "linecolor": "red",
+ "linewidth": 3,
+ "gridwidth": 2
+ },
+ "bgcolor": "black"
+ },
+ "smith4": {
+ "domain": {
+ "x": [
+ 0.54,
+ 1
+ ],
+ "y": [
+ 0,
+ 0.44
+ ]
+ },
+ "realaxis": {
+ "showticklabels": false
+ }
+ },
+ "showlegend": false,
+ "margin": {
+ "t": 40,
+ "b": 40,
+ "r": 40,
+ "l": 40
+ },
+ "width": 540,
+ "height": 540
+ }
+}
diff --git a/test/image/mocks/smith_subplots.json b/test/image/mocks/smith_subplots.json
new file mode 100644
index 00000000000..c8be6b9aeb4
--- /dev/null
+++ b/test/image/mocks/smith_subplots.json
@@ -0,0 +1,78 @@
+{
+ "data": [{
+ "type": "scattersmith",
+ "mode": "markers+lines+text",
+ "real": [0, 1, 1, 0],
+ "imag": [0, 0, 1, 1],
+ "text": ["A0", "B0", "C0"],
+ "hovertext": ["hover A0", "hover B0", "hover C0"],
+ "line": {"shape": "spline"},
+ "marker": {
+ "symbol": ["circle", "square", "x", "diamond"],
+ "gradient": {
+ "type": ["radial", "horizontal", "radial", "vertical"],
+ "color": ["white", "yellow", "orange", "red"]
+ },
+ "size": 30
+ },
+ "textfont": {
+ "color": ["red", "green", "blue"],
+ "size": 20
+ },
+ "textposition": ["top left", "bottom right", "bottom right"]
+ }, {
+ "type": "scattersmith",
+ "mode": "markers+lines+text",
+ "real": [0, 1, 1, 0],
+ "imag": [0, 0, 1, 1],
+ "text": ["A1", "B1", "C1"],
+ "hovertext": ["hover A1", "hover B1", "hover C1"],
+ "line": {
+ "shape": "spline",
+ "dash": "dash",
+ "width": 4
+ },
+ "marker": {
+ "symbol": "square",
+ "size": 15,
+ "color": [0, 2, 1, 3],
+ "opacity": 0.75,
+ "colorscale": "Portland",
+ "reversescale": true,
+ "showscale": true
+ },
+ "textfont": {
+ "color": "green",
+ "size": [20, 15, 10]
+ },
+ "textposition": ["top left", "bottom right", "bottom right"],
+ "subplot": "smith2"
+ }],
+ "layout": {
+ "width": 800,
+ "height": 400,
+ "margin": {
+ "t": 40,
+ "b": 40,
+ "l": 40,
+ "r": 40
+ },
+ "showlegend": false,
+ "smith": {
+ "domain": {
+ "x": [0.05, 0.45]
+ },
+ "realaxis": {
+ "showgrid": false
+ }
+ },
+ "smith2": {
+ "domain": {
+ "x": [0.55, 0.95]
+ },
+ "imaginaryaxis": {
+ "showgrid": false
+ }
+ }
+ }
+}
diff --git a/test/image/mocks/smith_template.json b/test/image/mocks/smith_template.json
new file mode 100644
index 00000000000..dfd39935f94
--- /dev/null
+++ b/test/image/mocks/smith_template.json
@@ -0,0 +1,75 @@
+{
+ "data": [
+ {
+ "real": [0, 0, 1, 1],
+ "imag": [0, 1, 1, 0],
+ "type": "scattersmith"
+ }
+ ],
+ "layout": {
+ "width": 400,
+ "height": 400,
+ "template": {
+ "data": {
+ "scattersmith": [
+ {
+ "marker": {
+ "opacity": 0.5,
+ "color": "hotpink",
+ "size": 20
+ },
+ "line": {
+ "color": "cyan"
+ }
+ }
+ ]
+ },
+ "layout": {
+ "margin": {
+ "t": 40,
+ "b": 40,
+ "l": 40,
+ "r": 40
+ },
+ "paper_bgcolor": "lightblue",
+ "smith": {
+ "bgcolor": "darkred",
+ "realaxis": {
+ "tickvals": [0.125, 0.25, 0.5, 1, 2, 4],
+ "tickfont": {
+ "family": "Gravitas One",
+ "size": 14,
+ "color": "orange"
+ },
+ "tickangle": -90,
+ "tickprefix": "[",
+ "ticksuffix": "]",
+ "side": "bottom",
+ "ticks": "bottom",
+ "ticklen": 10,
+ "tickwidth": 5,
+ "tickcolor": "yellow",
+ "gridcolor": "white",
+ "linecolor": "white"
+ },
+ "imaginaryaxis": {
+ "tickvals": [-4, -2, -1, -0.5, 0, 0.5, 1, 2, 4],
+ "tickfont": {
+ "family": "Times New Roman",
+ "size": 16,
+ "color": "darkblue"
+ },
+ "tickprefix": "i ",
+ "ticksuffix": " j",
+ "ticks": "inside",
+ "ticklen": 10,
+ "tickwidth": 5,
+ "tickcolor": "darkblue",
+ "gridcolor": "white",
+ "linecolor": "white"
+ }
+ }
+ }
+ }
+ }
+}
diff --git a/test/image/mocks/smith_transforms.json b/test/image/mocks/smith_transforms.json
new file mode 100644
index 00000000000..f6ba28e7291
--- /dev/null
+++ b/test/image/mocks/smith_transforms.json
@@ -0,0 +1,78 @@
+{
+ "data": [{
+ "type": "scattersmith",
+ "mode": "lines+markers",
+ "real": [1, -1, -2, 0, 1, 3, 3],
+ "imag": [2, 1, 0, 1, 3, 4, 3],
+ "transforms": [{
+ "type": "groupby",
+ "groups": ["a", "a", "b", "a", "b", "b", "a"],
+ "styles": [
+ {"target": "a", "value": {"marker": {"color": "orange"}}},
+ {"target": "b", "value": {"marker": {"color": "blue"}}}
+ ]
+ }, {
+ "type": "filter",
+ "target": "real",
+ "operation": ">=",
+ "value": 0,
+ "preservegaps": true
+ }],
+ "name": "Groupby+filter"
+ },
+ {
+ "type": "scattersmith",
+ "real": [1, 2, 3, 4, -3],
+ "imag": [1.1, 2.2, 3.3, 4.4, 5.5],
+ "marker": {
+ "size": [0.3, 0.2, 0.1, 0.4, 0.5],
+ "sizeref": 0.01,
+ "color": [2, 4, 6, 10, 8],
+ "opacity": [0.9, 0.6, 0.2, 0.8, 1.0],
+ "line": {
+ "color": [2.2, 3.3, 4.4, 5.5, 1.1]
+ }
+ },
+ "transforms": [{
+ "type": "aggregate",
+ "groups": ["a", "b", "a", "a", "a"],
+ "aggregations": [
+ {"target": "real", "func": "sum"},
+ {"target": "imag", "func": "avg"},
+ {"target": "marker.size", "func": "min"},
+ {"target": "marker.color", "func": "max"},
+ {"target": "marker.line.color", "func": "last"},
+ {"target": "marker.line.width", "func": "count"}
+ ]
+ }],
+ "name": "Aggregate"
+ },
+ {
+ "type": "scattersmith",
+ "real": [1, 2, 3, 4, 5, 6],
+ "imag": [1, 4, 2, 6, 5, 3],
+ "transforms": [{
+ "type": "sort",
+ "target": [1, 6, 2, 5, 3, 4]
+ }],
+ "name": "Sort"
+ },
+ {
+ "type": "scattersmith",
+ "real" :[4, 5, 6, 4, 5, 6],
+ "imag": [1, 1, 1, 2, 2, 2],
+ "marker": {"color": [1, 2, 3, -1, -2, -3], "size": 12},
+ "mode": "lines+markers",
+ "transforms": [
+ {"type": "groupby", "groups": [1, 1, 1, 2, 2, 2]}
+ ]
+ }],
+ "layout": {
+ "legend": {
+ "orientation": "h"
+ },
+ "width": 500,
+ "height": 500,
+ "title": {"text": "Transforms on smith subplot"}
+ }
+}
diff --git a/test/jasmine/assets/mock_lists.js b/test/jasmine/assets/mock_lists.js
index a7112686864..dd7532fa6b4 100644
--- a/test/jasmine/assets/mock_lists.js
+++ b/test/jasmine/assets/mock_lists.js
@@ -38,6 +38,7 @@ var svgMockList = [
['icicle_coffee', require('@mocks/icicle_coffee.json')],
['parcats_bad-displayindex', require('@mocks/parcats_bad-displayindex.json')],
['scattercarpet', require('@mocks/scattercarpet.json')],
+ ['smith_basic', require('@mocks/smith_basic.json')],
['shapes', require('@mocks/shapes.json')],
['splom_iris', require('@mocks/splom_iris.json')],
['table_wrapped_birds', require('@mocks/table_wrapped_birds.json')],
diff --git a/test/jasmine/bundle_tests/plotschema_test.js b/test/jasmine/bundle_tests/plotschema_test.js
index a8839522a92..171eaf5e869 100644
--- a/test/jasmine/bundle_tests/plotschema_test.js
+++ b/test/jasmine/bundle_tests/plotschema_test.js
@@ -134,7 +134,7 @@ describe('plot schema', function() {
var cnt = 0;
var astrs = [
- 'xaxis', 'yaxis', 'scene', 'geo', 'ternary', 'mapbox', 'polar',
+ 'xaxis', 'yaxis', 'scene', 'geo', 'ternary', 'mapbox', 'polar', 'smith',
// not really a 'subplot' object but supports yaxis, yaxis2, yaxis3,
// ... counters, so list it here
'xaxis.rangeslider.yaxis',
diff --git a/test/jasmine/tests/plot_api_react_test.js b/test/jasmine/tests/plot_api_react_test.js
index 90e54d81184..fc0b3a4846f 100644
--- a/test/jasmine/tests/plot_api_react_test.js
+++ b/test/jasmine/tests/plot_api_react_test.js
@@ -461,6 +461,28 @@ describe('@noCIdep Plotly.react', function() {
.then(done, done.fail);
});
+ it('can put smith plots into staticPlot mode', function(done) {
+ var data = [{real: [0, 1, 2], imag: [0, 1, 2], type: 'scattersmith'}];
+ var layout = {};
+
+ Plotly.newPlot(gd, data, layout)
+ .then(countPlots)
+ .then(function() {
+ expect(d3Select(gd).selectAll('.drag').size()).toBe(1);
+
+ return Plotly.react(gd, data, layout, {staticPlot: true});
+ })
+ .then(function() {
+ expect(d3Select(gd).selectAll('.drag').size()).toBe(0);
+
+ return Plotly.react(gd, data, layout, {});
+ })
+ .then(function() {
+ expect(d3Select(gd).selectAll('.drag').size()).toBe(1);
+ })
+ .then(done, done.fail);
+ });
+
it('can change from scatter to category scatterpolar and back', function(done) {
function scatter() {
return {
diff --git a/test/jasmine/tests/scattersmith_test.js b/test/jasmine/tests/scattersmith_test.js
new file mode 100644
index 00000000000..e841a84977f
--- /dev/null
+++ b/test/jasmine/tests/scattersmith_test.js
@@ -0,0 +1,152 @@
+var Plotly = require('@lib/index');
+var Lib = require('@src/lib');
+var ScatterSmith = require('@src/traces/scattersmith');
+
+var basicMock = require('@mocks/smith_basic.json');
+
+var createGraphDiv = require('../assets/create_graph_div');
+var destroyGraphDiv = require('../assets/destroy_graph_div');
+
+var mouseEvent = require('../assets/mouse_event');
+
+var customAssertions = require('../assets/custom_assertions');
+var assertHoverLabelContent = customAssertions.assertHoverLabelContent;
+var checkTextTemplate = require('../assets/check_texttemplate');
+
+describe('Test scattersmith trace defaults:', function() {
+ var traceOut;
+
+ function _supply(traceIn, layout) {
+ traceOut = {};
+ ScatterSmith.supplyDefaults(traceIn, traceOut, '#444', layout || {});
+ }
+
+ it('should not truncate *real* when longer than *imag*', function() {
+ // this is handled at the calc step now via _length.
+ _supply({
+ real: [1, 2, 3, 4, 5],
+ imag: [1, 2, 3]
+ });
+
+ expect(traceOut.real).toEqual([1, 2, 3, 4, 5]);
+ expect(traceOut.imag).toEqual([1, 2, 3]);
+ expect(traceOut._length).toBe(3);
+ });
+
+ it('should not truncate *imag* when longer than *real*', function() {
+ // this is handled at the calc step now via _length.
+ _supply({
+ real: [1, 2, 3],
+ imag: [1, 2, 3, 4, 5]
+ });
+
+ expect(traceOut.real).toEqual([1, 2, 3]);
+ expect(traceOut.imag).toEqual([1, 2, 3, 4, 5]);
+ expect(traceOut._length).toBe(3);
+ });
+});
+
+describe('Test scattersmith hover:', function() {
+ var gd;
+
+ afterEach(destroyGraphDiv);
+
+ function run(specs) {
+ gd = createGraphDiv();
+
+ var fig = Lib.extendDeep(basicMock);
+
+ if(specs.patch) {
+ fig = specs.patch(fig);
+ }
+
+ return Plotly.newPlot(gd, fig).then(function() {
+ mouseEvent('mousemove', 400, 70);
+ assertHoverLabelContent(specs);
+ });
+ }
+
+ [{
+ desc: 'base',
+ nums: 'real: 0\nimag: 1'
+ }, {
+ desc: 'with tickformat',
+ patch: function(fig) {
+ fig.layout.smith = {
+ realaxis: { tickformat: '.1f' },
+ imaginaryaxis: { tickformat: '.2f' }
+ };
+ return fig;
+ },
+ nums: 'real: 0.0\nimag: 1.00'
+ }, {
+ desc: 'with prefix and suffix',
+ patch: function(fig) {
+ fig.layout.smith = {
+ realaxis: {
+ tickprefix: '(',
+ ticksuffix: ')'
+ },
+ imaginaryaxis: {
+ tickprefix: '[',
+ ticksuffix: ']'
+ }
+ };
+ return fig;
+ },
+ nums: 'real: (0)\nimag: [1]'
+ }, {
+ desc: 'with prefix and suffix on invisible axes',
+ patch: function(fig) {
+ fig.layout.smith = {
+ realaxis: {
+ visible: false,
+ tickprefix: '(',
+ ticksuffix: ')'
+ },
+ imaginaryaxis: {
+ visible: false,
+ tickprefix: '[',
+ ticksuffix: ']'
+ }
+ };
+ return fig;
+ },
+ nums: 'real: (0)\nimag: [1]'
+ }].forEach(function(specs) {
+ it('should generate correct hover labels ' + specs.desc, function(done) {
+ run(specs).then(done, done.fail);
+ });
+ });
+});
+
+describe('Test scattersmith texttemplate:', function() {
+ checkTextTemplate([{
+ 'type': 'scattersmith',
+ 'mode': 'markers+text',
+ 'text': ['A', 'B', 'C'],
+ 'textposition': 'top center',
+ 'real': [1, 0.5, 1],
+ 'imag': [0, 90, 180],
+ }], 'g.textpoint', [
+ ['%{text}: (%{real:0.2f}, %{imag:0.1f})', ['A: (1.00, 0.0)', 'B: (0.50, 90.0)', 'C: (1.00, 180.0)']],
+ [['', 'b%{imag:0.2f}', '%{imag:0.2f}'], ['', 'b90.00', '180.00']]
+ ]);
+
+ checkTextTemplate({
+ data: [{
+ type: 'scattersmith',
+ mode: 'text',
+ real: ['0.125', '0.625'],
+ imag: ['0.5', '1']
+ }],
+ layout: {
+ smith: {
+ realaxis: { tickprefix: 'R', ticksuffix: 'r', tickformat: '.1f'},
+ imaginaryaxis: { tickprefix: 'I', ticksuffix: 'i' }
+ }
+ }
+ }, '.textpoint', [
+ ['%{real} X %{imag}', ['R0.1r X I0.5i', 'R0.6r X I1i']]
+ ]);
+});
diff --git a/test/jasmine/tests/select_test.js b/test/jasmine/tests/select_test.js
index 233af05aae7..d0f3b2027b8 100644
--- a/test/jasmine/tests/select_test.js
+++ b/test/jasmine/tests/select_test.js
@@ -2205,6 +2205,47 @@ describe('Test select box and lasso per trace:', function() {
});
});
+ [false, true].forEach(function(hasCssTransform) {
+ it('should work on scattersmith traces, hasCssTransform: ' + hasCssTransform, function(done) {
+ var assertPoints = makeAssertPoints(['real', 'imag']);
+ var assertSelectedPoints = makeAssertSelectedPoints();
+
+ var fig = Lib.extendDeep({}, require('@mocks/smith_basic.json'));
+ fig.layout.dragmode = 'select';
+ addInvisible(fig);
+
+ Plotly.newPlot(gd, fig)
+ .then(function() {
+ if(hasCssTransform) transformPlot(gd, cssTransform);
+
+ return _run(hasCssTransform,
+ [[260, 260], [460, 460]],
+ function() {
+ assertPoints([[1, 0]]);
+ assertSelectedPoints({0: [2]});
+ },
+ [360, 360],
+ BOXEVENTS, 'scattersmith select'
+ );
+ })
+ .then(function() {
+ return Plotly.relayout(gd, 'dragmode', 'lasso');
+ })
+ .then(function() {
+ return _run(hasCssTransform,
+ [[260, 260], [260, 460], [460, 460], [460, 260], [260, 260]],
+ function() {
+ assertPoints([[1, 0]]);
+ assertSelectedPoints({0: [2]});
+ },
+ [360, 360],
+ LASSOEVENTS, 'scattersmith lasso'
+ );
+ })
+ .then(done, done.fail);
+ });
+ });
+
[false, true].forEach(function(hasCssTransform) {
it('should work on barpolar traces, hasCssTransform: ' + hasCssTransform, function(done) {
var assertPoints = makeAssertPoints(['r', 'theta']);
diff --git a/test/jasmine/tests/smith_test.js b/test/jasmine/tests/smith_test.js
new file mode 100644
index 00000000000..cf655b30844
--- /dev/null
+++ b/test/jasmine/tests/smith_test.js
@@ -0,0 +1,377 @@
+var Plotly = require('@lib/index');
+var Lib = require('@src/lib');
+var Smith = require('@src/plots/smith');
+
+var basicMock = require('@mocks/smith_basic.json');
+
+var d3Select = require('../../strict-d3').select;
+var d3SelectAll = require('../../strict-d3').selectAll;
+var createGraphDiv = require('../assets/create_graph_div');
+var destroyGraphDiv = require('../assets/destroy_graph_div');
+
+var mouseEvent = require('../assets/mouse_event');
+var click = require('../assets/click');
+var doubleClick = require('../assets/double_click');
+
+describe('Test smith plots defaults:', function() {
+ var layoutOut;
+
+ function _supply(layoutIn, fullData) {
+ fullData = fullData || [{
+ type: 'scattersmith',
+ real: [],
+ imag: [],
+ subplot: 'smith'
+ }];
+
+ layoutOut = {
+ noUirevision: true,
+ font: {color: 'red'},
+ _subplots: {smith: ['smith']}
+ };
+
+ Smith.supplyLayoutDefaults(layoutIn, layoutOut, fullData);
+ }
+
+ it('should contain correct default top level values', function() {
+ _supply({
+ smith: {}
+ });
+
+ var smith = layoutOut.smith;
+
+ expect(smith.domain.x).toEqual([0, 1]);
+ expect(smith.domain.y).toEqual([0, 1]);
+ expect(smith.bgcolor).toBe('#fff');
+ });
+
+ it('should propagate axis *color* settings', function() {
+ _supply({
+ smith: {
+ imaginaryaxis: {color: 'red'},
+ realaxis: {color: 'blue'}
+ }
+ });
+
+ expect(layoutOut.smith.imaginaryaxis.linecolor).toBe('red');
+ expect(layoutOut.smith.imaginaryaxis.gridcolor).toBe('rgb(255, 153, 153)', 'blend by 60% with bgcolor');
+
+ expect(layoutOut.smith.realaxis.linecolor).toBe('blue');
+ expect(layoutOut.smith.realaxis.gridcolor).toBe('rgb(153, 153, 255)', 'blend by 60% with bgcolor');
+ });
+
+ it('should coerce hoverformat even for `visible: false` axes', function() {
+ _supply({
+ smith: {
+ realaxis: {
+ visible: false,
+ hoverformat: 'g'
+ },
+ imaginaryaxis: {
+ visible: false,
+ hoverformat: 'g'
+ }
+ }
+ }, [{
+ type: 'scattersmith',
+ real: [1, 2],
+ imag: [90, 180],
+ visible: true,
+ subplot: 'smith'
+ }]);
+
+ expect(layoutOut.smith.realaxis.hoverformat).toBe('g');
+ expect(layoutOut.smith.imaginaryaxis.hoverformat).toBe('g');
+ });
+});
+
+describe('Test relayout on smith subplots:', function() {
+ afterEach(destroyGraphDiv);
+
+ it('should be able to relayout imaginary axis ticks', function(done) {
+ var gd = createGraphDiv();
+ var fig = Lib.extendDeep({}, basicMock);
+
+ function check(cnt, expected) {
+ var ticks = d3SelectAll('path.imaginaryaxistick');
+
+ expect(ticks.size()).toBe(cnt, '# of ticks');
+ ticks.each(function() {
+ expect(d3Select(this).attr('d')).toBe(expected);
+ });
+ }
+
+ Plotly.newPlot(gd, fig).then(function() {
+ check(0);
+ return Plotly.relayout(gd, 'smith.imaginaryaxis', {ticks: 'inside'});
+ })
+ .then(function() {
+ check(26, 'M-0.5,0h-5');
+ return Plotly.relayout(gd, 'smith.imaginaryaxis', {ticks: 'outside'});
+ })
+ .then(function() {
+ check(26, 'M0.5,0h5');
+ return Plotly.relayout(gd, 'smith.imaginaryaxis', {ticks: ''});
+ })
+ .then(function() {
+ check(0);
+ return Plotly.relayout(gd, 'smith.imaginaryaxis', {ticks: 'inside'});
+ })
+ .then(function() {
+ check(26, 'M-0.5,0h-5');
+ })
+ .then(done, done.fail);
+ });
+
+ it('should be able to relayout real axis ticks', function(done) {
+ var gd = createGraphDiv();
+ var fig = Lib.extendDeep({}, basicMock);
+
+ function check(cnt, expected) {
+ var ticks = d3SelectAll('path.xtick');
+
+ expect(ticks.size()).toBe(cnt, '# of ticks');
+ ticks.each(function() {
+ expect(d3Select(this).attr('d')).toBe(expected);
+ });
+ }
+
+ Plotly.newPlot(gd, fig).then(function() {
+ check(0);
+ return Plotly.relayout(gd, 'smith.realaxis', {ticks: 'top'});
+ })
+ .then(function() {
+ check(5, 'M0,-0.5v-5');
+ return Plotly.relayout(gd, 'smith.realaxis', {ticks: 'bottom'});
+ })
+ .then(function() {
+ check(5, 'M0,0.5v5');
+ return Plotly.relayout(gd, 'smith.realaxis', {ticks: ''});
+ })
+ .then(function() {
+ check(0);
+ return Plotly.relayout(gd, 'smith.realaxis', {ticks: 'top'});
+ })
+ .then(function() {
+ check(5, 'M0,-0.5v-5');
+ })
+ .then(done, done.fail);
+ });
+
+ it('should clean up its framework, clip paths and info layers when getting deleted', function(done) {
+ var gd = createGraphDiv();
+ var fig = Lib.extendDeep({}, basicMock);
+ var traces = Lib.extendDeep([], fig.data);
+ var inds = traces.map(function(_, i) { return i; });
+
+ function _assert(exp) {
+ expect(d3SelectAll('g.smith').size()).toBe(exp.subplot, '# subplot layer');
+
+ var clipCnt = 0;
+ d3SelectAll('clipPath').each(function() {
+ if(/smith-for-traces/.test(this.id)) clipCnt++;
+ });
+ expect(clipCnt).toBe(exp.clip, '# clip paths');
+ }
+
+ Plotly.newPlot(gd, fig).then(function() {
+ _assert({subplot: 1, clip: 1});
+
+ return Plotly.deleteTraces(gd, inds);
+ })
+ .then(function() {
+ _assert({subplot: 0, clip: 0});
+
+ return Plotly.addTraces(gd, traces);
+ })
+ .then(function() {
+ _assert({subplot: 1, clip: 1});
+ })
+ .then(done, done.fail);
+ });
+});
+
+describe('Test smith interactions:', function() {
+ var gd;
+ var eventData;
+ var eventCnts;
+
+ var eventNames = [
+ 'plotly_hover', 'plotly_unhover',
+ 'plotly_click', 'plotly_doubleclick',
+ 'plotly_relayout'
+ ];
+
+ beforeEach(function() {
+ jasmine.DEFAULT_TIMEOUT_INTERVAL = 10000;
+ eventData = '';
+ eventCnts = {};
+ gd = createGraphDiv();
+ });
+
+ afterEach(destroyGraphDiv);
+
+ function _plot(fig) {
+ return Plotly.newPlot(gd, fig).then(function() {
+ eventNames.forEach(function(k) {
+ eventCnts[k] = 0;
+ gd.on(k, function(d) {
+ eventData = d;
+ eventCnts[k]++;
+ Lib.clearThrottle();
+ });
+ });
+ });
+ }
+
+ function assertEventPointData(expected, msg) {
+ var actual = eventData.points || [];
+
+ expect(actual.length)
+ .toBe(expected.length, msg + ' same number of pts');
+
+ expected.forEach(function(e, i) {
+ var a = actual[i];
+ var m = msg + ' (pt ' + i + ')';
+
+ for(var k in e) {
+ expect(a[k]).toBeCloseTo(e[k], 1, m + ' ' + k);
+ }
+ });
+ }
+
+ function assertEventCnt(expected, msg) {
+ eventNames.forEach(function(k) {
+ var m = msg + ' event cnt for ' + k;
+
+ if(k in expected) {
+ expect(eventCnts[k]).toBe(expected[k], m);
+ } else {
+ expect(eventCnts[k]).toBe(0, m);
+ }
+ });
+ }
+
+ function _hover(pos) {
+ eventData = '';
+ mouseEvent('mousemove', pos[0], pos[1]);
+ }
+
+ function _unhover(pos) {
+ eventData = '';
+ mouseEvent('mouseout', pos[0], pos[1]);
+ }
+
+ function _click(pos, opts) {
+ eventData = '';
+ gd._mouseDownTime = 0;
+ click(pos[0], pos[1], opts);
+ }
+
+ function _doubleClick(pos) {
+ gd._mouseDownTime = 0;
+ eventData = '';
+ return doubleClick(pos[0], pos[1]);
+ }
+
+ var modClickOpts = {
+ altKey: true,
+ ctrlKey: true, // this makes it effectively into a right-click
+ metaKey: true,
+ shiftKey: true,
+ button: 0,
+ cancelContext: true
+ };
+
+ var rightClickOpts = {
+ altKey: false,
+ ctrlKey: false,
+ metaKey: false,
+ shiftKey: false,
+ button: 2,
+ cancelContext: true
+ };
+
+ it('should trigger hover/unhover/click/doubleclick events', function(done) {
+ var fig = Lib.extendDeep({}, basicMock);
+ var ptPos = [400, 60];
+ var blankPos = [400, 100];
+ var marginPos = [20, 20];
+
+ var exp = [{
+ real: 0,
+ imag: 1
+ }];
+
+ function _assert(ptExpectation, cntExpecation, msg) {
+ if(Array.isArray(ptExpectation)) {
+ assertEventPointData(ptExpectation, msg);
+ } else {
+ expect(eventData).toBe(ptExpectation, msg);
+ }
+ assertEventCnt(cntExpecation, msg);
+ }
+
+ _plot(fig)
+ .then(function() { _hover(ptPos); })
+ .then(function() {
+ _assert(exp, {
+ plotly_hover: 1
+ }, 'after hover on pt');
+ })
+
+ .then(function() { _unhover(blankPos);})
+ .then(function() {
+ _assert(exp, {
+ plotly_hover: 1,
+ plotly_unhover: 1
+ }, 'after unhover off pt');
+ })
+ .then(function() { _hover(marginPos);})
+ .then(function() {
+ _assert('', {
+ plotly_hover: 1,
+ plotly_unhover: 1,
+ }, 'after hovering in margin');
+ })
+ .then(function() { _click(ptPos); })
+ .then(function() {
+ _assert(exp, {
+ plotly_hover: 2,
+ plotly_unhover: 1,
+ plotly_click: 1
+ }, 'after click');
+ })
+ .then(function() { return _doubleClick(ptPos); })
+ .then(function() {
+ assertEventCnt({
+ plotly_hover: 2,
+ plotly_unhover: 1,
+ plotly_click: 3,
+ plotly_doubleclick: 1,
+ plotly_relayout: 1
+ }, 'after doubleclick');
+ })
+ .then(function() { _click(ptPos, modClickOpts); })
+ .then(function() {
+ _assert(exp, {
+ plotly_hover: 2,
+ plotly_unhover: 1,
+ plotly_click: 4,
+ plotly_doubleclick: 1,
+ plotly_relayout: 1
+ }, 'after modified click');
+ })
+ .then(function() { _click(ptPos, rightClickOpts); })
+ .then(function() {
+ _assert(exp, {
+ plotly_hover: 2,
+ plotly_unhover: 1,
+ plotly_click: 5,
+ plotly_doubleclick: 1,
+ plotly_relayout: 1
+ }, 'after right click');
+ })
+ .then(done, done.fail);
+ });
+});
diff --git a/test/plot-schema.json b/test/plot-schema.json
index ba2a41655da..a49f77f14a5 100644
--- a/test/plot-schema.json
+++ b/test/plot-schema.json
@@ -7281,77 +7281,87 @@
},
"role": "object"
},
- "spikedistance": {
- "description": "Sets the default distance (in pixels) to look for data to draw spikelines to (-1 means no cutoff, 0 means no looking for data). As with hoverdistance, distance does not apply to area-like objects. In addition, some objects can be hovered on but will not generate spikelines, such as scatter fills.",
- "dflt": -1,
- "editType": "none",
- "min": -1,
- "valType": "integer"
- },
- "template": {
- "description": "Default attributes to be applied to the plot. Templates can be created from existing plots using `Plotly.makeTemplate`, or created manually. They should be objects with format: `{layout: layoutTemplate, data: {[type]: [traceTemplate, ...]}, ...}` `layoutTemplate` and `traceTemplate` are objects matching the attribute structure of `layout` and a data trace. Trace templates are applied cyclically to traces of each type. Container arrays (eg `annotations`) have special handling: An object ending in `defaults` (eg `annotationdefaults`) is applied to each array item. But if an item has a `templateitemname` key we look in the template array for an item with matching `name` and apply that instead. If no matching `name` is found we mark the item invisible. Any named template item not referenced is appended to the end of the array, so you can use this for a watermark annotation or a logo image, for example. To omit one of these items on the plot, make an item with matching `templateitemname` and `visible: false`.",
- "editType": "calc",
- "valType": "any"
- },
- "ternary": {
+ "smith": {
"_isSubplotObj": true,
- "aaxis": {
- "_deprecated": {
- "title": {
- "description": "Value of `title` is no longer a simple *string* but a set of sub-attributes. To set the axis' title, please use `title.text` now.",
- "editType": "plot",
- "valType": "string"
- },
- "titlefont": {
- "color": {
+ "bgcolor": {
+ "description": "Set the background color of the subplot",
+ "dflt": "#fff",
+ "editType": "plot",
+ "valType": "color"
+ },
+ "domain": {
+ "column": {
+ "description": "If there is a layout grid, use the domain for this column in the grid for this smith subplot .",
+ "dflt": 0,
+ "editType": "plot",
+ "min": 0,
+ "valType": "integer"
+ },
+ "editType": "plot",
+ "role": "object",
+ "row": {
+ "description": "If there is a layout grid, use the domain for this row in the grid for this smith subplot .",
+ "dflt": 0,
+ "editType": "plot",
+ "min": 0,
+ "valType": "integer"
+ },
+ "x": {
+ "description": "Sets the horizontal domain of this smith subplot (in plot fraction).",
+ "dflt": [
+ 0,
+ 1
+ ],
+ "editType": "plot",
+ "items": [
+ {
"editType": "plot",
- "valType": "color"
+ "max": 1,
+ "min": 0,
+ "valType": "number"
},
- "description": "Former `titlefont` is now the sub-attribute `font` of `title`. To customize title font properties, please use `title.font` now.",
- "editType": "plot",
- "family": {
- "description": "HTML font family - the typeface that will be applied by the web browser. The web browser will only be able to apply a font if it is available on the system which it operates. Provide multiple font families, separated by commas, to indicate the preference in which to apply fonts if they aren't available on the system. The Chart Studio Cloud (at https://chart-studio.plotly.com or on-premise) generates images on a server, where only a select number of fonts are installed and supported. These include *Arial*, *Balto*, *Courier New*, *Droid Sans*,, *Droid Serif*, *Droid Sans Mono*, *Gravitas One*, *Old Standard TT*, *Open Sans*, *Overpass*, *PT Sans Narrow*, *Raleway*, *Times New Roman*.",
+ {
"editType": "plot",
- "noBlank": true,
- "strict": true,
- "valType": "string"
+ "max": 1,
+ "min": 0,
+ "valType": "number"
+ }
+ ],
+ "valType": "info_array"
+ },
+ "y": {
+ "description": "Sets the vertical domain of this smith subplot (in plot fraction).",
+ "dflt": [
+ 0,
+ 1
+ ],
+ "editType": "plot",
+ "items": [
+ {
+ "editType": "plot",
+ "max": 1,
+ "min": 0,
+ "valType": "number"
},
- "size": {
+ {
"editType": "plot",
- "min": 1,
+ "max": 1,
+ "min": 0,
"valType": "number"
}
- }
- },
+ ],
+ "valType": "info_array"
+ }
+ },
+ "editType": "calc",
+ "imaginaryaxis": {
"color": {
"description": "Sets default for all colors associated with this axis all at once: line, font, tick, and grid colors. Grid color is lightened by blending this with the plot background Individual pieces can override this.",
"dflt": "#444",
"editType": "plot",
"valType": "color"
},
- "dtick": {
- "description": "Sets the step in-between ticks on this axis. Use with `tick0`. Must be a positive number, or special strings available to *log* and *date* axes. If the axis `type` is *log*, then ticks are set every 10^(n*dtick) where n is the tick number. For example, to set a tick mark at 1, 10, 100, 1000, ... set dtick to 1. To set tick marks at 1, 100, 10000, ... set dtick to 2. To set tick marks at 1, 5, 25, 125, 625, 3125, ... set dtick to log_10(5), or 0.69897000433. *log* has several special values; *L*, where `f` is a positive number, gives ticks linearly spaced in value (but not position). For example `tick0` = 0.1, `dtick` = *L0.5* will put ticks at 0.1, 0.6, 1.1, 1.6 etc. To show powers of 10 plus small digits between, use *D1* (all digits) or *D2* (only 2 and 5). `tick0` is ignored for *D1* and *D2*. If the axis `type` is *date*, then you must convert the time to milliseconds. For example, to set the interval between ticks to one day, set `dtick` to 86400000.0. *date* also has special values *M* gives ticks spaced by a number of months. `n` must be a positive integer. To set ticks on the 15th of every third month, set `tick0` to *2000-01-15* and `dtick` to *M3*. To set ticks every 4 years, set `dtick` to *M48*",
- "editType": "plot",
- "impliedEdits": {
- "tickmode": "linear"
- },
- "valType": "any"
- },
"editType": "plot",
- "exponentformat": {
- "description": "Determines a formatting rule for the tick exponents. For example, consider the number 1,000,000,000. If *none*, it appears as 1,000,000,000. If *e*, 1e+9. If *E*, 1E+9. If *power*, 1x10^9 (with 9 in a super script). If *SI*, 1G. If *B*, 1B.",
- "dflt": "B",
- "editType": "plot",
- "valType": "enumerated",
- "values": [
- "none",
- "e",
- "E",
- "power",
- "SI",
- "B"
- ]
- },
"gridcolor": {
"description": "Sets the color of the grid lines.",
"dflt": "#eee",
@@ -7394,36 +7404,39 @@
"min": 0,
"valType": "number"
},
- "min": {
- "description": "The minimum value visible on this axis. The maximum is determined by the sum minus the minimum values of the other two axes. The full view corresponds to all the minima set to zero.",
- "dflt": 0,
+ "role": "object",
+ "showgrid": {
+ "description": "Determines whether or not grid lines are drawn. If *true*, the grid lines are drawn at every tick mark.",
+ "dflt": true,
"editType": "plot",
- "min": 0,
- "valType": "number"
+ "valType": "boolean"
},
- "minexponent": {
- "description": "Hide SI prefix for 10^n if |n| is below this number. This only has an effect when `tickformat` is *SI* or *B*.",
- "dflt": 3,
+ "showline": {
+ "description": "Determines whether or not a line bounding this axis is drawn.",
+ "dflt": true,
"editType": "plot",
- "min": 0,
- "valType": "number"
+ "valType": "boolean"
},
- "nticks": {
- "description": "Specifies the maximum number of ticks for the particular axis. The actual number of ticks will be chosen automatically to be less than or equal to `nticks`. Has an effect only if `tickmode` is set to *auto*.",
- "dflt": 6,
+ "showticklabels": {
+ "description": "Determines whether or not the tick labels are drawn.",
+ "dflt": true,
"editType": "plot",
- "min": 1,
- "valType": "integer"
+ "valType": "boolean"
},
- "role": "object",
- "separatethousands": {
- "description": "If \"true\", even 4-digit integers are separated",
- "dflt": false,
+ "showtickprefix": {
+ "description": "If *all*, all tick labels are displayed with a prefix. If *first*, only the first tick is displayed with a prefix. If *last*, only the last tick is displayed with a suffix. If *none*, tick prefixes are hidden.",
+ "dflt": "all",
"editType": "plot",
- "valType": "boolean"
+ "valType": "enumerated",
+ "values": [
+ "all",
+ "first",
+ "last",
+ "none"
+ ]
},
- "showexponent": {
- "description": "If *all*, all exponents are shown besides their significands. If *first*, only the exponent of the first tick is shown. If *last*, only the exponent of the last tick is shown. If *none*, no exponents appear.",
+ "showticksuffix": {
+ "description": "Same as `showtickprefix` but for tick suffixes.",
"dflt": "all",
"editType": "plot",
"valType": "enumerated",
@@ -7434,6 +7447,143 @@
"none"
]
},
+ "tickcolor": {
+ "description": "Sets the tick color.",
+ "dflt": "#444",
+ "editType": "plot",
+ "valType": "color"
+ },
+ "tickfont": {
+ "color": {
+ "editType": "plot",
+ "valType": "color"
+ },
+ "description": "Sets the tick font.",
+ "editType": "plot",
+ "family": {
+ "description": "HTML font family - the typeface that will be applied by the web browser. The web browser will only be able to apply a font if it is available on the system which it operates. Provide multiple font families, separated by commas, to indicate the preference in which to apply fonts if they aren't available on the system. The Chart Studio Cloud (at https://chart-studio.plotly.com or on-premise) generates images on a server, where only a select number of fonts are installed and supported. These include *Arial*, *Balto*, *Courier New*, *Droid Sans*,, *Droid Serif*, *Droid Sans Mono*, *Gravitas One*, *Old Standard TT*, *Open Sans*, *Overpass*, *PT Sans Narrow*, *Raleway*, *Times New Roman*.",
+ "editType": "plot",
+ "noBlank": true,
+ "strict": true,
+ "valType": "string"
+ },
+ "role": "object",
+ "size": {
+ "editType": "plot",
+ "min": 1,
+ "valType": "number"
+ }
+ },
+ "tickformat": {
+ "description": "Sets the tick label formatting rule using d3 formatting mini-languages which are very similar to those in Python. For numbers, see: https://github.com/d3/d3-format/tree/v1.4.5#d3-format. And for dates see: https://github.com/d3/d3-time-format/tree/v2.2.3#locale_format. We add two items to d3's date formatter: *%h* for half of the year as a decimal number as well as *%{n}f* for fractional seconds with n digits. For example, *2016-10-13 09:15:23.456* with tickformat *%H~%M~%S.%2f* would display *09~15~23.46*",
+ "dflt": "",
+ "editType": "plot",
+ "valType": "string"
+ },
+ "ticklen": {
+ "description": "Sets the tick length (in px).",
+ "dflt": 5,
+ "editType": "plot",
+ "min": 0,
+ "valType": "number"
+ },
+ "tickprefix": {
+ "description": "Sets a tick label prefix.",
+ "dflt": "",
+ "editType": "plot",
+ "valType": "string"
+ },
+ "ticks": {
+ "description": "Determines whether ticks are drawn or not. If **, this axis' ticks are not drawn. If *outside* (*inside*), this axis' are drawn outside (inside) the axis lines.",
+ "editType": "ticks",
+ "valType": "enumerated",
+ "values": [
+ "outside",
+ "inside",
+ ""
+ ]
+ },
+ "ticksuffix": {
+ "description": "Sets a tick label suffix.",
+ "dflt": "",
+ "editType": "plot",
+ "valType": "string"
+ },
+ "tickvals": {
+ "description": "Sets the values at which ticks on this axis appear. Defaults to `realaxis.tickvals` plus the same as negatives and zero.",
+ "editType": "plot",
+ "valType": "data_array"
+ },
+ "tickvalssrc": {
+ "description": "Sets the source reference on Chart Studio Cloud for `tickvals`.",
+ "editType": "none",
+ "valType": "string"
+ },
+ "tickwidth": {
+ "description": "Sets the tick width (in px).",
+ "dflt": 2,
+ "editType": "plot",
+ "min": 0,
+ "valType": "number"
+ },
+ "visible": {
+ "description": "A single toggle to hide the axis while preserving interaction like dragging. Default is true when a cheater plot is present on the axis, otherwise false",
+ "dflt": true,
+ "editType": "plot",
+ "valType": "boolean"
+ }
+ },
+ "realaxis": {
+ "color": {
+ "description": "Sets default for all colors associated with this axis all at once: line, font, tick, and grid colors. Grid color is lightened by blending this with the plot background Individual pieces can override this.",
+ "dflt": "#444",
+ "editType": "plot",
+ "valType": "color"
+ },
+ "editType": "plot",
+ "gridcolor": {
+ "description": "Sets the color of the grid lines.",
+ "dflt": "#eee",
+ "editType": "plot",
+ "valType": "color"
+ },
+ "gridwidth": {
+ "description": "Sets the width (in px) of the grid lines.",
+ "dflt": 1,
+ "editType": "plot",
+ "min": 0,
+ "valType": "number"
+ },
+ "hoverformat": {
+ "description": "Sets the hover text formatting rule using d3 formatting mini-languages which are very similar to those in Python. For numbers, see: https://github.com/d3/d3-format/tree/v1.4.5#d3-format. And for dates see: https://github.com/d3/d3-time-format/tree/v2.2.3#locale_format. We add two items to d3's date formatter: *%h* for half of the year as a decimal number as well as *%{n}f* for fractional seconds with n digits. For example, *2016-10-13 09:15:23.456* with tickformat *%H~%M~%S.%2f* would display *09~15~23.46*",
+ "dflt": "",
+ "editType": "plot",
+ "valType": "string"
+ },
+ "layer": {
+ "description": "Sets the layer on which this axis is displayed. If *above traces*, this axis is displayed above all the subplot's traces If *below traces*, this axis is displayed below all the subplot's traces, but above the grid lines. Useful when used together with scatter-like traces with `cliponaxis` set to *false* to show markers and/or text nodes above this axis.",
+ "dflt": "above traces",
+ "editType": "plot",
+ "valType": "enumerated",
+ "values": [
+ "above traces",
+ "below traces"
+ ]
+ },
+ "linecolor": {
+ "description": "Sets the axis line color.",
+ "dflt": "#444",
+ "editType": "plot",
+ "valType": "color"
+ },
+ "linewidth": {
+ "description": "Sets the width (in px) of the axis line.",
+ "dflt": 1,
+ "editType": "plot",
+ "min": 0,
+ "valType": "number"
+ },
+ "role": "object",
"showgrid": {
"description": "Determines whether or not grid lines are drawn. If *true*, the grid lines are drawn at every tick mark.",
"dflt": true,
@@ -7476,18 +7626,20 @@
"none"
]
},
- "tick0": {
- "description": "Sets the placement of the first tick on this axis. Use with `dtick`. If the axis `type` is *log*, then you must take the log of your starting tick (e.g. to set the starting tick to 100, set the `tick0` to 2) except when `dtick`=*L* (see `dtick` for more info). If the axis `type` is *date*, it should be a date string, like date data. If the axis `type` is *category*, it should be a number, using the scale where each category is assigned a serial number from zero in the order it appears.",
+ "side": {
+ "description": "Determines on which side of real axis line the tick and tick labels appear.",
+ "dflt": "top",
"editType": "plot",
- "impliedEdits": {
- "tickmode": "linear"
- },
- "valType": "any"
+ "valType": "enumerated",
+ "values": [
+ "top",
+ "bottom"
+ ]
},
"tickangle": {
"description": "Sets the angle of the tick labels with respect to the horizontal. For example, a `tickangle` of -90 draws the tick labels vertically.",
- "dflt": "auto",
- "editType": "plot",
+ "dflt": 90,
+ "editType": "ticks",
"valType": "angle"
},
"tickcolor": {
@@ -7523,52 +7675,6 @@
"editType": "plot",
"valType": "string"
},
- "tickformatstops": {
- "items": {
- "tickformatstop": {
- "dtickrange": {
- "description": "range [*min*, *max*], where *min*, *max* - dtick values which describe some zoom level, it is possible to omit *min* or *max* value by passing *null*",
- "editType": "plot",
- "items": [
- {
- "editType": "plot",
- "valType": "any"
- },
- {
- "editType": "plot",
- "valType": "any"
- }
- ],
- "valType": "info_array"
- },
- "editType": "plot",
- "enabled": {
- "description": "Determines whether or not this stop is used. If `false`, this stop is ignored even within its `dtickrange`.",
- "dflt": true,
- "editType": "plot",
- "valType": "boolean"
- },
- "name": {
- "description": "When used in a template, named items are created in the output figure in addition to any items the figure already has in this array. You can modify these items in the output figure by making your own item with `templateitemname` matching this `name` alongside your modifications (including `visible: false` or `enabled: false` to hide it). Has no effect outside of a template.",
- "editType": "plot",
- "valType": "string"
- },
- "role": "object",
- "templateitemname": {
- "description": "Used to refer to a named item in this array in the template. Named items from the template will be created even without a matching item in the input figure, but you can modify one by making an item with `templateitemname` matching its `name`, alongside your modifications (including `visible: false` or `enabled: false` to hide it). If there is no template or no matching item, this item will be hidden unless you explicitly show it with `visible: true`.",
- "editType": "plot",
- "valType": "string"
- },
- "value": {
- "description": "string - dtickformat for described zoom level, the same as *tickformat*",
- "dflt": "",
- "editType": "plot",
- "valType": "string"
- }
- }
- },
- "role": "object"
- },
"ticklen": {
"description": "Sets the tick length (in px).",
"dflt": 5,
@@ -7576,17 +7682,6 @@
"min": 0,
"valType": "number"
},
- "tickmode": {
- "description": "Sets the tick mode for this axis. If *auto*, the number of ticks is set via `nticks`. If *linear*, the placement of the ticks is determined by a starting position `tick0` and a tick step `dtick` (*linear* is the default value if `tick0` and `dtick` are provided). If *array*, the placement of the ticks is set via `tickvals` and the tick text is `ticktext`. (*array* is the default value if `tickvals` is provided).",
- "editType": "plot",
- "impliedEdits": {},
- "valType": "enumerated",
- "values": [
- "auto",
- "linear",
- "array"
- ]
- },
"tickprefix": {
"description": "Sets a tick label prefix.",
"dflt": "",
@@ -7594,12 +7689,12 @@
"valType": "string"
},
"ticks": {
- "description": "Determines whether ticks are drawn or not. If **, this axis' ticks are not drawn. If *outside* (*inside*), this axis' are drawn outside (inside) the axis lines.",
- "editType": "plot",
+ "description": "Determines whether ticks are drawn or not. If **, this axis' ticks are not drawn. If *top* (*bottom*), this axis' are drawn above (below) the axis line.",
+ "editType": "ticks",
"valType": "enumerated",
"values": [
- "outside",
- "inside",
+ "top",
+ "bottom",
""
]
},
@@ -7609,18 +7704,15 @@
"editType": "plot",
"valType": "string"
},
- "ticktext": {
- "description": "Sets the text displayed at the ticks position via `tickvals`. Only has an effect if `tickmode` is set to *array*. Used with `tickvals`.",
- "editType": "plot",
- "valType": "data_array"
- },
- "ticktextsrc": {
- "description": "Sets the source reference on Chart Studio Cloud for `ticktext`.",
- "editType": "none",
- "valType": "string"
- },
"tickvals": {
- "description": "Sets the values at which ticks on this axis appear. Only has an effect if `tickmode` is set to *array*. Used with `ticktext`.",
+ "description": "Sets the values at which ticks on this axis appear.",
+ "dflt": [
+ 0.2,
+ 0.5,
+ 1,
+ 2,
+ 5
+ ],
"editType": "plot",
"valType": "data_array"
},
@@ -7631,48 +7723,35 @@
},
"tickwidth": {
"description": "Sets the tick width (in px).",
- "dflt": 1,
+ "dflt": 2,
"editType": "plot",
"min": 0,
"valType": "number"
},
- "title": {
+ "visible": {
+ "description": "A single toggle to hide the axis while preserving interaction like dragging. Default is true when a cheater plot is present on the axis, otherwise false",
+ "dflt": true,
"editType": "plot",
- "font": {
- "color": {
- "editType": "plot",
- "valType": "color"
- },
- "description": "Sets this axis' title font. Note that the title's font used to be customized by the now deprecated `titlefont` attribute.",
- "editType": "plot",
- "family": {
- "description": "HTML font family - the typeface that will be applied by the web browser. The web browser will only be able to apply a font if it is available on the system which it operates. Provide multiple font families, separated by commas, to indicate the preference in which to apply fonts if they aren't available on the system. The Chart Studio Cloud (at https://chart-studio.plotly.com or on-premise) generates images on a server, where only a select number of fonts are installed and supported. These include *Arial*, *Balto*, *Courier New*, *Droid Sans*,, *Droid Serif*, *Droid Sans Mono*, *Gravitas One*, *Old Standard TT*, *Open Sans*, *Overpass*, *PT Sans Narrow*, *Raleway*, *Times New Roman*.",
- "editType": "plot",
- "noBlank": true,
- "strict": true,
- "valType": "string"
- },
- "role": "object",
- "size": {
- "editType": "plot",
- "min": 1,
- "valType": "number"
- }
- },
- "role": "object",
- "text": {
- "description": "Sets the title of this axis. Note that before the existence of `title.text`, the title's contents used to be defined as the `title` attribute itself. This behavior has been deprecated.",
- "editType": "plot",
- "valType": "string"
- }
- },
- "uirevision": {
- "description": "Controls persistence of user-driven changes in axis `min`, and `title` if in `editable: true` configuration. Defaults to `ternary.uirevision`.",
- "editType": "none",
- "valType": "any"
+ "valType": "boolean"
}
},
- "baxis": {
+ "role": "object"
+ },
+ "spikedistance": {
+ "description": "Sets the default distance (in pixels) to look for data to draw spikelines to (-1 means no cutoff, 0 means no looking for data). As with hoverdistance, distance does not apply to area-like objects. In addition, some objects can be hovered on but will not generate spikelines, such as scatter fills.",
+ "dflt": -1,
+ "editType": "none",
+ "min": -1,
+ "valType": "integer"
+ },
+ "template": {
+ "description": "Default attributes to be applied to the plot. Templates can be created from existing plots using `Plotly.makeTemplate`, or created manually. They should be objects with format: `{layout: layoutTemplate, data: {[type]: [traceTemplate, ...]}, ...}` `layoutTemplate` and `traceTemplate` are objects matching the attribute structure of `layout` and a data trace. Trace templates are applied cyclically to traces of each type. Container arrays (eg `annotations`) have special handling: An object ending in `defaults` (eg `annotationdefaults`) is applied to each array item. But if an item has a `templateitemname` key we look in the template array for an item with matching `name` and apply that instead. If no matching `name` is found we mark the item invisible. Any named template item not referenced is appended to the end of the array, so you can use this for a watermark annotation or a logo image, for example. To omit one of these items on the plot, make an item with matching `templateitemname` and `visible: false`.",
+ "editType": "calc",
+ "valType": "any"
+ },
+ "ternary": {
+ "_isSubplotObj": true,
+ "aaxis": {
"_deprecated": {
"title": {
"description": "Value of `title` is no longer a simple *string* but a set of sub-attributes. To set the axis' title, please use `title.text` now.",
@@ -8049,13 +8128,390 @@
"valType": "any"
}
},
- "bgcolor": {
- "description": "Set the background color of the subplot",
- "dflt": "#fff",
- "editType": "plot",
- "valType": "color"
- },
- "caxis": {
+ "baxis": {
+ "_deprecated": {
+ "title": {
+ "description": "Value of `title` is no longer a simple *string* but a set of sub-attributes. To set the axis' title, please use `title.text` now.",
+ "editType": "plot",
+ "valType": "string"
+ },
+ "titlefont": {
+ "color": {
+ "editType": "plot",
+ "valType": "color"
+ },
+ "description": "Former `titlefont` is now the sub-attribute `font` of `title`. To customize title font properties, please use `title.font` now.",
+ "editType": "plot",
+ "family": {
+ "description": "HTML font family - the typeface that will be applied by the web browser. The web browser will only be able to apply a font if it is available on the system which it operates. Provide multiple font families, separated by commas, to indicate the preference in which to apply fonts if they aren't available on the system. The Chart Studio Cloud (at https://chart-studio.plotly.com or on-premise) generates images on a server, where only a select number of fonts are installed and supported. These include *Arial*, *Balto*, *Courier New*, *Droid Sans*,, *Droid Serif*, *Droid Sans Mono*, *Gravitas One*, *Old Standard TT*, *Open Sans*, *Overpass*, *PT Sans Narrow*, *Raleway*, *Times New Roman*.",
+ "editType": "plot",
+ "noBlank": true,
+ "strict": true,
+ "valType": "string"
+ },
+ "size": {
+ "editType": "plot",
+ "min": 1,
+ "valType": "number"
+ }
+ }
+ },
+ "color": {
+ "description": "Sets default for all colors associated with this axis all at once: line, font, tick, and grid colors. Grid color is lightened by blending this with the plot background Individual pieces can override this.",
+ "dflt": "#444",
+ "editType": "plot",
+ "valType": "color"
+ },
+ "dtick": {
+ "description": "Sets the step in-between ticks on this axis. Use with `tick0`. Must be a positive number, or special strings available to *log* and *date* axes. If the axis `type` is *log*, then ticks are set every 10^(n*dtick) where n is the tick number. For example, to set a tick mark at 1, 10, 100, 1000, ... set dtick to 1. To set tick marks at 1, 100, 10000, ... set dtick to 2. To set tick marks at 1, 5, 25, 125, 625, 3125, ... set dtick to log_10(5), or 0.69897000433. *log* has several special values; *L*, where `f` is a positive number, gives ticks linearly spaced in value (but not position). For example `tick0` = 0.1, `dtick` = *L0.5* will put ticks at 0.1, 0.6, 1.1, 1.6 etc. To show powers of 10 plus small digits between, use *D1* (all digits) or *D2* (only 2 and 5). `tick0` is ignored for *D1* and *D2*. If the axis `type` is *date*, then you must convert the time to milliseconds. For example, to set the interval between ticks to one day, set `dtick` to 86400000.0. *date* also has special values *M* gives ticks spaced by a number of months. `n` must be a positive integer. To set ticks on the 15th of every third month, set `tick0` to *2000-01-15* and `dtick` to *M3*. To set ticks every 4 years, set `dtick` to *M48*",
+ "editType": "plot",
+ "impliedEdits": {
+ "tickmode": "linear"
+ },
+ "valType": "any"
+ },
+ "editType": "plot",
+ "exponentformat": {
+ "description": "Determines a formatting rule for the tick exponents. For example, consider the number 1,000,000,000. If *none*, it appears as 1,000,000,000. If *e*, 1e+9. If *E*, 1E+9. If *power*, 1x10^9 (with 9 in a super script). If *SI*, 1G. If *B*, 1B.",
+ "dflt": "B",
+ "editType": "plot",
+ "valType": "enumerated",
+ "values": [
+ "none",
+ "e",
+ "E",
+ "power",
+ "SI",
+ "B"
+ ]
+ },
+ "gridcolor": {
+ "description": "Sets the color of the grid lines.",
+ "dflt": "#eee",
+ "editType": "plot",
+ "valType": "color"
+ },
+ "gridwidth": {
+ "description": "Sets the width (in px) of the grid lines.",
+ "dflt": 1,
+ "editType": "plot",
+ "min": 0,
+ "valType": "number"
+ },
+ "hoverformat": {
+ "description": "Sets the hover text formatting rule using d3 formatting mini-languages which are very similar to those in Python. For numbers, see: https://github.com/d3/d3-format/tree/v1.4.5#d3-format. And for dates see: https://github.com/d3/d3-time-format/tree/v2.2.3#locale_format. We add two items to d3's date formatter: *%h* for half of the year as a decimal number as well as *%{n}f* for fractional seconds with n digits. For example, *2016-10-13 09:15:23.456* with tickformat *%H~%M~%S.%2f* would display *09~15~23.46*",
+ "dflt": "",
+ "editType": "plot",
+ "valType": "string"
+ },
+ "layer": {
+ "description": "Sets the layer on which this axis is displayed. If *above traces*, this axis is displayed above all the subplot's traces If *below traces*, this axis is displayed below all the subplot's traces, but above the grid lines. Useful when used together with scatter-like traces with `cliponaxis` set to *false* to show markers and/or text nodes above this axis.",
+ "dflt": "above traces",
+ "editType": "plot",
+ "valType": "enumerated",
+ "values": [
+ "above traces",
+ "below traces"
+ ]
+ },
+ "linecolor": {
+ "description": "Sets the axis line color.",
+ "dflt": "#444",
+ "editType": "plot",
+ "valType": "color"
+ },
+ "linewidth": {
+ "description": "Sets the width (in px) of the axis line.",
+ "dflt": 1,
+ "editType": "plot",
+ "min": 0,
+ "valType": "number"
+ },
+ "min": {
+ "description": "The minimum value visible on this axis. The maximum is determined by the sum minus the minimum values of the other two axes. The full view corresponds to all the minima set to zero.",
+ "dflt": 0,
+ "editType": "plot",
+ "min": 0,
+ "valType": "number"
+ },
+ "minexponent": {
+ "description": "Hide SI prefix for 10^n if |n| is below this number. This only has an effect when `tickformat` is *SI* or *B*.",
+ "dflt": 3,
+ "editType": "plot",
+ "min": 0,
+ "valType": "number"
+ },
+ "nticks": {
+ "description": "Specifies the maximum number of ticks for the particular axis. The actual number of ticks will be chosen automatically to be less than or equal to `nticks`. Has an effect only if `tickmode` is set to *auto*.",
+ "dflt": 6,
+ "editType": "plot",
+ "min": 1,
+ "valType": "integer"
+ },
+ "role": "object",
+ "separatethousands": {
+ "description": "If \"true\", even 4-digit integers are separated",
+ "dflt": false,
+ "editType": "plot",
+ "valType": "boolean"
+ },
+ "showexponent": {
+ "description": "If *all*, all exponents are shown besides their significands. If *first*, only the exponent of the first tick is shown. If *last*, only the exponent of the last tick is shown. If *none*, no exponents appear.",
+ "dflt": "all",
+ "editType": "plot",
+ "valType": "enumerated",
+ "values": [
+ "all",
+ "first",
+ "last",
+ "none"
+ ]
+ },
+ "showgrid": {
+ "description": "Determines whether or not grid lines are drawn. If *true*, the grid lines are drawn at every tick mark.",
+ "dflt": true,
+ "editType": "plot",
+ "valType": "boolean"
+ },
+ "showline": {
+ "description": "Determines whether or not a line bounding this axis is drawn.",
+ "dflt": true,
+ "editType": "plot",
+ "valType": "boolean"
+ },
+ "showticklabels": {
+ "description": "Determines whether or not the tick labels are drawn.",
+ "dflt": true,
+ "editType": "plot",
+ "valType": "boolean"
+ },
+ "showtickprefix": {
+ "description": "If *all*, all tick labels are displayed with a prefix. If *first*, only the first tick is displayed with a prefix. If *last*, only the last tick is displayed with a suffix. If *none*, tick prefixes are hidden.",
+ "dflt": "all",
+ "editType": "plot",
+ "valType": "enumerated",
+ "values": [
+ "all",
+ "first",
+ "last",
+ "none"
+ ]
+ },
+ "showticksuffix": {
+ "description": "Same as `showtickprefix` but for tick suffixes.",
+ "dflt": "all",
+ "editType": "plot",
+ "valType": "enumerated",
+ "values": [
+ "all",
+ "first",
+ "last",
+ "none"
+ ]
+ },
+ "tick0": {
+ "description": "Sets the placement of the first tick on this axis. Use with `dtick`. If the axis `type` is *log*, then you must take the log of your starting tick (e.g. to set the starting tick to 100, set the `tick0` to 2) except when `dtick`=*L* (see `dtick` for more info). If the axis `type` is *date*, it should be a date string, like date data. If the axis `type` is *category*, it should be a number, using the scale where each category is assigned a serial number from zero in the order it appears.",
+ "editType": "plot",
+ "impliedEdits": {
+ "tickmode": "linear"
+ },
+ "valType": "any"
+ },
+ "tickangle": {
+ "description": "Sets the angle of the tick labels with respect to the horizontal. For example, a `tickangle` of -90 draws the tick labels vertically.",
+ "dflt": "auto",
+ "editType": "plot",
+ "valType": "angle"
+ },
+ "tickcolor": {
+ "description": "Sets the tick color.",
+ "dflt": "#444",
+ "editType": "plot",
+ "valType": "color"
+ },
+ "tickfont": {
+ "color": {
+ "editType": "plot",
+ "valType": "color"
+ },
+ "description": "Sets the tick font.",
+ "editType": "plot",
+ "family": {
+ "description": "HTML font family - the typeface that will be applied by the web browser. The web browser will only be able to apply a font if it is available on the system which it operates. Provide multiple font families, separated by commas, to indicate the preference in which to apply fonts if they aren't available on the system. The Chart Studio Cloud (at https://chart-studio.plotly.com or on-premise) generates images on a server, where only a select number of fonts are installed and supported. These include *Arial*, *Balto*, *Courier New*, *Droid Sans*,, *Droid Serif*, *Droid Sans Mono*, *Gravitas One*, *Old Standard TT*, *Open Sans*, *Overpass*, *PT Sans Narrow*, *Raleway*, *Times New Roman*.",
+ "editType": "plot",
+ "noBlank": true,
+ "strict": true,
+ "valType": "string"
+ },
+ "role": "object",
+ "size": {
+ "editType": "plot",
+ "min": 1,
+ "valType": "number"
+ }
+ },
+ "tickformat": {
+ "description": "Sets the tick label formatting rule using d3 formatting mini-languages which are very similar to those in Python. For numbers, see: https://github.com/d3/d3-format/tree/v1.4.5#d3-format. And for dates see: https://github.com/d3/d3-time-format/tree/v2.2.3#locale_format. We add two items to d3's date formatter: *%h* for half of the year as a decimal number as well as *%{n}f* for fractional seconds with n digits. For example, *2016-10-13 09:15:23.456* with tickformat *%H~%M~%S.%2f* would display *09~15~23.46*",
+ "dflt": "",
+ "editType": "plot",
+ "valType": "string"
+ },
+ "tickformatstops": {
+ "items": {
+ "tickformatstop": {
+ "dtickrange": {
+ "description": "range [*min*, *max*], where *min*, *max* - dtick values which describe some zoom level, it is possible to omit *min* or *max* value by passing *null*",
+ "editType": "plot",
+ "items": [
+ {
+ "editType": "plot",
+ "valType": "any"
+ },
+ {
+ "editType": "plot",
+ "valType": "any"
+ }
+ ],
+ "valType": "info_array"
+ },
+ "editType": "plot",
+ "enabled": {
+ "description": "Determines whether or not this stop is used. If `false`, this stop is ignored even within its `dtickrange`.",
+ "dflt": true,
+ "editType": "plot",
+ "valType": "boolean"
+ },
+ "name": {
+ "description": "When used in a template, named items are created in the output figure in addition to any items the figure already has in this array. You can modify these items in the output figure by making your own item with `templateitemname` matching this `name` alongside your modifications (including `visible: false` or `enabled: false` to hide it). Has no effect outside of a template.",
+ "editType": "plot",
+ "valType": "string"
+ },
+ "role": "object",
+ "templateitemname": {
+ "description": "Used to refer to a named item in this array in the template. Named items from the template will be created even without a matching item in the input figure, but you can modify one by making an item with `templateitemname` matching its `name`, alongside your modifications (including `visible: false` or `enabled: false` to hide it). If there is no template or no matching item, this item will be hidden unless you explicitly show it with `visible: true`.",
+ "editType": "plot",
+ "valType": "string"
+ },
+ "value": {
+ "description": "string - dtickformat for described zoom level, the same as *tickformat*",
+ "dflt": "",
+ "editType": "plot",
+ "valType": "string"
+ }
+ }
+ },
+ "role": "object"
+ },
+ "ticklen": {
+ "description": "Sets the tick length (in px).",
+ "dflt": 5,
+ "editType": "plot",
+ "min": 0,
+ "valType": "number"
+ },
+ "tickmode": {
+ "description": "Sets the tick mode for this axis. If *auto*, the number of ticks is set via `nticks`. If *linear*, the placement of the ticks is determined by a starting position `tick0` and a tick step `dtick` (*linear* is the default value if `tick0` and `dtick` are provided). If *array*, the placement of the ticks is set via `tickvals` and the tick text is `ticktext`. (*array* is the default value if `tickvals` is provided).",
+ "editType": "plot",
+ "impliedEdits": {},
+ "valType": "enumerated",
+ "values": [
+ "auto",
+ "linear",
+ "array"
+ ]
+ },
+ "tickprefix": {
+ "description": "Sets a tick label prefix.",
+ "dflt": "",
+ "editType": "plot",
+ "valType": "string"
+ },
+ "ticks": {
+ "description": "Determines whether ticks are drawn or not. If **, this axis' ticks are not drawn. If *outside* (*inside*), this axis' are drawn outside (inside) the axis lines.",
+ "editType": "plot",
+ "valType": "enumerated",
+ "values": [
+ "outside",
+ "inside",
+ ""
+ ]
+ },
+ "ticksuffix": {
+ "description": "Sets a tick label suffix.",
+ "dflt": "",
+ "editType": "plot",
+ "valType": "string"
+ },
+ "ticktext": {
+ "description": "Sets the text displayed at the ticks position via `tickvals`. Only has an effect if `tickmode` is set to *array*. Used with `tickvals`.",
+ "editType": "plot",
+ "valType": "data_array"
+ },
+ "ticktextsrc": {
+ "description": "Sets the source reference on Chart Studio Cloud for `ticktext`.",
+ "editType": "none",
+ "valType": "string"
+ },
+ "tickvals": {
+ "description": "Sets the values at which ticks on this axis appear. Only has an effect if `tickmode` is set to *array*. Used with `ticktext`.",
+ "editType": "plot",
+ "valType": "data_array"
+ },
+ "tickvalssrc": {
+ "description": "Sets the source reference on Chart Studio Cloud for `tickvals`.",
+ "editType": "none",
+ "valType": "string"
+ },
+ "tickwidth": {
+ "description": "Sets the tick width (in px).",
+ "dflt": 1,
+ "editType": "plot",
+ "min": 0,
+ "valType": "number"
+ },
+ "title": {
+ "editType": "plot",
+ "font": {
+ "color": {
+ "editType": "plot",
+ "valType": "color"
+ },
+ "description": "Sets this axis' title font. Note that the title's font used to be customized by the now deprecated `titlefont` attribute.",
+ "editType": "plot",
+ "family": {
+ "description": "HTML font family - the typeface that will be applied by the web browser. The web browser will only be able to apply a font if it is available on the system which it operates. Provide multiple font families, separated by commas, to indicate the preference in which to apply fonts if they aren't available on the system. The Chart Studio Cloud (at https://chart-studio.plotly.com or on-premise) generates images on a server, where only a select number of fonts are installed and supported. These include *Arial*, *Balto*, *Courier New*, *Droid Sans*,, *Droid Serif*, *Droid Sans Mono*, *Gravitas One*, *Old Standard TT*, *Open Sans*, *Overpass*, *PT Sans Narrow*, *Raleway*, *Times New Roman*.",
+ "editType": "plot",
+ "noBlank": true,
+ "strict": true,
+ "valType": "string"
+ },
+ "role": "object",
+ "size": {
+ "editType": "plot",
+ "min": 1,
+ "valType": "number"
+ }
+ },
+ "role": "object",
+ "text": {
+ "description": "Sets the title of this axis. Note that before the existence of `title.text`, the title's contents used to be defined as the `title` attribute itself. This behavior has been deprecated.",
+ "editType": "plot",
+ "valType": "string"
+ }
+ },
+ "uirevision": {
+ "description": "Controls persistence of user-driven changes in axis `min`, and `title` if in `editable: true` configuration. Defaults to `ternary.uirevision`.",
+ "editType": "none",
+ "valType": "any"
+ }
+ },
+ "bgcolor": {
+ "description": "Set the background color of the subplot",
+ "dflt": "#fff",
+ "editType": "plot",
+ "valType": "color"
+ },
+ "caxis": {
"_deprecated": {
"title": {
"description": "Value of `title` is no longer a simple *string* but a set of sub-attributes. To set the axis' title, please use `title.text` now.",
@@ -52395,47 +52851,1869 @@
"line": {
"color": {
"description": "Sets the line color.",
- "editType": "style",
+ "editType": "style",
+ "valType": "color"
+ },
+ "dash": {
+ "description": "Sets the dash style of lines. Set to a dash type string (*solid*, *dot*, *dash*, *longdash*, *dashdot*, or *longdashdot*) or a dash length list in px (eg *5px,10px,2px,2px*).",
+ "dflt": "solid",
+ "editType": "style",
+ "valType": "string",
+ "values": [
+ "solid",
+ "dot",
+ "dash",
+ "longdash",
+ "dashdot",
+ "longdashdot"
+ ]
+ },
+ "editType": "calc",
+ "role": "object",
+ "shape": {
+ "description": "Determines the line shape. With *spline* the lines are drawn using spline interpolation. The other available values correspond to step-wise line shapes.",
+ "dflt": "linear",
+ "editType": "plot",
+ "valType": "enumerated",
+ "values": [
+ "linear",
+ "spline"
+ ]
+ },
+ "smoothing": {
+ "description": "Has an effect only if `shape` is set to *spline* Sets the amount of smoothing. *0* corresponds to no smoothing (equivalent to a *linear* shape).",
+ "dflt": 1,
+ "editType": "plot",
+ "max": 1.3,
+ "min": 0,
+ "valType": "number"
+ },
+ "width": {
+ "description": "Sets the line width (in px).",
+ "dflt": 2,
+ "editType": "style",
+ "min": 0,
+ "valType": "number"
+ }
+ },
+ "marker": {
+ "autocolorscale": {
+ "description": "Determines whether the colorscale is a default palette (`autocolorscale: true`) or the palette determined by `marker.colorscale`. Has an effect only if in `marker.color`is set to a numerical array. In case `colorscale` is unspecified or `autocolorscale` is true, the default palette will be chosen according to whether numbers in the `color` array are all positive, all negative or mixed.",
+ "dflt": true,
+ "editType": "calc",
+ "impliedEdits": {},
+ "valType": "boolean"
+ },
+ "cauto": {
+ "description": "Determines whether or not the color domain is computed with respect to the input data (here in `marker.color`) or the bounds set in `marker.cmin` and `marker.cmax` Has an effect only if in `marker.color`is set to a numerical array. Defaults to `false` when `marker.cmin` and `marker.cmax` are set by the user.",
+ "dflt": true,
+ "editType": "calc",
+ "impliedEdits": {},
+ "valType": "boolean"
+ },
+ "cmax": {
+ "description": "Sets the upper bound of the color domain. Has an effect only if in `marker.color`is set to a numerical array. Value should have the same units as in `marker.color` and if set, `marker.cmin` must be set as well.",
+ "dflt": null,
+ "editType": "plot",
+ "impliedEdits": {
+ "cauto": false
+ },
+ "valType": "number"
+ },
+ "cmid": {
+ "description": "Sets the mid-point of the color domain by scaling `marker.cmin` and/or `marker.cmax` to be equidistant to this point. Has an effect only if in `marker.color`is set to a numerical array. Value should have the same units as in `marker.color`. Has no effect when `marker.cauto` is `false`.",
+ "dflt": null,
+ "editType": "calc",
+ "impliedEdits": {},
+ "valType": "number"
+ },
+ "cmin": {
+ "description": "Sets the lower bound of the color domain. Has an effect only if in `marker.color`is set to a numerical array. Value should have the same units as in `marker.color` and if set, `marker.cmax` must be set as well.",
+ "dflt": null,
+ "editType": "plot",
+ "impliedEdits": {
+ "cauto": false
+ },
+ "valType": "number"
+ },
+ "color": {
+ "arrayOk": true,
+ "description": "Sets themarkercolor. It accepts either a specific color or an array of numbers that are mapped to the colorscale relative to the max and min values of the array or relative to `marker.cmin` and `marker.cmax` if set.",
+ "editType": "style",
+ "valType": "color"
+ },
+ "coloraxis": {
+ "description": "Sets a reference to a shared color axis. References to these shared color axes are *coloraxis*, *coloraxis2*, *coloraxis3*, etc. Settings for these shared color axes are set in the layout, under `layout.coloraxis`, `layout.coloraxis2`, etc. Note that multiple color scales can be linked to the same color axis.",
+ "dflt": null,
+ "editType": "calc",
+ "regex": "/^coloraxis([2-9]|[1-9][0-9]+)?$/",
+ "valType": "subplotid"
+ },
+ "colorbar": {
+ "_deprecated": {
+ "title": {
+ "description": "Deprecated in favor of color bar's `title.text`. Note that value of color bar's `title` is no longer a simple *string* but a set of sub-attributes.",
+ "editType": "colorbars",
+ "valType": "string"
+ },
+ "titlefont": {
+ "color": {
+ "editType": "colorbars",
+ "valType": "color"
+ },
+ "description": "Deprecated in favor of color bar's `title.font`.",
+ "editType": "colorbars",
+ "family": {
+ "description": "HTML font family - the typeface that will be applied by the web browser. The web browser will only be able to apply a font if it is available on the system which it operates. Provide multiple font families, separated by commas, to indicate the preference in which to apply fonts if they aren't available on the system. The Chart Studio Cloud (at https://chart-studio.plotly.com or on-premise) generates images on a server, where only a select number of fonts are installed and supported. These include *Arial*, *Balto*, *Courier New*, *Droid Sans*,, *Droid Serif*, *Droid Sans Mono*, *Gravitas One*, *Old Standard TT*, *Open Sans*, *Overpass*, *PT Sans Narrow*, *Raleway*, *Times New Roman*.",
+ "editType": "colorbars",
+ "noBlank": true,
+ "strict": true,
+ "valType": "string"
+ },
+ "size": {
+ "editType": "colorbars",
+ "min": 1,
+ "valType": "number"
+ }
+ },
+ "titleside": {
+ "description": "Deprecated in favor of color bar's `title.side`.",
+ "dflt": "top",
+ "editType": "colorbars",
+ "valType": "enumerated",
+ "values": [
+ "right",
+ "top",
+ "bottom"
+ ]
+ }
+ },
+ "bgcolor": {
+ "description": "Sets the color of padded area.",
+ "dflt": "rgba(0,0,0,0)",
+ "editType": "colorbars",
+ "valType": "color"
+ },
+ "bordercolor": {
+ "description": "Sets the axis line color.",
+ "dflt": "#444",
+ "editType": "colorbars",
+ "valType": "color"
+ },
+ "borderwidth": {
+ "description": "Sets the width (in px) or the border enclosing this color bar.",
+ "dflt": 0,
+ "editType": "colorbars",
+ "min": 0,
+ "valType": "number"
+ },
+ "dtick": {
+ "description": "Sets the step in-between ticks on this axis. Use with `tick0`. Must be a positive number, or special strings available to *log* and *date* axes. If the axis `type` is *log*, then ticks are set every 10^(n*dtick) where n is the tick number. For example, to set a tick mark at 1, 10, 100, 1000, ... set dtick to 1. To set tick marks at 1, 100, 10000, ... set dtick to 2. To set tick marks at 1, 5, 25, 125, 625, 3125, ... set dtick to log_10(5), or 0.69897000433. *log* has several special values; *L*, where `f` is a positive number, gives ticks linearly spaced in value (but not position). For example `tick0` = 0.1, `dtick` = *L0.5* will put ticks at 0.1, 0.6, 1.1, 1.6 etc. To show powers of 10 plus small digits between, use *D1* (all digits) or *D2* (only 2 and 5). `tick0` is ignored for *D1* and *D2*. If the axis `type` is *date*, then you must convert the time to milliseconds. For example, to set the interval between ticks to one day, set `dtick` to 86400000.0. *date* also has special values *M* gives ticks spaced by a number of months. `n` must be a positive integer. To set ticks on the 15th of every third month, set `tick0` to *2000-01-15* and `dtick` to *M3*. To set ticks every 4 years, set `dtick` to *M48*",
+ "editType": "colorbars",
+ "impliedEdits": {
+ "tickmode": "linear"
+ },
+ "valType": "any"
+ },
+ "editType": "colorbars",
+ "exponentformat": {
+ "description": "Determines a formatting rule for the tick exponents. For example, consider the number 1,000,000,000. If *none*, it appears as 1,000,000,000. If *e*, 1e+9. If *E*, 1E+9. If *power*, 1x10^9 (with 9 in a super script). If *SI*, 1G. If *B*, 1B.",
+ "dflt": "B",
+ "editType": "colorbars",
+ "valType": "enumerated",
+ "values": [
+ "none",
+ "e",
+ "E",
+ "power",
+ "SI",
+ "B"
+ ]
+ },
+ "len": {
+ "description": "Sets the length of the color bar This measure excludes the padding of both ends. That is, the color bar length is this length minus the padding on both ends.",
+ "dflt": 1,
+ "editType": "colorbars",
+ "min": 0,
+ "valType": "number"
+ },
+ "lenmode": {
+ "description": "Determines whether this color bar's length (i.e. the measure in the color variation direction) is set in units of plot *fraction* or in *pixels. Use `len` to set the value.",
+ "dflt": "fraction",
+ "editType": "colorbars",
+ "valType": "enumerated",
+ "values": [
+ "fraction",
+ "pixels"
+ ]
+ },
+ "minexponent": {
+ "description": "Hide SI prefix for 10^n if |n| is below this number. This only has an effect when `tickformat` is *SI* or *B*.",
+ "dflt": 3,
+ "editType": "colorbars",
+ "min": 0,
+ "valType": "number"
+ },
+ "nticks": {
+ "description": "Specifies the maximum number of ticks for the particular axis. The actual number of ticks will be chosen automatically to be less than or equal to `nticks`. Has an effect only if `tickmode` is set to *auto*.",
+ "dflt": 0,
+ "editType": "colorbars",
+ "min": 0,
+ "valType": "integer"
+ },
+ "outlinecolor": {
+ "description": "Sets the axis line color.",
+ "dflt": "#444",
+ "editType": "colorbars",
+ "valType": "color"
+ },
+ "outlinewidth": {
+ "description": "Sets the width (in px) of the axis line.",
+ "dflt": 1,
+ "editType": "colorbars",
+ "min": 0,
+ "valType": "number"
+ },
+ "role": "object",
+ "separatethousands": {
+ "description": "If \"true\", even 4-digit integers are separated",
+ "dflt": false,
+ "editType": "colorbars",
+ "valType": "boolean"
+ },
+ "showexponent": {
+ "description": "If *all*, all exponents are shown besides their significands. If *first*, only the exponent of the first tick is shown. If *last*, only the exponent of the last tick is shown. If *none*, no exponents appear.",
+ "dflt": "all",
+ "editType": "colorbars",
+ "valType": "enumerated",
+ "values": [
+ "all",
+ "first",
+ "last",
+ "none"
+ ]
+ },
+ "showticklabels": {
+ "description": "Determines whether or not the tick labels are drawn.",
+ "dflt": true,
+ "editType": "colorbars",
+ "valType": "boolean"
+ },
+ "showtickprefix": {
+ "description": "If *all*, all tick labels are displayed with a prefix. If *first*, only the first tick is displayed with a prefix. If *last*, only the last tick is displayed with a suffix. If *none*, tick prefixes are hidden.",
+ "dflt": "all",
+ "editType": "colorbars",
+ "valType": "enumerated",
+ "values": [
+ "all",
+ "first",
+ "last",
+ "none"
+ ]
+ },
+ "showticksuffix": {
+ "description": "Same as `showtickprefix` but for tick suffixes.",
+ "dflt": "all",
+ "editType": "colorbars",
+ "valType": "enumerated",
+ "values": [
+ "all",
+ "first",
+ "last",
+ "none"
+ ]
+ },
+ "thickness": {
+ "description": "Sets the thickness of the color bar This measure excludes the size of the padding, ticks and labels.",
+ "dflt": 30,
+ "editType": "colorbars",
+ "min": 0,
+ "valType": "number"
+ },
+ "thicknessmode": {
+ "description": "Determines whether this color bar's thickness (i.e. the measure in the constant color direction) is set in units of plot *fraction* or in *pixels*. Use `thickness` to set the value.",
+ "dflt": "pixels",
+ "editType": "colorbars",
+ "valType": "enumerated",
+ "values": [
+ "fraction",
+ "pixels"
+ ]
+ },
+ "tick0": {
+ "description": "Sets the placement of the first tick on this axis. Use with `dtick`. If the axis `type` is *log*, then you must take the log of your starting tick (e.g. to set the starting tick to 100, set the `tick0` to 2) except when `dtick`=*L* (see `dtick` for more info). If the axis `type` is *date*, it should be a date string, like date data. If the axis `type` is *category*, it should be a number, using the scale where each category is assigned a serial number from zero in the order it appears.",
+ "editType": "colorbars",
+ "impliedEdits": {
+ "tickmode": "linear"
+ },
+ "valType": "any"
+ },
+ "tickangle": {
+ "description": "Sets the angle of the tick labels with respect to the horizontal. For example, a `tickangle` of -90 draws the tick labels vertically.",
+ "dflt": "auto",
+ "editType": "colorbars",
+ "valType": "angle"
+ },
+ "tickcolor": {
+ "description": "Sets the tick color.",
+ "dflt": "#444",
+ "editType": "colorbars",
+ "valType": "color"
+ },
+ "tickfont": {
+ "color": {
+ "editType": "colorbars",
+ "valType": "color"
+ },
+ "description": "Sets the color bar's tick label font",
+ "editType": "colorbars",
+ "family": {
+ "description": "HTML font family - the typeface that will be applied by the web browser. The web browser will only be able to apply a font if it is available on the system which it operates. Provide multiple font families, separated by commas, to indicate the preference in which to apply fonts if they aren't available on the system. The Chart Studio Cloud (at https://chart-studio.plotly.com or on-premise) generates images on a server, where only a select number of fonts are installed and supported. These include *Arial*, *Balto*, *Courier New*, *Droid Sans*,, *Droid Serif*, *Droid Sans Mono*, *Gravitas One*, *Old Standard TT*, *Open Sans*, *Overpass*, *PT Sans Narrow*, *Raleway*, *Times New Roman*.",
+ "editType": "colorbars",
+ "noBlank": true,
+ "strict": true,
+ "valType": "string"
+ },
+ "role": "object",
+ "size": {
+ "editType": "colorbars",
+ "min": 1,
+ "valType": "number"
+ }
+ },
+ "tickformat": {
+ "description": "Sets the tick label formatting rule using d3 formatting mini-languages which are very similar to those in Python. For numbers, see: https://github.com/d3/d3-format/tree/v1.4.5#d3-format. And for dates see: https://github.com/d3/d3-time-format/tree/v2.2.3#locale_format. We add two items to d3's date formatter: *%h* for half of the year as a decimal number as well as *%{n}f* for fractional seconds with n digits. For example, *2016-10-13 09:15:23.456* with tickformat *%H~%M~%S.%2f* would display *09~15~23.46*",
+ "dflt": "",
+ "editType": "colorbars",
+ "valType": "string"
+ },
+ "tickformatstops": {
+ "items": {
+ "tickformatstop": {
+ "dtickrange": {
+ "description": "range [*min*, *max*], where *min*, *max* - dtick values which describe some zoom level, it is possible to omit *min* or *max* value by passing *null*",
+ "editType": "colorbars",
+ "items": [
+ {
+ "editType": "colorbars",
+ "valType": "any"
+ },
+ {
+ "editType": "colorbars",
+ "valType": "any"
+ }
+ ],
+ "valType": "info_array"
+ },
+ "editType": "colorbars",
+ "enabled": {
+ "description": "Determines whether or not this stop is used. If `false`, this stop is ignored even within its `dtickrange`.",
+ "dflt": true,
+ "editType": "colorbars",
+ "valType": "boolean"
+ },
+ "name": {
+ "description": "When used in a template, named items are created in the output figure in addition to any items the figure already has in this array. You can modify these items in the output figure by making your own item with `templateitemname` matching this `name` alongside your modifications (including `visible: false` or `enabled: false` to hide it). Has no effect outside of a template.",
+ "editType": "colorbars",
+ "valType": "string"
+ },
+ "role": "object",
+ "templateitemname": {
+ "description": "Used to refer to a named item in this array in the template. Named items from the template will be created even without a matching item in the input figure, but you can modify one by making an item with `templateitemname` matching its `name`, alongside your modifications (including `visible: false` or `enabled: false` to hide it). If there is no template or no matching item, this item will be hidden unless you explicitly show it with `visible: true`.",
+ "editType": "colorbars",
+ "valType": "string"
+ },
+ "value": {
+ "description": "string - dtickformat for described zoom level, the same as *tickformat*",
+ "dflt": "",
+ "editType": "colorbars",
+ "valType": "string"
+ }
+ }
+ },
+ "role": "object"
+ },
+ "ticklabeloverflow": {
+ "description": "Determines how we handle tick labels that would overflow either the graph div or the domain of the axis. The default value for inside tick labels is *hide past domain*. In other cases the default is *hide past div*.",
+ "editType": "colorbars",
+ "valType": "enumerated",
+ "values": [
+ "allow",
+ "hide past div",
+ "hide past domain"
+ ]
+ },
+ "ticklabelposition": {
+ "description": "Determines where tick labels are drawn.",
+ "dflt": "outside",
+ "editType": "colorbars",
+ "valType": "enumerated",
+ "values": [
+ "outside",
+ "inside",
+ "outside top",
+ "inside top",
+ "outside bottom",
+ "inside bottom"
+ ]
+ },
+ "ticklen": {
+ "description": "Sets the tick length (in px).",
+ "dflt": 5,
+ "editType": "colorbars",
+ "min": 0,
+ "valType": "number"
+ },
+ "tickmode": {
+ "description": "Sets the tick mode for this axis. If *auto*, the number of ticks is set via `nticks`. If *linear*, the placement of the ticks is determined by a starting position `tick0` and a tick step `dtick` (*linear* is the default value if `tick0` and `dtick` are provided). If *array*, the placement of the ticks is set via `tickvals` and the tick text is `ticktext`. (*array* is the default value if `tickvals` is provided).",
+ "editType": "colorbars",
+ "impliedEdits": {},
+ "valType": "enumerated",
+ "values": [
+ "auto",
+ "linear",
+ "array"
+ ]
+ },
+ "tickprefix": {
+ "description": "Sets a tick label prefix.",
+ "dflt": "",
+ "editType": "colorbars",
+ "valType": "string"
+ },
+ "ticks": {
+ "description": "Determines whether ticks are drawn or not. If **, this axis' ticks are not drawn. If *outside* (*inside*), this axis' are drawn outside (inside) the axis lines.",
+ "dflt": "",
+ "editType": "colorbars",
+ "valType": "enumerated",
+ "values": [
+ "outside",
+ "inside",
+ ""
+ ]
+ },
+ "ticksuffix": {
+ "description": "Sets a tick label suffix.",
+ "dflt": "",
+ "editType": "colorbars",
+ "valType": "string"
+ },
+ "ticktext": {
+ "description": "Sets the text displayed at the ticks position via `tickvals`. Only has an effect if `tickmode` is set to *array*. Used with `tickvals`.",
+ "editType": "colorbars",
+ "valType": "data_array"
+ },
+ "ticktextsrc": {
+ "description": "Sets the source reference on Chart Studio Cloud for `ticktext`.",
+ "editType": "none",
+ "valType": "string"
+ },
+ "tickvals": {
+ "description": "Sets the values at which ticks on this axis appear. Only has an effect if `tickmode` is set to *array*. Used with `ticktext`.",
+ "editType": "colorbars",
+ "valType": "data_array"
+ },
+ "tickvalssrc": {
+ "description": "Sets the source reference on Chart Studio Cloud for `tickvals`.",
+ "editType": "none",
+ "valType": "string"
+ },
+ "tickwidth": {
+ "description": "Sets the tick width (in px).",
+ "dflt": 1,
+ "editType": "colorbars",
+ "min": 0,
+ "valType": "number"
+ },
+ "title": {
+ "editType": "colorbars",
+ "font": {
+ "color": {
+ "editType": "colorbars",
+ "valType": "color"
+ },
+ "description": "Sets this color bar's title font. Note that the title's font used to be set by the now deprecated `titlefont` attribute.",
+ "editType": "colorbars",
+ "family": {
+ "description": "HTML font family - the typeface that will be applied by the web browser. The web browser will only be able to apply a font if it is available on the system which it operates. Provide multiple font families, separated by commas, to indicate the preference in which to apply fonts if they aren't available on the system. The Chart Studio Cloud (at https://chart-studio.plotly.com or on-premise) generates images on a server, where only a select number of fonts are installed and supported. These include *Arial*, *Balto*, *Courier New*, *Droid Sans*,, *Droid Serif*, *Droid Sans Mono*, *Gravitas One*, *Old Standard TT*, *Open Sans*, *Overpass*, *PT Sans Narrow*, *Raleway*, *Times New Roman*.",
+ "editType": "colorbars",
+ "noBlank": true,
+ "strict": true,
+ "valType": "string"
+ },
+ "role": "object",
+ "size": {
+ "editType": "colorbars",
+ "min": 1,
+ "valType": "number"
+ }
+ },
+ "role": "object",
+ "side": {
+ "description": "Determines the location of color bar's title with respect to the color bar. Note that the title's location used to be set by the now deprecated `titleside` attribute.",
+ "dflt": "top",
+ "editType": "colorbars",
+ "valType": "enumerated",
+ "values": [
+ "right",
+ "top",
+ "bottom"
+ ]
+ },
+ "text": {
+ "description": "Sets the title of the color bar. Note that before the existence of `title.text`, the title's contents used to be defined as the `title` attribute itself. This behavior has been deprecated.",
+ "editType": "colorbars",
+ "valType": "string"
+ }
+ },
+ "x": {
+ "description": "Sets the x position of the color bar (in plot fraction).",
+ "dflt": 1.02,
+ "editType": "colorbars",
+ "max": 3,
+ "min": -2,
+ "valType": "number"
+ },
+ "xanchor": {
+ "description": "Sets this color bar's horizontal position anchor. This anchor binds the `x` position to the *left*, *center* or *right* of the color bar.",
+ "dflt": "left",
+ "editType": "colorbars",
+ "valType": "enumerated",
+ "values": [
+ "left",
+ "center",
+ "right"
+ ]
+ },
+ "xpad": {
+ "description": "Sets the amount of padding (in px) along the x direction.",
+ "dflt": 10,
+ "editType": "colorbars",
+ "min": 0,
+ "valType": "number"
+ },
+ "y": {
+ "description": "Sets the y position of the color bar (in plot fraction).",
+ "dflt": 0.5,
+ "editType": "colorbars",
+ "max": 3,
+ "min": -2,
+ "valType": "number"
+ },
+ "yanchor": {
+ "description": "Sets this color bar's vertical position anchor This anchor binds the `y` position to the *top*, *middle* or *bottom* of the color bar.",
+ "dflt": "middle",
+ "editType": "colorbars",
+ "valType": "enumerated",
+ "values": [
+ "top",
+ "middle",
+ "bottom"
+ ]
+ },
+ "ypad": {
+ "description": "Sets the amount of padding (in px) along the y direction.",
+ "dflt": 10,
+ "editType": "colorbars",
+ "min": 0,
+ "valType": "number"
+ }
+ },
+ "colorscale": {
+ "description": "Sets the colorscale. Has an effect only if in `marker.color`is set to a numerical array. The colorscale must be an array containing arrays mapping a normalized value to an rgb, rgba, hex, hsl, hsv, or named color string. At minimum, a mapping for the lowest (0) and highest (1) values are required. For example, `[[0, 'rgb(0,0,255)'], [1, 'rgb(255,0,0)']]`. To control the bounds of the colorscale in color space, use`marker.cmin` and `marker.cmax`. Alternatively, `colorscale` may be a palette name string of the following list: Blackbody,Bluered,Blues,Cividis,Earth,Electric,Greens,Greys,Hot,Jet,Picnic,Portland,Rainbow,RdBu,Reds,Viridis,YlGnBu,YlOrRd.",
+ "dflt": null,
+ "editType": "calc",
+ "impliedEdits": {
+ "autocolorscale": false
+ },
+ "valType": "colorscale"
+ },
+ "colorsrc": {
+ "description": "Sets the source reference on Chart Studio Cloud for `color`.",
+ "editType": "none",
+ "valType": "string"
+ },
+ "editType": "calc",
+ "gradient": {
+ "color": {
+ "arrayOk": true,
+ "description": "Sets the final color of the gradient fill: the center color for radial, the right for horizontal, or the bottom for vertical.",
+ "editType": "calc",
+ "valType": "color"
+ },
+ "colorsrc": {
+ "description": "Sets the source reference on Chart Studio Cloud for `color`.",
+ "editType": "none",
+ "valType": "string"
+ },
+ "editType": "calc",
+ "role": "object",
+ "type": {
+ "arrayOk": true,
+ "description": "Sets the type of gradient used to fill the markers",
+ "dflt": "none",
+ "editType": "calc",
+ "valType": "enumerated",
+ "values": [
+ "radial",
+ "horizontal",
+ "vertical",
+ "none"
+ ]
+ },
+ "typesrc": {
+ "description": "Sets the source reference on Chart Studio Cloud for `type`.",
+ "editType": "none",
+ "valType": "string"
+ }
+ },
+ "line": {
+ "autocolorscale": {
+ "description": "Determines whether the colorscale is a default palette (`autocolorscale: true`) or the palette determined by `marker.line.colorscale`. Has an effect only if in `marker.line.color`is set to a numerical array. In case `colorscale` is unspecified or `autocolorscale` is true, the default palette will be chosen according to whether numbers in the `color` array are all positive, all negative or mixed.",
+ "dflt": true,
+ "editType": "calc",
+ "impliedEdits": {},
+ "valType": "boolean"
+ },
+ "cauto": {
+ "description": "Determines whether or not the color domain is computed with respect to the input data (here in `marker.line.color`) or the bounds set in `marker.line.cmin` and `marker.line.cmax` Has an effect only if in `marker.line.color`is set to a numerical array. Defaults to `false` when `marker.line.cmin` and `marker.line.cmax` are set by the user.",
+ "dflt": true,
+ "editType": "calc",
+ "impliedEdits": {},
+ "valType": "boolean"
+ },
+ "cmax": {
+ "description": "Sets the upper bound of the color domain. Has an effect only if in `marker.line.color`is set to a numerical array. Value should have the same units as in `marker.line.color` and if set, `marker.line.cmin` must be set as well.",
+ "dflt": null,
+ "editType": "plot",
+ "impliedEdits": {
+ "cauto": false
+ },
+ "valType": "number"
+ },
+ "cmid": {
+ "description": "Sets the mid-point of the color domain by scaling `marker.line.cmin` and/or `marker.line.cmax` to be equidistant to this point. Has an effect only if in `marker.line.color`is set to a numerical array. Value should have the same units as in `marker.line.color`. Has no effect when `marker.line.cauto` is `false`.",
+ "dflt": null,
+ "editType": "calc",
+ "impliedEdits": {},
+ "valType": "number"
+ },
+ "cmin": {
+ "description": "Sets the lower bound of the color domain. Has an effect only if in `marker.line.color`is set to a numerical array. Value should have the same units as in `marker.line.color` and if set, `marker.line.cmax` must be set as well.",
+ "dflt": null,
+ "editType": "plot",
+ "impliedEdits": {
+ "cauto": false
+ },
+ "valType": "number"
+ },
+ "color": {
+ "arrayOk": true,
+ "description": "Sets themarker.linecolor. It accepts either a specific color or an array of numbers that are mapped to the colorscale relative to the max and min values of the array or relative to `marker.line.cmin` and `marker.line.cmax` if set.",
+ "editType": "style",
+ "valType": "color"
+ },
+ "coloraxis": {
+ "description": "Sets a reference to a shared color axis. References to these shared color axes are *coloraxis*, *coloraxis2*, *coloraxis3*, etc. Settings for these shared color axes are set in the layout, under `layout.coloraxis`, `layout.coloraxis2`, etc. Note that multiple color scales can be linked to the same color axis.",
+ "dflt": null,
+ "editType": "calc",
+ "regex": "/^coloraxis([2-9]|[1-9][0-9]+)?$/",
+ "valType": "subplotid"
+ },
+ "colorscale": {
+ "description": "Sets the colorscale. Has an effect only if in `marker.line.color`is set to a numerical array. The colorscale must be an array containing arrays mapping a normalized value to an rgb, rgba, hex, hsl, hsv, or named color string. At minimum, a mapping for the lowest (0) and highest (1) values are required. For example, `[[0, 'rgb(0,0,255)'], [1, 'rgb(255,0,0)']]`. To control the bounds of the colorscale in color space, use`marker.line.cmin` and `marker.line.cmax`. Alternatively, `colorscale` may be a palette name string of the following list: Blackbody,Bluered,Blues,Cividis,Earth,Electric,Greens,Greys,Hot,Jet,Picnic,Portland,Rainbow,RdBu,Reds,Viridis,YlGnBu,YlOrRd.",
+ "dflt": null,
+ "editType": "calc",
+ "impliedEdits": {
+ "autocolorscale": false
+ },
+ "valType": "colorscale"
+ },
+ "colorsrc": {
+ "description": "Sets the source reference on Chart Studio Cloud for `color`.",
+ "editType": "none",
+ "valType": "string"
+ },
+ "editType": "calc",
+ "reversescale": {
+ "description": "Reverses the color mapping if true. Has an effect only if in `marker.line.color`is set to a numerical array. If true, `marker.line.cmin` will correspond to the last color in the array and `marker.line.cmax` will correspond to the first color.",
+ "dflt": false,
+ "editType": "plot",
+ "valType": "boolean"
+ },
+ "role": "object",
+ "width": {
+ "arrayOk": true,
+ "description": "Sets the width (in px) of the lines bounding the marker points.",
+ "editType": "style",
+ "min": 0,
+ "valType": "number"
+ },
+ "widthsrc": {
+ "description": "Sets the source reference on Chart Studio Cloud for `width`.",
+ "editType": "none",
+ "valType": "string"
+ }
+ },
+ "maxdisplayed": {
+ "description": "Sets a maximum number of points to be drawn on the graph. *0* corresponds to no limit.",
+ "dflt": 0,
+ "editType": "plot",
+ "min": 0,
+ "valType": "number"
+ },
+ "opacity": {
+ "arrayOk": true,
+ "description": "Sets the marker opacity.",
+ "editType": "style",
+ "max": 1,
+ "min": 0,
+ "valType": "number"
+ },
+ "opacitysrc": {
+ "description": "Sets the source reference on Chart Studio Cloud for `opacity`.",
+ "editType": "none",
+ "valType": "string"
+ },
+ "reversescale": {
+ "description": "Reverses the color mapping if true. Has an effect only if in `marker.color`is set to a numerical array. If true, `marker.cmin` will correspond to the last color in the array and `marker.cmax` will correspond to the first color.",
+ "dflt": false,
+ "editType": "plot",
+ "valType": "boolean"
+ },
+ "role": "object",
+ "showscale": {
+ "description": "Determines whether or not a colorbar is displayed for this trace. Has an effect only if in `marker.color`is set to a numerical array.",
+ "dflt": false,
+ "editType": "calc",
+ "valType": "boolean"
+ },
+ "size": {
+ "arrayOk": true,
+ "description": "Sets the marker size (in px).",
+ "dflt": 6,
+ "editType": "calc",
+ "min": 0,
+ "valType": "number"
+ },
+ "sizemin": {
+ "description": "Has an effect only if `marker.size` is set to a numerical array. Sets the minimum size (in px) of the rendered marker points.",
+ "dflt": 0,
+ "editType": "calc",
+ "min": 0,
+ "valType": "number"
+ },
+ "sizemode": {
+ "description": "Has an effect only if `marker.size` is set to a numerical array. Sets the rule for which the data in `size` is converted to pixels.",
+ "dflt": "diameter",
+ "editType": "calc",
+ "valType": "enumerated",
+ "values": [
+ "diameter",
+ "area"
+ ]
+ },
+ "sizeref": {
+ "description": "Has an effect only if `marker.size` is set to a numerical array. Sets the scale factor used to determine the rendered size of marker points. Use with `sizemin` and `sizemode`.",
+ "dflt": 1,
+ "editType": "calc",
+ "valType": "number"
+ },
+ "sizesrc": {
+ "description": "Sets the source reference on Chart Studio Cloud for `size`.",
+ "editType": "none",
+ "valType": "string"
+ },
+ "symbol": {
+ "arrayOk": true,
+ "description": "Sets the marker symbol type. Adding 100 is equivalent to appending *-open* to a symbol name. Adding 200 is equivalent to appending *-dot* to a symbol name. Adding 300 is equivalent to appending *-open-dot* or *dot-open* to a symbol name.",
+ "dflt": "circle",
+ "editType": "style",
+ "valType": "enumerated",
+ "values": [
+ 0,
+ "0",
+ "circle",
+ 100,
+ "100",
+ "circle-open",
+ 200,
+ "200",
+ "circle-dot",
+ 300,
+ "300",
+ "circle-open-dot",
+ 1,
+ "1",
+ "square",
+ 101,
+ "101",
+ "square-open",
+ 201,
+ "201",
+ "square-dot",
+ 301,
+ "301",
+ "square-open-dot",
+ 2,
+ "2",
+ "diamond",
+ 102,
+ "102",
+ "diamond-open",
+ 202,
+ "202",
+ "diamond-dot",
+ 302,
+ "302",
+ "diamond-open-dot",
+ 3,
+ "3",
+ "cross",
+ 103,
+ "103",
+ "cross-open",
+ 203,
+ "203",
+ "cross-dot",
+ 303,
+ "303",
+ "cross-open-dot",
+ 4,
+ "4",
+ "x",
+ 104,
+ "104",
+ "x-open",
+ 204,
+ "204",
+ "x-dot",
+ 304,
+ "304",
+ "x-open-dot",
+ 5,
+ "5",
+ "triangle-up",
+ 105,
+ "105",
+ "triangle-up-open",
+ 205,
+ "205",
+ "triangle-up-dot",
+ 305,
+ "305",
+ "triangle-up-open-dot",
+ 6,
+ "6",
+ "triangle-down",
+ 106,
+ "106",
+ "triangle-down-open",
+ 206,
+ "206",
+ "triangle-down-dot",
+ 306,
+ "306",
+ "triangle-down-open-dot",
+ 7,
+ "7",
+ "triangle-left",
+ 107,
+ "107",
+ "triangle-left-open",
+ 207,
+ "207",
+ "triangle-left-dot",
+ 307,
+ "307",
+ "triangle-left-open-dot",
+ 8,
+ "8",
+ "triangle-right",
+ 108,
+ "108",
+ "triangle-right-open",
+ 208,
+ "208",
+ "triangle-right-dot",
+ 308,
+ "308",
+ "triangle-right-open-dot",
+ 9,
+ "9",
+ "triangle-ne",
+ 109,
+ "109",
+ "triangle-ne-open",
+ 209,
+ "209",
+ "triangle-ne-dot",
+ 309,
+ "309",
+ "triangle-ne-open-dot",
+ 10,
+ "10",
+ "triangle-se",
+ 110,
+ "110",
+ "triangle-se-open",
+ 210,
+ "210",
+ "triangle-se-dot",
+ 310,
+ "310",
+ "triangle-se-open-dot",
+ 11,
+ "11",
+ "triangle-sw",
+ 111,
+ "111",
+ "triangle-sw-open",
+ 211,
+ "211",
+ "triangle-sw-dot",
+ 311,
+ "311",
+ "triangle-sw-open-dot",
+ 12,
+ "12",
+ "triangle-nw",
+ 112,
+ "112",
+ "triangle-nw-open",
+ 212,
+ "212",
+ "triangle-nw-dot",
+ 312,
+ "312",
+ "triangle-nw-open-dot",
+ 13,
+ "13",
+ "pentagon",
+ 113,
+ "113",
+ "pentagon-open",
+ 213,
+ "213",
+ "pentagon-dot",
+ 313,
+ "313",
+ "pentagon-open-dot",
+ 14,
+ "14",
+ "hexagon",
+ 114,
+ "114",
+ "hexagon-open",
+ 214,
+ "214",
+ "hexagon-dot",
+ 314,
+ "314",
+ "hexagon-open-dot",
+ 15,
+ "15",
+ "hexagon2",
+ 115,
+ "115",
+ "hexagon2-open",
+ 215,
+ "215",
+ "hexagon2-dot",
+ 315,
+ "315",
+ "hexagon2-open-dot",
+ 16,
+ "16",
+ "octagon",
+ 116,
+ "116",
+ "octagon-open",
+ 216,
+ "216",
+ "octagon-dot",
+ 316,
+ "316",
+ "octagon-open-dot",
+ 17,
+ "17",
+ "star",
+ 117,
+ "117",
+ "star-open",
+ 217,
+ "217",
+ "star-dot",
+ 317,
+ "317",
+ "star-open-dot",
+ 18,
+ "18",
+ "hexagram",
+ 118,
+ "118",
+ "hexagram-open",
+ 218,
+ "218",
+ "hexagram-dot",
+ 318,
+ "318",
+ "hexagram-open-dot",
+ 19,
+ "19",
+ "star-triangle-up",
+ 119,
+ "119",
+ "star-triangle-up-open",
+ 219,
+ "219",
+ "star-triangle-up-dot",
+ 319,
+ "319",
+ "star-triangle-up-open-dot",
+ 20,
+ "20",
+ "star-triangle-down",
+ 120,
+ "120",
+ "star-triangle-down-open",
+ 220,
+ "220",
+ "star-triangle-down-dot",
+ 320,
+ "320",
+ "star-triangle-down-open-dot",
+ 21,
+ "21",
+ "star-square",
+ 121,
+ "121",
+ "star-square-open",
+ 221,
+ "221",
+ "star-square-dot",
+ 321,
+ "321",
+ "star-square-open-dot",
+ 22,
+ "22",
+ "star-diamond",
+ 122,
+ "122",
+ "star-diamond-open",
+ 222,
+ "222",
+ "star-diamond-dot",
+ 322,
+ "322",
+ "star-diamond-open-dot",
+ 23,
+ "23",
+ "diamond-tall",
+ 123,
+ "123",
+ "diamond-tall-open",
+ 223,
+ "223",
+ "diamond-tall-dot",
+ 323,
+ "323",
+ "diamond-tall-open-dot",
+ 24,
+ "24",
+ "diamond-wide",
+ 124,
+ "124",
+ "diamond-wide-open",
+ 224,
+ "224",
+ "diamond-wide-dot",
+ 324,
+ "324",
+ "diamond-wide-open-dot",
+ 25,
+ "25",
+ "hourglass",
+ 125,
+ "125",
+ "hourglass-open",
+ 26,
+ "26",
+ "bowtie",
+ 126,
+ "126",
+ "bowtie-open",
+ 27,
+ "27",
+ "circle-cross",
+ 127,
+ "127",
+ "circle-cross-open",
+ 28,
+ "28",
+ "circle-x",
+ 128,
+ "128",
+ "circle-x-open",
+ 29,
+ "29",
+ "square-cross",
+ 129,
+ "129",
+ "square-cross-open",
+ 30,
+ "30",
+ "square-x",
+ 130,
+ "130",
+ "square-x-open",
+ 31,
+ "31",
+ "diamond-cross",
+ 131,
+ "131",
+ "diamond-cross-open",
+ 32,
+ "32",
+ "diamond-x",
+ 132,
+ "132",
+ "diamond-x-open",
+ 33,
+ "33",
+ "cross-thin",
+ 133,
+ "133",
+ "cross-thin-open",
+ 34,
+ "34",
+ "x-thin",
+ 134,
+ "134",
+ "x-thin-open",
+ 35,
+ "35",
+ "asterisk",
+ 135,
+ "135",
+ "asterisk-open",
+ 36,
+ "36",
+ "hash",
+ 136,
+ "136",
+ "hash-open",
+ 236,
+ "236",
+ "hash-dot",
+ 336,
+ "336",
+ "hash-open-dot",
+ 37,
+ "37",
+ "y-up",
+ 137,
+ "137",
+ "y-up-open",
+ 38,
+ "38",
+ "y-down",
+ 138,
+ "138",
+ "y-down-open",
+ 39,
+ "39",
+ "y-left",
+ 139,
+ "139",
+ "y-left-open",
+ 40,
+ "40",
+ "y-right",
+ 140,
+ "140",
+ "y-right-open",
+ 41,
+ "41",
+ "line-ew",
+ 141,
+ "141",
+ "line-ew-open",
+ 42,
+ "42",
+ "line-ns",
+ 142,
+ "142",
+ "line-ns-open",
+ 43,
+ "43",
+ "line-ne",
+ 143,
+ "143",
+ "line-ne-open",
+ 44,
+ "44",
+ "line-nw",
+ 144,
+ "144",
+ "line-nw-open",
+ 45,
+ "45",
+ "arrow-up",
+ 145,
+ "145",
+ "arrow-up-open",
+ 46,
+ "46",
+ "arrow-down",
+ 146,
+ "146",
+ "arrow-down-open",
+ 47,
+ "47",
+ "arrow-left",
+ 147,
+ "147",
+ "arrow-left-open",
+ 48,
+ "48",
+ "arrow-right",
+ 148,
+ "148",
+ "arrow-right-open",
+ 49,
+ "49",
+ "arrow-bar-up",
+ 149,
+ "149",
+ "arrow-bar-up-open",
+ 50,
+ "50",
+ "arrow-bar-down",
+ 150,
+ "150",
+ "arrow-bar-down-open",
+ 51,
+ "51",
+ "arrow-bar-left",
+ 151,
+ "151",
+ "arrow-bar-left-open",
+ 52,
+ "52",
+ "arrow-bar-right",
+ 152,
+ "152",
+ "arrow-bar-right-open"
+ ]
+ },
+ "symbolsrc": {
+ "description": "Sets the source reference on Chart Studio Cloud for `symbol`.",
+ "editType": "none",
+ "valType": "string"
+ }
+ },
+ "meta": {
+ "arrayOk": true,
+ "description": "Assigns extra meta information associated with this trace that can be used in various text attributes. Attributes such as trace `name`, graph, axis and colorbar `title.text`, annotation `text` `rangeselector`, `updatemenues` and `sliders` `label` text all support `meta`. To access the trace `meta` values in an attribute in the same trace, simply use `%{meta[i]}` where `i` is the index or key of the `meta` item in question. To access trace `meta` in layout attributes, use `%{data[n[.meta[i]}` where `i` is the index or key of the `meta` and `n` is the trace index.",
+ "editType": "plot",
+ "valType": "any"
+ },
+ "metasrc": {
+ "description": "Sets the source reference on Chart Studio Cloud for `meta`.",
+ "editType": "none",
+ "valType": "string"
+ },
+ "mode": {
+ "description": "Determines the drawing mode for this scatter trace. If the provided `mode` includes *text* then the `text` elements appear at the coordinates. Otherwise, the `text` elements appear on hover. If there are less than 20 points and the trace is not stacked then the default is *lines+markers*. Otherwise, *lines*.",
+ "editType": "calc",
+ "extras": [
+ "none"
+ ],
+ "flags": [
+ "lines",
+ "markers",
+ "text"
+ ],
+ "valType": "flaglist"
+ },
+ "name": {
+ "description": "Sets the trace name. The trace name appear as the legend item and on hover.",
+ "editType": "style",
+ "valType": "string"
+ },
+ "opacity": {
+ "description": "Sets the opacity of the trace.",
+ "dflt": 1,
+ "editType": "style",
+ "max": 1,
+ "min": 0,
+ "valType": "number"
+ },
+ "r": {
+ "description": "Sets the radial coordinates",
+ "editType": "calc+clearAxisTypes",
+ "valType": "data_array"
+ },
+ "r0": {
+ "description": "Alternate to `r`. Builds a linear space of r coordinates. Use with `dr` where `r0` is the starting coordinate and `dr` the step.",
+ "dflt": 0,
+ "editType": "calc+clearAxisTypes",
+ "valType": "any"
+ },
+ "rsrc": {
+ "description": "Sets the source reference on Chart Studio Cloud for `r`.",
+ "editType": "none",
+ "valType": "string"
+ },
+ "selected": {
+ "editType": "style",
+ "marker": {
+ "color": {
+ "description": "Sets the marker color of selected points.",
+ "editType": "style",
+ "valType": "color"
+ },
+ "editType": "style",
+ "opacity": {
+ "description": "Sets the marker opacity of selected points.",
+ "editType": "style",
+ "max": 1,
+ "min": 0,
+ "valType": "number"
+ },
+ "role": "object",
+ "size": {
+ "description": "Sets the marker size of selected points.",
+ "editType": "style",
+ "min": 0,
+ "valType": "number"
+ }
+ },
+ "role": "object",
+ "textfont": {
+ "color": {
+ "description": "Sets the text font color of selected points.",
+ "editType": "style",
+ "valType": "color"
+ },
+ "editType": "style",
+ "role": "object"
+ }
+ },
+ "selectedpoints": {
+ "description": "Array containing integer indices of selected points. Has an effect only for traces that support selections. Note that an empty array means an empty selection where the `unselected` are turned on for all points, whereas, any other non-array values means no selection all where the `selected` and `unselected` styles have no effect.",
+ "editType": "calc",
+ "valType": "any"
+ },
+ "showlegend": {
+ "description": "Determines whether or not an item corresponding to this trace is shown in the legend.",
+ "dflt": true,
+ "editType": "style",
+ "valType": "boolean"
+ },
+ "stream": {
+ "editType": "calc",
+ "maxpoints": {
+ "description": "Sets the maximum number of points to keep on the plots from an incoming stream. If `maxpoints` is set to *50*, only the newest 50 points will be displayed on the plot.",
+ "dflt": 500,
+ "editType": "calc",
+ "max": 10000,
+ "min": 0,
+ "valType": "number"
+ },
+ "role": "object",
+ "token": {
+ "description": "The stream id number links a data trace on a plot with a stream. See https://chart-studio.plotly.com/settings for more details.",
+ "editType": "calc",
+ "noBlank": true,
+ "strict": true,
+ "valType": "string"
+ }
+ },
+ "subplot": {
+ "description": "Sets a reference between this trace's data coordinates and a polar subplot. If *polar* (the default value), the data refer to `layout.polar`. If *polar2*, the data refer to `layout.polar2`, and so on.",
+ "dflt": "polar",
+ "editType": "calc",
+ "valType": "subplotid"
+ },
+ "text": {
+ "arrayOk": true,
+ "description": "Sets text elements associated with each (x,y) pair. If a single string, the same string appears over all the data points. If an array of string, the items are mapped in order to the this trace's (x,y) coordinates. If trace `hoverinfo` contains a *text* flag and *hovertext* is not set, these elements will be seen in the hover labels.",
+ "dflt": "",
+ "editType": "calc",
+ "valType": "string"
+ },
+ "textfont": {
+ "color": {
+ "arrayOk": true,
+ "editType": "style",
+ "valType": "color"
+ },
+ "colorsrc": {
+ "description": "Sets the source reference on Chart Studio Cloud for `color`.",
+ "editType": "none",
+ "valType": "string"
+ },
+ "description": "Sets the text font.",
+ "editType": "calc",
+ "family": {
+ "arrayOk": true,
+ "description": "HTML font family - the typeface that will be applied by the web browser. The web browser will only be able to apply a font if it is available on the system which it operates. Provide multiple font families, separated by commas, to indicate the preference in which to apply fonts if they aren't available on the system. The Chart Studio Cloud (at https://chart-studio.plotly.com or on-premise) generates images on a server, where only a select number of fonts are installed and supported. These include *Arial*, *Balto*, *Courier New*, *Droid Sans*,, *Droid Serif*, *Droid Sans Mono*, *Gravitas One*, *Old Standard TT*, *Open Sans*, *Overpass*, *PT Sans Narrow*, *Raleway*, *Times New Roman*.",
+ "editType": "calc",
+ "noBlank": true,
+ "strict": true,
+ "valType": "string"
+ },
+ "familysrc": {
+ "description": "Sets the source reference on Chart Studio Cloud for `family`.",
+ "editType": "none",
+ "valType": "string"
+ },
+ "role": "object",
+ "size": {
+ "arrayOk": true,
+ "editType": "calc",
+ "min": 1,
+ "valType": "number"
+ },
+ "sizesrc": {
+ "description": "Sets the source reference on Chart Studio Cloud for `size`.",
+ "editType": "none",
+ "valType": "string"
+ }
+ },
+ "textposition": {
+ "arrayOk": true,
+ "description": "Sets the positions of the `text` elements with respects to the (x,y) coordinates.",
+ "dflt": "middle center",
+ "editType": "calc",
+ "valType": "enumerated",
+ "values": [
+ "top left",
+ "top center",
+ "top right",
+ "middle left",
+ "middle center",
+ "middle right",
+ "bottom left",
+ "bottom center",
+ "bottom right"
+ ]
+ },
+ "textpositionsrc": {
+ "description": "Sets the source reference on Chart Studio Cloud for `textposition`.",
+ "editType": "none",
+ "valType": "string"
+ },
+ "textsrc": {
+ "description": "Sets the source reference on Chart Studio Cloud for `text`.",
+ "editType": "none",
+ "valType": "string"
+ },
+ "texttemplate": {
+ "arrayOk": true,
+ "description": "Template string used for rendering the information text that appear on points. Note that this will override `textinfo`. Variables are inserted using %{variable}, for example \"y: %{y}\". Numbers are formatted using d3-format's syntax %{variable:d3-format}, for example \"Price: %{y:$.2f}\". https://github.com/d3/d3-format/tree/v1.4.5#d3-format for details on the formatting syntax. Dates are formatted using d3-time-format's syntax %{variable|d3-time-format}, for example \"Day: %{2019-01-01|%A}\". https://github.com/d3/d3-time-format/tree/v2.2.3#locale_format for details on the date formatting syntax. Every attributes that can be specified per-point (the ones that are `arrayOk: true`) are available. variables `r`, `theta` and `text`.",
+ "dflt": "",
+ "editType": "plot",
+ "valType": "string"
+ },
+ "texttemplatesrc": {
+ "description": "Sets the source reference on Chart Studio Cloud for `texttemplate`.",
+ "editType": "none",
+ "valType": "string"
+ },
+ "theta": {
+ "description": "Sets the angular coordinates",
+ "editType": "calc+clearAxisTypes",
+ "valType": "data_array"
+ },
+ "theta0": {
+ "description": "Alternate to `theta`. Builds a linear space of theta coordinates. Use with `dtheta` where `theta0` is the starting coordinate and `dtheta` the step.",
+ "dflt": 0,
+ "editType": "calc+clearAxisTypes",
+ "valType": "any"
+ },
+ "thetasrc": {
+ "description": "Sets the source reference on Chart Studio Cloud for `theta`.",
+ "editType": "none",
+ "valType": "string"
+ },
+ "thetaunit": {
+ "description": "Sets the unit of input *theta* values. Has an effect only when on *linear* angular axes.",
+ "dflt": "degrees",
+ "editType": "calc+clearAxisTypes",
+ "valType": "enumerated",
+ "values": [
+ "radians",
+ "degrees",
+ "gradians"
+ ]
+ },
+ "transforms": {
+ "items": {
+ "transform": {
+ "description": "WARNING: All transforms are deprecated and may be removed from the API in next major version. An array of operations that manipulate the trace data, for example filtering or sorting the data arrays.",
+ "editType": "calc",
+ "role": "object"
+ }
+ },
+ "role": "object"
+ },
+ "type": "scatterpolar",
+ "uid": {
+ "description": "Assign an id to this trace, Use this to provide object constancy between traces during animations and transitions.",
+ "editType": "plot",
+ "valType": "string"
+ },
+ "uirevision": {
+ "description": "Controls persistence of some user-driven changes to the trace: `constraintrange` in `parcoords` traces, as well as some `editable: true` modifications such as `name` and `colorbar.title`. Defaults to `layout.uirevision`. Note that other user-driven trace attribute changes are controlled by `layout` attributes: `trace.visible` is controlled by `layout.legend.uirevision`, `selectedpoints` is controlled by `layout.selectionrevision`, and `colorbar.(x|y)` (accessible with `config: {editable: true}`) is controlled by `layout.editrevision`. Trace changes are tracked by `uid`, which only falls back on trace index if no `uid` is provided. So if your app can add/remove traces before the end of the `data` array, such that the same trace has a different index, you can still preserve user-driven changes if you give each trace a `uid` that stays with it as it moves.",
+ "editType": "none",
+ "valType": "any"
+ },
+ "unselected": {
+ "editType": "style",
+ "marker": {
+ "color": {
+ "description": "Sets the marker color of unselected points, applied only when a selection exists.",
+ "editType": "style",
+ "valType": "color"
+ },
+ "editType": "style",
+ "opacity": {
+ "description": "Sets the marker opacity of unselected points, applied only when a selection exists.",
+ "editType": "style",
+ "max": 1,
+ "min": 0,
+ "valType": "number"
+ },
+ "role": "object",
+ "size": {
+ "description": "Sets the marker size of unselected points, applied only when a selection exists.",
+ "editType": "style",
+ "min": 0,
+ "valType": "number"
+ }
+ },
+ "role": "object",
+ "textfont": {
+ "color": {
+ "description": "Sets the text font color of unselected points, applied only when a selection exists.",
+ "editType": "style",
+ "valType": "color"
+ },
+ "editType": "style",
+ "role": "object"
+ }
+ },
+ "visible": {
+ "description": "Determines whether or not this trace is visible. If *legendonly*, the trace is not drawn, but can appear as a legend item (provided that the legend itself is visible).",
+ "dflt": true,
+ "editType": "calc",
+ "valType": "enumerated",
+ "values": [
+ true,
+ false,
+ "legendonly"
+ ]
+ }
+ },
+ "categories": [
+ "polar",
+ "symbols",
+ "showLegend",
+ "scatter-like"
+ ],
+ "meta": {
+ "description": "The scatterpolar trace type encompasses line charts, scatter charts, text charts, and bubble charts in polar coordinates. The data visualized as scatter point or lines is set in `r` (radial) and `theta` (angular) coordinates Text (appearing either on the chart or on hover only) is via `text`. Bubble charts are achieved by setting `marker.size` and/or `marker.color` to numerical arrays.",
+ "hrName": "scatter_polar"
+ },
+ "type": "scatterpolar"
+ },
+ "scatterpolargl": {
+ "animatable": false,
+ "attributes": {
+ "connectgaps": {
+ "description": "Determines whether or not gaps (i.e. {nan} or missing values) in the provided data arrays are connected.",
+ "dflt": false,
+ "editType": "calc",
+ "valType": "boolean"
+ },
+ "customdata": {
+ "description": "Assigns extra data each datum. This may be useful when listening to hover, click and selection events. Note that, *scatter* traces also appends customdata items in the markers DOM elements",
+ "editType": "calc",
+ "valType": "data_array"
+ },
+ "customdatasrc": {
+ "description": "Sets the source reference on Chart Studio Cloud for `customdata`.",
+ "editType": "none",
+ "valType": "string"
+ },
+ "dr": {
+ "description": "Sets the r coordinate step.",
+ "dflt": 1,
+ "editType": "calc",
+ "valType": "number"
+ },
+ "dtheta": {
+ "description": "Sets the theta coordinate step. By default, the `dtheta` step equals the subplot's period divided by the length of the `r` coordinates.",
+ "editType": "calc",
+ "valType": "number"
+ },
+ "fill": {
+ "description": "Sets the area to fill with a solid color. Defaults to *none* unless this trace is stacked, then it gets *tonexty* (*tonextx*) if `orientation` is *v* (*h*) Use with `fillcolor` if not *none*. *tozerox* and *tozeroy* fill to x=0 and y=0 respectively. *tonextx* and *tonexty* fill between the endpoints of this trace and the endpoints of the trace before it, connecting those endpoints with straight lines (to make a stacked area graph); if there is no trace before it, they behave like *tozerox* and *tozeroy*. *toself* connects the endpoints of the trace (or each segment of the trace if it has gaps) into a closed shape. *tonext* fills the space between two traces if one completely encloses the other (eg consecutive contour lines), and behaves like *toself* if there is no trace before it. *tonext* should not be used if one trace does not enclose the other. Traces in a `stackgroup` will only fill to (or be filled to) other traces in the same group. With multiple `stackgroup`s or some traces stacked and some not, if fill-linked traces are not already consecutive, the later ones will be pushed down in the drawing order.",
+ "dflt": "none",
+ "editType": "calc",
+ "valType": "enumerated",
+ "values": [
+ "none",
+ "tozeroy",
+ "tozerox",
+ "tonexty",
+ "tonextx",
+ "toself",
+ "tonext"
+ ]
+ },
+ "fillcolor": {
+ "description": "Sets the fill color. Defaults to a half-transparent variant of the line color, marker color, or marker line color, whichever is available.",
+ "editType": "calc",
+ "valType": "color"
+ },
+ "hoverinfo": {
+ "arrayOk": true,
+ "description": "Determines which trace information appear on hover. If `none` or `skip` are set, no information is displayed upon hovering. But, if `none` is set, click and hover events are still fired.",
+ "dflt": "all",
+ "editType": "none",
+ "extras": [
+ "all",
+ "none",
+ "skip"
+ ],
+ "flags": [
+ "r",
+ "theta",
+ "text",
+ "name"
+ ],
+ "valType": "flaglist"
+ },
+ "hoverinfosrc": {
+ "description": "Sets the source reference on Chart Studio Cloud for `hoverinfo`.",
+ "editType": "none",
+ "valType": "string"
+ },
+ "hoverlabel": {
+ "align": {
+ "arrayOk": true,
+ "description": "Sets the horizontal alignment of the text content within hover label box. Has an effect only if the hover label text spans more two or more lines",
+ "dflt": "auto",
+ "editType": "none",
+ "valType": "enumerated",
+ "values": [
+ "left",
+ "right",
+ "auto"
+ ]
+ },
+ "alignsrc": {
+ "description": "Sets the source reference on Chart Studio Cloud for `align`.",
+ "editType": "none",
+ "valType": "string"
+ },
+ "bgcolor": {
+ "arrayOk": true,
+ "description": "Sets the background color of the hover labels for this trace",
+ "editType": "none",
+ "valType": "color"
+ },
+ "bgcolorsrc": {
+ "description": "Sets the source reference on Chart Studio Cloud for `bgcolor`.",
+ "editType": "none",
+ "valType": "string"
+ },
+ "bordercolor": {
+ "arrayOk": true,
+ "description": "Sets the border color of the hover labels for this trace.",
+ "editType": "none",
+ "valType": "color"
+ },
+ "bordercolorsrc": {
+ "description": "Sets the source reference on Chart Studio Cloud for `bordercolor`.",
+ "editType": "none",
+ "valType": "string"
+ },
+ "editType": "none",
+ "font": {
+ "color": {
+ "arrayOk": true,
+ "editType": "none",
+ "valType": "color"
+ },
+ "colorsrc": {
+ "description": "Sets the source reference on Chart Studio Cloud for `color`.",
+ "editType": "none",
+ "valType": "string"
+ },
+ "description": "Sets the font used in hover labels.",
+ "editType": "none",
+ "family": {
+ "arrayOk": true,
+ "description": "HTML font family - the typeface that will be applied by the web browser. The web browser will only be able to apply a font if it is available on the system which it operates. Provide multiple font families, separated by commas, to indicate the preference in which to apply fonts if they aren't available on the system. The Chart Studio Cloud (at https://chart-studio.plotly.com or on-premise) generates images on a server, where only a select number of fonts are installed and supported. These include *Arial*, *Balto*, *Courier New*, *Droid Sans*,, *Droid Serif*, *Droid Sans Mono*, *Gravitas One*, *Old Standard TT*, *Open Sans*, *Overpass*, *PT Sans Narrow*, *Raleway*, *Times New Roman*.",
+ "editType": "none",
+ "noBlank": true,
+ "strict": true,
+ "valType": "string"
+ },
+ "familysrc": {
+ "description": "Sets the source reference on Chart Studio Cloud for `family`.",
+ "editType": "none",
+ "valType": "string"
+ },
+ "role": "object",
+ "size": {
+ "arrayOk": true,
+ "editType": "none",
+ "min": 1,
+ "valType": "number"
+ },
+ "sizesrc": {
+ "description": "Sets the source reference on Chart Studio Cloud for `size`.",
+ "editType": "none",
+ "valType": "string"
+ }
+ },
+ "namelength": {
+ "arrayOk": true,
+ "description": "Sets the default length (in number of characters) of the trace name in the hover labels for all traces. -1 shows the whole name regardless of length. 0-3 shows the first 0-3 characters, and an integer >3 will show the whole name if it is less than that many characters, but if it is longer, will truncate to `namelength - 3` characters and add an ellipsis.",
+ "dflt": 15,
+ "editType": "none",
+ "min": -1,
+ "valType": "integer"
+ },
+ "namelengthsrc": {
+ "description": "Sets the source reference on Chart Studio Cloud for `namelength`.",
+ "editType": "none",
+ "valType": "string"
+ },
+ "role": "object"
+ },
+ "hovertemplate": {
+ "arrayOk": true,
+ "description": "Template string used for rendering the information that appear on hover box. Note that this will override `hoverinfo`. Variables are inserted using %{variable}, for example \"y: %{y}\" as well as %{xother}, {%_xother}, {%_xother_}, {%xother_}. When showing info for several points, *xother* will be added to those with different x positions from the first point. An underscore before or after *(x|y)other* will add a space on that side, only when this field is shown. Numbers are formatted using d3-format's syntax %{variable:d3-format}, for example \"Price: %{y:$.2f}\". https://github.com/d3/d3-format/tree/v1.4.5#d3-format for details on the formatting syntax. Dates are formatted using d3-time-format's syntax %{variable|d3-time-format}, for example \"Day: %{2019-01-01|%A}\". https://github.com/d3/d3-time-format/tree/v2.2.3#locale_format for details on the date formatting syntax. The variables available in `hovertemplate` are the ones emitted as event data described at this link https://plotly.com/javascript/plotlyjs-events/#event-data. Additionally, every attributes that can be specified per-point (the ones that are `arrayOk: true`) are available. Anything contained in tag `` is displayed in the secondary box, for example \"{fullData.name}\". To hide the secondary box completely, use an empty tag ``.",
+ "dflt": "",
+ "editType": "none",
+ "valType": "string"
+ },
+ "hovertemplatesrc": {
+ "description": "Sets the source reference on Chart Studio Cloud for `hovertemplate`.",
+ "editType": "none",
+ "valType": "string"
+ },
+ "hovertext": {
+ "arrayOk": true,
+ "description": "Sets hover text elements associated with each (x,y) pair. If a single string, the same string appears over all the data points. If an array of string, the items are mapped in order to the this trace's (x,y) coordinates. To be seen, trace `hoverinfo` must contain a *text* flag.",
+ "dflt": "",
+ "editType": "style",
+ "valType": "string"
+ },
+ "hovertextsrc": {
+ "description": "Sets the source reference on Chart Studio Cloud for `hovertext`.",
+ "editType": "none",
+ "valType": "string"
+ },
+ "ids": {
+ "description": "Assigns id labels to each datum. These ids for object constancy of data points during animation. Should be an array of strings, not numbers or any other type.",
+ "editType": "calc",
+ "valType": "data_array"
+ },
+ "idssrc": {
+ "description": "Sets the source reference on Chart Studio Cloud for `ids`.",
+ "editType": "none",
+ "valType": "string"
+ },
+ "legendgroup": {
+ "description": "Sets the legend group for this trace. Traces part of the same legend group hide/show at the same time when toggling legend items.",
+ "dflt": "",
+ "editType": "style",
+ "valType": "string"
+ },
+ "legendgrouptitle": {
+ "editType": "style",
+ "font": {
+ "color": {
+ "editType": "style",
+ "valType": "color"
+ },
+ "description": "Sets this legend group's title font.",
+ "editType": "style",
+ "family": {
+ "description": "HTML font family - the typeface that will be applied by the web browser. The web browser will only be able to apply a font if it is available on the system which it operates. Provide multiple font families, separated by commas, to indicate the preference in which to apply fonts if they aren't available on the system. The Chart Studio Cloud (at https://chart-studio.plotly.com or on-premise) generates images on a server, where only a select number of fonts are installed and supported. These include *Arial*, *Balto*, *Courier New*, *Droid Sans*,, *Droid Serif*, *Droid Sans Mono*, *Gravitas One*, *Old Standard TT*, *Open Sans*, *Overpass*, *PT Sans Narrow*, *Raleway*, *Times New Roman*.",
+ "editType": "style",
+ "noBlank": true,
+ "strict": true,
+ "valType": "string"
+ },
+ "role": "object",
+ "size": {
+ "editType": "style",
+ "min": 1,
+ "valType": "number"
+ }
+ },
+ "role": "object",
+ "text": {
+ "description": "Sets the title of the legend group.",
+ "dflt": "",
+ "editType": "style",
+ "valType": "string"
+ }
+ },
+ "legendrank": {
+ "description": "Sets the legend rank for this trace. Items and groups with smaller ranks are presented on top/left side while with `*reversed* `legend.traceorder` they are on bottom/right side. The default legendrank is 1000, so that you can use ranks less than 1000 to place certain items before all unranked items, and ranks greater than 1000 to go after all unranked items.",
+ "dflt": 1000,
+ "editType": "style",
+ "valType": "number"
+ },
+ "line": {
+ "color": {
+ "description": "Sets the line color.",
+ "editType": "calc",
"valType": "color"
},
"dash": {
- "description": "Sets the dash style of lines. Set to a dash type string (*solid*, *dot*, *dash*, *longdash*, *dashdot*, or *longdashdot*) or a dash length list in px (eg *5px,10px,2px,2px*).",
+ "description": "Sets the style of the lines.",
"dflt": "solid",
- "editType": "style",
- "valType": "string",
+ "editType": "calc",
+ "valType": "enumerated",
"values": [
- "solid",
- "dot",
"dash",
- "longdash",
"dashdot",
- "longdashdot"
+ "dot",
+ "longdash",
+ "longdashdot",
+ "solid"
]
},
"editType": "calc",
"role": "object",
"shape": {
- "description": "Determines the line shape. With *spline* the lines are drawn using spline interpolation. The other available values correspond to step-wise line shapes.",
+ "description": "Determines the line shape. The values correspond to step-wise line shapes.",
"dflt": "linear",
- "editType": "plot",
+ "editType": "calc",
"valType": "enumerated",
"values": [
"linear",
- "spline"
+ "hv",
+ "vh",
+ "hvh",
+ "vhv"
]
},
- "smoothing": {
- "description": "Has an effect only if `shape` is set to *spline* Sets the amount of smoothing. *0* corresponds to no smoothing (equivalent to a *linear* shape).",
- "dflt": 1,
- "editType": "plot",
- "max": 1.3,
- "min": 0,
- "valType": "number"
- },
"width": {
"description": "Sets the line width (in px).",
"dflt": 2,
- "editType": "style",
+ "editType": "calc",
"min": 0,
"valType": "number"
}
@@ -52458,7 +54736,7 @@
"cmax": {
"description": "Sets the upper bound of the color domain. Has an effect only if in `marker.color`is set to a numerical array. Value should have the same units as in `marker.color` and if set, `marker.cmin` must be set as well.",
"dflt": null,
- "editType": "plot",
+ "editType": "calc",
"impliedEdits": {
"cauto": false
},
@@ -52474,7 +54752,7 @@
"cmin": {
"description": "Sets the lower bound of the color domain. Has an effect only if in `marker.color`is set to a numerical array. Value should have the same units as in `marker.color` and if set, `marker.cmax` must be set as well.",
"dflt": null,
- "editType": "plot",
+ "editType": "calc",
"impliedEdits": {
"cauto": false
},
@@ -52483,7 +54761,7 @@
"color": {
"arrayOk": true,
"description": "Sets themarkercolor. It accepts either a specific color or an array of numbers that are mapped to the colorscale relative to the max and min values of the array or relative to `marker.cmin` and `marker.cmax` if set.",
- "editType": "style",
+ "editType": "calc",
"valType": "color"
},
"coloraxis": {
@@ -52497,25 +54775,25 @@
"_deprecated": {
"title": {
"description": "Deprecated in favor of color bar's `title.text`. Note that value of color bar's `title` is no longer a simple *string* but a set of sub-attributes.",
- "editType": "colorbars",
+ "editType": "calc",
"valType": "string"
},
"titlefont": {
"color": {
- "editType": "colorbars",
+ "editType": "calc",
"valType": "color"
},
"description": "Deprecated in favor of color bar's `title.font`.",
- "editType": "colorbars",
+ "editType": "calc",
"family": {
"description": "HTML font family - the typeface that will be applied by the web browser. The web browser will only be able to apply a font if it is available on the system which it operates. Provide multiple font families, separated by commas, to indicate the preference in which to apply fonts if they aren't available on the system. The Chart Studio Cloud (at https://chart-studio.plotly.com or on-premise) generates images on a server, where only a select number of fonts are installed and supported. These include *Arial*, *Balto*, *Courier New*, *Droid Sans*,, *Droid Serif*, *Droid Sans Mono*, *Gravitas One*, *Old Standard TT*, *Open Sans*, *Overpass*, *PT Sans Narrow*, *Raleway*, *Times New Roman*.",
- "editType": "colorbars",
+ "editType": "calc",
"noBlank": true,
"strict": true,
"valType": "string"
},
"size": {
- "editType": "colorbars",
+ "editType": "calc",
"min": 1,
"valType": "number"
}
@@ -52523,7 +54801,7 @@
"titleside": {
"description": "Deprecated in favor of color bar's `title.side`.",
"dflt": "top",
- "editType": "colorbars",
+ "editType": "calc",
"valType": "enumerated",
"values": [
"right",
@@ -52535,35 +54813,35 @@
"bgcolor": {
"description": "Sets the color of padded area.",
"dflt": "rgba(0,0,0,0)",
- "editType": "colorbars",
+ "editType": "calc",
"valType": "color"
},
"bordercolor": {
"description": "Sets the axis line color.",
"dflt": "#444",
- "editType": "colorbars",
+ "editType": "calc",
"valType": "color"
},
"borderwidth": {
"description": "Sets the width (in px) or the border enclosing this color bar.",
"dflt": 0,
- "editType": "colorbars",
+ "editType": "calc",
"min": 0,
"valType": "number"
},
"dtick": {
"description": "Sets the step in-between ticks on this axis. Use with `tick0`. Must be a positive number, or special strings available to *log* and *date* axes. If the axis `type` is *log*, then ticks are set every 10^(n*dtick) where n is the tick number. For example, to set a tick mark at 1, 10, 100, 1000, ... set dtick to 1. To set tick marks at 1, 100, 10000, ... set dtick to 2. To set tick marks at 1, 5, 25, 125, 625, 3125, ... set dtick to log_10(5), or 0.69897000433. *log* has several special values; *L*, where `f` is a positive number, gives ticks linearly spaced in value (but not position). For example `tick0` = 0.1, `dtick` = *L0.5* will put ticks at 0.1, 0.6, 1.1, 1.6 etc. To show powers of 10 plus small digits between, use *D1* (all digits) or *D2* (only 2 and 5). `tick0` is ignored for *D1* and *D2*. If the axis `type` is *date*, then you must convert the time to milliseconds. For example, to set the interval between ticks to one day, set `dtick` to 86400000.0. *date* also has special values *M* gives ticks spaced by a number of months. `n` must be a positive integer. To set ticks on the 15th of every third month, set `tick0` to *2000-01-15* and `dtick` to *M3*. To set ticks every 4 years, set `dtick` to *M48*",
- "editType": "colorbars",
+ "editType": "calc",
"impliedEdits": {
"tickmode": "linear"
},
"valType": "any"
},
- "editType": "colorbars",
+ "editType": "calc",
"exponentformat": {
"description": "Determines a formatting rule for the tick exponents. For example, consider the number 1,000,000,000. If *none*, it appears as 1,000,000,000. If *e*, 1e+9. If *E*, 1E+9. If *power*, 1x10^9 (with 9 in a super script). If *SI*, 1G. If *B*, 1B.",
"dflt": "B",
- "editType": "colorbars",
+ "editType": "calc",
"valType": "enumerated",
"values": [
"none",
@@ -52577,14 +54855,14 @@
"len": {
"description": "Sets the length of the color bar This measure excludes the padding of both ends. That is, the color bar length is this length minus the padding on both ends.",
"dflt": 1,
- "editType": "colorbars",
+ "editType": "calc",
"min": 0,
"valType": "number"
},
"lenmode": {
"description": "Determines whether this color bar's length (i.e. the measure in the color variation direction) is set in units of plot *fraction* or in *pixels. Use `len` to set the value.",
"dflt": "fraction",
- "editType": "colorbars",
+ "editType": "calc",
"valType": "enumerated",
"values": [
"fraction",
@@ -52594,27 +54872,27 @@
"minexponent": {
"description": "Hide SI prefix for 10^n if |n| is below this number. This only has an effect when `tickformat` is *SI* or *B*.",
"dflt": 3,
- "editType": "colorbars",
+ "editType": "calc",
"min": 0,
"valType": "number"
},
"nticks": {
"description": "Specifies the maximum number of ticks for the particular axis. The actual number of ticks will be chosen automatically to be less than or equal to `nticks`. Has an effect only if `tickmode` is set to *auto*.",
"dflt": 0,
- "editType": "colorbars",
+ "editType": "calc",
"min": 0,
"valType": "integer"
},
"outlinecolor": {
"description": "Sets the axis line color.",
"dflt": "#444",
- "editType": "colorbars",
+ "editType": "calc",
"valType": "color"
},
"outlinewidth": {
"description": "Sets the width (in px) of the axis line.",
"dflt": 1,
- "editType": "colorbars",
+ "editType": "calc",
"min": 0,
"valType": "number"
},
@@ -52622,13 +54900,13 @@
"separatethousands": {
"description": "If \"true\", even 4-digit integers are separated",
"dflt": false,
- "editType": "colorbars",
+ "editType": "calc",
"valType": "boolean"
},
"showexponent": {
"description": "If *all*, all exponents are shown besides their significands. If *first*, only the exponent of the first tick is shown. If *last*, only the exponent of the last tick is shown. If *none*, no exponents appear.",
"dflt": "all",
- "editType": "colorbars",
+ "editType": "calc",
"valType": "enumerated",
"values": [
"all",
@@ -52640,13 +54918,13 @@
"showticklabels": {
"description": "Determines whether or not the tick labels are drawn.",
"dflt": true,
- "editType": "colorbars",
+ "editType": "calc",
"valType": "boolean"
},
"showtickprefix": {
"description": "If *all*, all tick labels are displayed with a prefix. If *first*, only the first tick is displayed with a prefix. If *last*, only the last tick is displayed with a suffix. If *none*, tick prefixes are hidden.",
"dflt": "all",
- "editType": "colorbars",
+ "editType": "calc",
"valType": "enumerated",
"values": [
"all",
@@ -52658,7 +54936,7 @@
"showticksuffix": {
"description": "Same as `showtickprefix` but for tick suffixes.",
"dflt": "all",
- "editType": "colorbars",
+ "editType": "calc",
"valType": "enumerated",
"values": [
"all",
@@ -52670,14 +54948,14 @@
"thickness": {
"description": "Sets the thickness of the color bar This measure excludes the size of the padding, ticks and labels.",
"dflt": 30,
- "editType": "colorbars",
+ "editType": "calc",
"min": 0,
"valType": "number"
},
"thicknessmode": {
"description": "Determines whether this color bar's thickness (i.e. the measure in the constant color direction) is set in units of plot *fraction* or in *pixels*. Use `thickness` to set the value.",
"dflt": "pixels",
- "editType": "colorbars",
+ "editType": "calc",
"valType": "enumerated",
"values": [
"fraction",
@@ -52686,7 +54964,7 @@
},
"tick0": {
"description": "Sets the placement of the first tick on this axis. Use with `dtick`. If the axis `type` is *log*, then you must take the log of your starting tick (e.g. to set the starting tick to 100, set the `tick0` to 2) except when `dtick`=*L* (see `dtick` for more info). If the axis `type` is *date*, it should be a date string, like date data. If the axis `type` is *category*, it should be a number, using the scale where each category is assigned a serial number from zero in the order it appears.",
- "editType": "colorbars",
+ "editType": "calc",
"impliedEdits": {
"tickmode": "linear"
},
@@ -52695,32 +54973,32 @@
"tickangle": {
"description": "Sets the angle of the tick labels with respect to the horizontal. For example, a `tickangle` of -90 draws the tick labels vertically.",
"dflt": "auto",
- "editType": "colorbars",
+ "editType": "calc",
"valType": "angle"
},
"tickcolor": {
"description": "Sets the tick color.",
"dflt": "#444",
- "editType": "colorbars",
+ "editType": "calc",
"valType": "color"
},
"tickfont": {
"color": {
- "editType": "colorbars",
+ "editType": "calc",
"valType": "color"
},
"description": "Sets the color bar's tick label font",
- "editType": "colorbars",
+ "editType": "calc",
"family": {
"description": "HTML font family - the typeface that will be applied by the web browser. The web browser will only be able to apply a font if it is available on the system which it operates. Provide multiple font families, separated by commas, to indicate the preference in which to apply fonts if they aren't available on the system. The Chart Studio Cloud (at https://chart-studio.plotly.com or on-premise) generates images on a server, where only a select number of fonts are installed and supported. These include *Arial*, *Balto*, *Courier New*, *Droid Sans*,, *Droid Serif*, *Droid Sans Mono*, *Gravitas One*, *Old Standard TT*, *Open Sans*, *Overpass*, *PT Sans Narrow*, *Raleway*, *Times New Roman*.",
- "editType": "colorbars",
+ "editType": "calc",
"noBlank": true,
"strict": true,
"valType": "string"
},
"role": "object",
"size": {
- "editType": "colorbars",
+ "editType": "calc",
"min": 1,
"valType": "number"
}
@@ -52728,7 +55006,7 @@
"tickformat": {
"description": "Sets the tick label formatting rule using d3 formatting mini-languages which are very similar to those in Python. For numbers, see: https://github.com/d3/d3-format/tree/v1.4.5#d3-format. And for dates see: https://github.com/d3/d3-time-format/tree/v2.2.3#locale_format. We add two items to d3's date formatter: *%h* for half of the year as a decimal number as well as *%{n}f* for fractional seconds with n digits. For example, *2016-10-13 09:15:23.456* with tickformat *%H~%M~%S.%2f* would display *09~15~23.46*",
"dflt": "",
- "editType": "colorbars",
+ "editType": "calc",
"valType": "string"
},
"tickformatstops": {
@@ -52736,41 +55014,41 @@
"tickformatstop": {
"dtickrange": {
"description": "range [*min*, *max*], where *min*, *max* - dtick values which describe some zoom level, it is possible to omit *min* or *max* value by passing *null*",
- "editType": "colorbars",
+ "editType": "calc",
"items": [
{
- "editType": "colorbars",
+ "editType": "calc",
"valType": "any"
},
{
- "editType": "colorbars",
+ "editType": "calc",
"valType": "any"
}
],
"valType": "info_array"
},
- "editType": "colorbars",
+ "editType": "calc",
"enabled": {
"description": "Determines whether or not this stop is used. If `false`, this stop is ignored even within its `dtickrange`.",
"dflt": true,
- "editType": "colorbars",
+ "editType": "calc",
"valType": "boolean"
},
"name": {
"description": "When used in a template, named items are created in the output figure in addition to any items the figure already has in this array. You can modify these items in the output figure by making your own item with `templateitemname` matching this `name` alongside your modifications (including `visible: false` or `enabled: false` to hide it). Has no effect outside of a template.",
- "editType": "colorbars",
+ "editType": "calc",
"valType": "string"
},
"role": "object",
"templateitemname": {
"description": "Used to refer to a named item in this array in the template. Named items from the template will be created even without a matching item in the input figure, but you can modify one by making an item with `templateitemname` matching its `name`, alongside your modifications (including `visible: false` or `enabled: false` to hide it). If there is no template or no matching item, this item will be hidden unless you explicitly show it with `visible: true`.",
- "editType": "colorbars",
+ "editType": "calc",
"valType": "string"
},
"value": {
"description": "string - dtickformat for described zoom level, the same as *tickformat*",
"dflt": "",
- "editType": "colorbars",
+ "editType": "calc",
"valType": "string"
}
}
@@ -52779,7 +55057,7 @@
},
"ticklabeloverflow": {
"description": "Determines how we handle tick labels that would overflow either the graph div or the domain of the axis. The default value for inside tick labels is *hide past domain*. In other cases the default is *hide past div*.",
- "editType": "colorbars",
+ "editType": "calc",
"valType": "enumerated",
"values": [
"allow",
@@ -52790,7 +55068,7 @@
"ticklabelposition": {
"description": "Determines where tick labels are drawn.",
"dflt": "outside",
- "editType": "colorbars",
+ "editType": "calc",
"valType": "enumerated",
"values": [
"outside",
@@ -52804,13 +55082,13 @@
"ticklen": {
"description": "Sets the tick length (in px).",
"dflt": 5,
- "editType": "colorbars",
+ "editType": "calc",
"min": 0,
"valType": "number"
},
"tickmode": {
"description": "Sets the tick mode for this axis. If *auto*, the number of ticks is set via `nticks`. If *linear*, the placement of the ticks is determined by a starting position `tick0` and a tick step `dtick` (*linear* is the default value if `tick0` and `dtick` are provided). If *array*, the placement of the ticks is set via `tickvals` and the tick text is `ticktext`. (*array* is the default value if `tickvals` is provided).",
- "editType": "colorbars",
+ "editType": "calc",
"impliedEdits": {},
"valType": "enumerated",
"values": [
@@ -52822,13 +55100,13 @@
"tickprefix": {
"description": "Sets a tick label prefix.",
"dflt": "",
- "editType": "colorbars",
+ "editType": "calc",
"valType": "string"
},
"ticks": {
"description": "Determines whether ticks are drawn or not. If **, this axis' ticks are not drawn. If *outside* (*inside*), this axis' are drawn outside (inside) the axis lines.",
"dflt": "",
- "editType": "colorbars",
+ "editType": "calc",
"valType": "enumerated",
"values": [
"outside",
@@ -52839,12 +55117,12 @@
"ticksuffix": {
"description": "Sets a tick label suffix.",
"dflt": "",
- "editType": "colorbars",
+ "editType": "calc",
"valType": "string"
},
"ticktext": {
"description": "Sets the text displayed at the ticks position via `tickvals`. Only has an effect if `tickmode` is set to *array*. Used with `tickvals`.",
- "editType": "colorbars",
+ "editType": "calc",
"valType": "data_array"
},
"ticktextsrc": {
@@ -52854,7 +55132,7 @@
},
"tickvals": {
"description": "Sets the values at which ticks on this axis appear. Only has an effect if `tickmode` is set to *array*. Used with `ticktext`.",
- "editType": "colorbars",
+ "editType": "calc",
"valType": "data_array"
},
"tickvalssrc": {
@@ -52865,29 +55143,29 @@
"tickwidth": {
"description": "Sets the tick width (in px).",
"dflt": 1,
- "editType": "colorbars",
+ "editType": "calc",
"min": 0,
"valType": "number"
},
"title": {
- "editType": "colorbars",
+ "editType": "calc",
"font": {
"color": {
- "editType": "colorbars",
+ "editType": "calc",
"valType": "color"
},
"description": "Sets this color bar's title font. Note that the title's font used to be set by the now deprecated `titlefont` attribute.",
- "editType": "colorbars",
+ "editType": "calc",
"family": {
"description": "HTML font family - the typeface that will be applied by the web browser. The web browser will only be able to apply a font if it is available on the system which it operates. Provide multiple font families, separated by commas, to indicate the preference in which to apply fonts if they aren't available on the system. The Chart Studio Cloud (at https://chart-studio.plotly.com or on-premise) generates images on a server, where only a select number of fonts are installed and supported. These include *Arial*, *Balto*, *Courier New*, *Droid Sans*,, *Droid Serif*, *Droid Sans Mono*, *Gravitas One*, *Old Standard TT*, *Open Sans*, *Overpass*, *PT Sans Narrow*, *Raleway*, *Times New Roman*.",
- "editType": "colorbars",
+ "editType": "calc",
"noBlank": true,
"strict": true,
"valType": "string"
},
"role": "object",
"size": {
- "editType": "colorbars",
+ "editType": "calc",
"min": 1,
"valType": "number"
}
@@ -52896,7 +55174,7 @@
"side": {
"description": "Determines the location of color bar's title with respect to the color bar. Note that the title's location used to be set by the now deprecated `titleside` attribute.",
"dflt": "top",
- "editType": "colorbars",
+ "editType": "calc",
"valType": "enumerated",
"values": [
"right",
@@ -52906,14 +55184,14 @@
},
"text": {
"description": "Sets the title of the color bar. Note that before the existence of `title.text`, the title's contents used to be defined as the `title` attribute itself. This behavior has been deprecated.",
- "editType": "colorbars",
+ "editType": "calc",
"valType": "string"
}
},
"x": {
"description": "Sets the x position of the color bar (in plot fraction).",
"dflt": 1.02,
- "editType": "colorbars",
+ "editType": "calc",
"max": 3,
"min": -2,
"valType": "number"
@@ -52921,7 +55199,7 @@
"xanchor": {
"description": "Sets this color bar's horizontal position anchor. This anchor binds the `x` position to the *left*, *center* or *right* of the color bar.",
"dflt": "left",
- "editType": "colorbars",
+ "editType": "calc",
"valType": "enumerated",
"values": [
"left",
@@ -52932,14 +55210,14 @@
"xpad": {
"description": "Sets the amount of padding (in px) along the x direction.",
"dflt": 10,
- "editType": "colorbars",
+ "editType": "calc",
"min": 0,
"valType": "number"
},
"y": {
"description": "Sets the y position of the color bar (in plot fraction).",
"dflt": 0.5,
- "editType": "colorbars",
+ "editType": "calc",
"max": 3,
"min": -2,
"valType": "number"
@@ -52947,7 +55225,7 @@
"yanchor": {
"description": "Sets this color bar's vertical position anchor This anchor binds the `y` position to the *top*, *middle* or *bottom* of the color bar.",
"dflt": "middle",
- "editType": "colorbars",
+ "editType": "calc",
"valType": "enumerated",
"values": [
"top",
@@ -52958,7 +55236,7 @@
"ypad": {
"description": "Sets the amount of padding (in px) along the y direction.",
"dflt": 10,
- "editType": "colorbars",
+ "editType": "calc",
"min": 0,
"valType": "number"
}
@@ -52978,39 +55256,6 @@
"valType": "string"
},
"editType": "calc",
- "gradient": {
- "color": {
- "arrayOk": true,
- "description": "Sets the final color of the gradient fill: the center color for radial, the right for horizontal, or the bottom for vertical.",
- "editType": "calc",
- "valType": "color"
- },
- "colorsrc": {
- "description": "Sets the source reference on Chart Studio Cloud for `color`.",
- "editType": "none",
- "valType": "string"
- },
- "editType": "calc",
- "role": "object",
- "type": {
- "arrayOk": true,
- "description": "Sets the type of gradient used to fill the markers",
- "dflt": "none",
- "editType": "calc",
- "valType": "enumerated",
- "values": [
- "radial",
- "horizontal",
- "vertical",
- "none"
- ]
- },
- "typesrc": {
- "description": "Sets the source reference on Chart Studio Cloud for `type`.",
- "editType": "none",
- "valType": "string"
- }
- },
"line": {
"autocolorscale": {
"description": "Determines whether the colorscale is a default palette (`autocolorscale: true`) or the palette determined by `marker.line.colorscale`. Has an effect only if in `marker.line.color`is set to a numerical array. In case `colorscale` is unspecified or `autocolorscale` is true, the default palette will be chosen according to whether numbers in the `color` array are all positive, all negative or mixed.",
@@ -53029,7 +55274,7 @@
"cmax": {
"description": "Sets the upper bound of the color domain. Has an effect only if in `marker.line.color`is set to a numerical array. Value should have the same units as in `marker.line.color` and if set, `marker.line.cmin` must be set as well.",
"dflt": null,
- "editType": "plot",
+ "editType": "calc",
"impliedEdits": {
"cauto": false
},
@@ -53045,7 +55290,7 @@
"cmin": {
"description": "Sets the lower bound of the color domain. Has an effect only if in `marker.line.color`is set to a numerical array. Value should have the same units as in `marker.line.color` and if set, `marker.line.cmax` must be set as well.",
"dflt": null,
- "editType": "plot",
+ "editType": "calc",
"impliedEdits": {
"cauto": false
},
@@ -53054,7 +55299,7 @@
"color": {
"arrayOk": true,
"description": "Sets themarker.linecolor. It accepts either a specific color or an array of numbers that are mapped to the colorscale relative to the max and min values of the array or relative to `marker.line.cmin` and `marker.line.cmax` if set.",
- "editType": "style",
+ "editType": "calc",
"valType": "color"
},
"coloraxis": {
@@ -53082,14 +55327,14 @@
"reversescale": {
"description": "Reverses the color mapping if true. Has an effect only if in `marker.line.color`is set to a numerical array. If true, `marker.line.cmin` will correspond to the last color in the array and `marker.line.cmax` will correspond to the first color.",
"dflt": false,
- "editType": "plot",
+ "editType": "calc",
"valType": "boolean"
},
"role": "object",
"width": {
"arrayOk": true,
"description": "Sets the width (in px) of the lines bounding the marker points.",
- "editType": "style",
+ "editType": "calc",
"min": 0,
"valType": "number"
},
@@ -53099,17 +55344,10 @@
"valType": "string"
}
},
- "maxdisplayed": {
- "description": "Sets a maximum number of points to be drawn on the graph. *0* corresponds to no limit.",
- "dflt": 0,
- "editType": "plot",
- "min": 0,
- "valType": "number"
- },
"opacity": {
"arrayOk": true,
"description": "Sets the marker opacity.",
- "editType": "style",
+ "editType": "calc",
"max": 1,
"min": 0,
"valType": "number"
@@ -53122,7 +55360,7 @@
"reversescale": {
"description": "Reverses the color mapping if true. Has an effect only if in `marker.color`is set to a numerical array. If true, `marker.cmin` will correspond to the last color in the array and `marker.cmax` will correspond to the first color.",
"dflt": false,
- "editType": "plot",
+ "editType": "calc",
"valType": "boolean"
},
"role": "object",
@@ -53172,7 +55410,7 @@
"arrayOk": true,
"description": "Sets the marker symbol type. Adding 100 is equivalent to appending *-open* to a symbol name. Adding 200 is equivalent to appending *-dot* to a symbol name. Adding 300 is equivalent to appending *-open-dot* or *dot-open* to a symbol name.",
"dflt": "circle",
- "editType": "style",
+ "editType": "calc",
"valType": "enumerated",
"values": [
0,
@@ -53791,7 +56029,7 @@
"textfont": {
"color": {
"arrayOk": true,
- "editType": "style",
+ "editType": "calc",
"valType": "color"
},
"colorsrc": {
@@ -53904,7 +56142,7 @@
},
"role": "object"
},
- "type": "scatterpolar",
+ "type": "scatterpolargl",
"uid": {
"description": "Assign an id to this trace, Use this to provide object constancy between traces during animations and transitions.",
"editType": "plot",
@@ -53963,20 +56201,28 @@
}
},
"categories": [
+ "gl",
+ "regl",
"polar",
"symbols",
"showLegend",
"scatter-like"
],
"meta": {
- "description": "The scatterpolar trace type encompasses line charts, scatter charts, text charts, and bubble charts in polar coordinates. The data visualized as scatter point or lines is set in `r` (radial) and `theta` (angular) coordinates Text (appearing either on the chart or on hover only) is via `text`. Bubble charts are achieved by setting `marker.size` and/or `marker.color` to numerical arrays.",
- "hrName": "scatter_polar"
+ "description": "The scatterpolargl trace type encompasses line charts, scatter charts, and bubble charts in polar coordinates using the WebGL plotting engine. The data visualized as scatter point or lines is set in `r` (radial) and `theta` (angular) coordinates Bubble charts are achieved by setting `marker.size` and/or `marker.color` to numerical arrays.",
+ "hrName": "scatter_polar_gl"
},
- "type": "scatterpolar"
+ "type": "scatterpolargl"
},
- "scatterpolargl": {
+ "scattersmith": {
"animatable": false,
"attributes": {
+ "cliponaxis": {
+ "description": "Determines whether or not markers and text nodes are clipped about the subplot axes. To show markers and text nodes above axis lines and tick labels, make sure to set `xaxis.layer` and `yaxis.layer` to *below traces*.",
+ "dflt": false,
+ "editType": "plot",
+ "valType": "boolean"
+ },
"connectgaps": {
"description": "Determines whether or not gaps (i.e. {nan} or missing values) in the provided data arrays are connected.",
"dflt": false,
@@ -53993,35 +56239,20 @@
"editType": "none",
"valType": "string"
},
- "dr": {
- "description": "Sets the r coordinate step.",
- "dflt": 1,
- "editType": "calc",
- "valType": "number"
- },
- "dtheta": {
- "description": "Sets the theta coordinate step. By default, the `dtheta` step equals the subplot's period divided by the length of the `r` coordinates.",
- "editType": "calc",
- "valType": "number"
- },
"fill": {
- "description": "Sets the area to fill with a solid color. Defaults to *none* unless this trace is stacked, then it gets *tonexty* (*tonextx*) if `orientation` is *v* (*h*) Use with `fillcolor` if not *none*. *tozerox* and *tozeroy* fill to x=0 and y=0 respectively. *tonextx* and *tonexty* fill between the endpoints of this trace and the endpoints of the trace before it, connecting those endpoints with straight lines (to make a stacked area graph); if there is no trace before it, they behave like *tozerox* and *tozeroy*. *toself* connects the endpoints of the trace (or each segment of the trace if it has gaps) into a closed shape. *tonext* fills the space between two traces if one completely encloses the other (eg consecutive contour lines), and behaves like *toself* if there is no trace before it. *tonext* should not be used if one trace does not enclose the other. Traces in a `stackgroup` will only fill to (or be filled to) other traces in the same group. With multiple `stackgroup`s or some traces stacked and some not, if fill-linked traces are not already consecutive, the later ones will be pushed down in the drawing order.",
+ "description": "Sets the area to fill with a solid color. Use with `fillcolor` if not *none*. scattersmith has a subset of the options available to scatter. *toself* connects the endpoints of the trace (or each segment of the trace if it has gaps) into a closed shape. *tonext* fills the space between two traces if one completely encloses the other (eg consecutive contour lines), and behaves like *toself* if there is no trace before it. *tonext* should not be used if one trace does not enclose the other.",
"dflt": "none",
"editType": "calc",
"valType": "enumerated",
"values": [
"none",
- "tozeroy",
- "tozerox",
- "tonexty",
- "tonextx",
"toself",
"tonext"
]
},
"fillcolor": {
"description": "Sets the fill color. Defaults to a half-transparent variant of the line color, marker color, or marker line color, whichever is available.",
- "editType": "calc",
+ "editType": "style",
"valType": "color"
},
"hoverinfo": {
@@ -54035,8 +56266,8 @@
"skip"
],
"flags": [
- "r",
- "theta",
+ "real",
+ "imag",
"text",
"name"
],
@@ -54142,6 +56373,15 @@
},
"role": "object"
},
+ "hoveron": {
+ "description": "Do the hover effects highlight individual points (markers or line points) or do they highlight filled regions? If the fill is *toself* or *tonext* and there are no markers or text, then the default is *fills*, otherwise it is *points*.",
+ "editType": "style",
+ "flags": [
+ "points",
+ "fills"
+ ],
+ "valType": "flaglist"
+ },
"hovertemplate": {
"arrayOk": true,
"description": "Template string used for rendering the information that appear on hover box. Note that this will override `hoverinfo`. Variables are inserted using %{variable}, for example \"y: %{y}\" as well as %{xother}, {%_xother}, {%_xother_}, {%xother_}. When showing info for several points, *xother* will be added to those with different x positions from the first point. An underscore before or after *(x|y)other* will add a space on that side, only when this field is shown. Numbers are formatted using d3-format's syntax %{variable:d3-format}, for example \"Price: %{y:$.2f}\". https://github.com/d3/d3-format/tree/v1.4.5#d3-format for details on the formatting syntax. Dates are formatted using d3-time-format's syntax %{variable|d3-time-format}, for example \"Day: %{2019-01-01|%A}\". https://github.com/d3/d3-time-format/tree/v2.2.3#locale_format for details on the date formatting syntax. The variables available in `hovertemplate` are the ones emitted as event data described at this link https://plotly.com/javascript/plotlyjs-events/#event-data. Additionally, every attributes that can be specified per-point (the ones that are `arrayOk: true`) are available. Anything contained in tag `` is displayed in the secondary box, for example \"{fullData.name}\". To hide the secondary box completely, use an empty tag ``.",
@@ -54176,6 +56416,16 @@
"editType": "none",
"valType": "string"
},
+ "imag": {
+ "description": "Sets the imaginary component of the data, in units of normalized impedance such that real=1, imag=0 is the center of the chart.",
+ "editType": "calc+clearAxisTypes",
+ "valType": "data_array"
+ },
+ "imagsrc": {
+ "description": "Sets the source reference on Chart Studio Cloud for `imag`.",
+ "editType": "none",
+ "valType": "string"
+ },
"legendgroup": {
"description": "Sets the legend group for this trace. Traces part of the same legend group hide/show at the same time when toggling legend items.",
"dflt": "",
@@ -54222,42 +56472,47 @@
"line": {
"color": {
"description": "Sets the line color.",
- "editType": "calc",
+ "editType": "style",
"valType": "color"
},
"dash": {
- "description": "Sets the style of the lines.",
+ "description": "Sets the dash style of lines. Set to a dash type string (*solid*, *dot*, *dash*, *longdash*, *dashdot*, or *longdashdot*) or a dash length list in px (eg *5px,10px,2px,2px*).",
"dflt": "solid",
- "editType": "calc",
- "valType": "enumerated",
+ "editType": "style",
+ "valType": "string",
"values": [
- "dash",
- "dashdot",
+ "solid",
"dot",
+ "dash",
"longdash",
- "longdashdot",
- "solid"
+ "dashdot",
+ "longdashdot"
]
},
"editType": "calc",
"role": "object",
"shape": {
- "description": "Determines the line shape. The values correspond to step-wise line shapes.",
+ "description": "Determines the line shape. With *spline* the lines are drawn using spline interpolation. The other available values correspond to step-wise line shapes.",
"dflt": "linear",
- "editType": "calc",
+ "editType": "plot",
"valType": "enumerated",
"values": [
"linear",
- "hv",
- "vh",
- "hvh",
- "vhv"
+ "spline"
]
},
+ "smoothing": {
+ "description": "Has an effect only if `shape` is set to *spline* Sets the amount of smoothing. *0* corresponds to no smoothing (equivalent to a *linear* shape).",
+ "dflt": 1,
+ "editType": "plot",
+ "max": 1.3,
+ "min": 0,
+ "valType": "number"
+ },
"width": {
"description": "Sets the line width (in px).",
"dflt": 2,
- "editType": "calc",
+ "editType": "style",
"min": 0,
"valType": "number"
}
@@ -54280,7 +56535,7 @@
"cmax": {
"description": "Sets the upper bound of the color domain. Has an effect only if in `marker.color`is set to a numerical array. Value should have the same units as in `marker.color` and if set, `marker.cmin` must be set as well.",
"dflt": null,
- "editType": "calc",
+ "editType": "plot",
"impliedEdits": {
"cauto": false
},
@@ -54296,7 +56551,7 @@
"cmin": {
"description": "Sets the lower bound of the color domain. Has an effect only if in `marker.color`is set to a numerical array. Value should have the same units as in `marker.color` and if set, `marker.cmax` must be set as well.",
"dflt": null,
- "editType": "calc",
+ "editType": "plot",
"impliedEdits": {
"cauto": false
},
@@ -54305,7 +56560,7 @@
"color": {
"arrayOk": true,
"description": "Sets themarkercolor. It accepts either a specific color or an array of numbers that are mapped to the colorscale relative to the max and min values of the array or relative to `marker.cmin` and `marker.cmax` if set.",
- "editType": "calc",
+ "editType": "style",
"valType": "color"
},
"coloraxis": {
@@ -54319,25 +56574,25 @@
"_deprecated": {
"title": {
"description": "Deprecated in favor of color bar's `title.text`. Note that value of color bar's `title` is no longer a simple *string* but a set of sub-attributes.",
- "editType": "calc",
+ "editType": "colorbars",
"valType": "string"
},
"titlefont": {
"color": {
- "editType": "calc",
+ "editType": "colorbars",
"valType": "color"
},
"description": "Deprecated in favor of color bar's `title.font`.",
- "editType": "calc",
+ "editType": "colorbars",
"family": {
"description": "HTML font family - the typeface that will be applied by the web browser. The web browser will only be able to apply a font if it is available on the system which it operates. Provide multiple font families, separated by commas, to indicate the preference in which to apply fonts if they aren't available on the system. The Chart Studio Cloud (at https://chart-studio.plotly.com or on-premise) generates images on a server, where only a select number of fonts are installed and supported. These include *Arial*, *Balto*, *Courier New*, *Droid Sans*,, *Droid Serif*, *Droid Sans Mono*, *Gravitas One*, *Old Standard TT*, *Open Sans*, *Overpass*, *PT Sans Narrow*, *Raleway*, *Times New Roman*.",
- "editType": "calc",
+ "editType": "colorbars",
"noBlank": true,
"strict": true,
"valType": "string"
},
"size": {
- "editType": "calc",
+ "editType": "colorbars",
"min": 1,
"valType": "number"
}
@@ -54345,7 +56600,7 @@
"titleside": {
"description": "Deprecated in favor of color bar's `title.side`.",
"dflt": "top",
- "editType": "calc",
+ "editType": "colorbars",
"valType": "enumerated",
"values": [
"right",
@@ -54357,35 +56612,35 @@
"bgcolor": {
"description": "Sets the color of padded area.",
"dflt": "rgba(0,0,0,0)",
- "editType": "calc",
+ "editType": "colorbars",
"valType": "color"
},
"bordercolor": {
"description": "Sets the axis line color.",
"dflt": "#444",
- "editType": "calc",
+ "editType": "colorbars",
"valType": "color"
},
"borderwidth": {
"description": "Sets the width (in px) or the border enclosing this color bar.",
"dflt": 0,
- "editType": "calc",
+ "editType": "colorbars",
"min": 0,
"valType": "number"
},
"dtick": {
"description": "Sets the step in-between ticks on this axis. Use with `tick0`. Must be a positive number, or special strings available to *log* and *date* axes. If the axis `type` is *log*, then ticks are set every 10^(n*dtick) where n is the tick number. For example, to set a tick mark at 1, 10, 100, 1000, ... set dtick to 1. To set tick marks at 1, 100, 10000, ... set dtick to 2. To set tick marks at 1, 5, 25, 125, 625, 3125, ... set dtick to log_10(5), or 0.69897000433. *log* has several special values; *L*, where `f` is a positive number, gives ticks linearly spaced in value (but not position). For example `tick0` = 0.1, `dtick` = *L0.5* will put ticks at 0.1, 0.6, 1.1, 1.6 etc. To show powers of 10 plus small digits between, use *D1* (all digits) or *D2* (only 2 and 5). `tick0` is ignored for *D1* and *D2*. If the axis `type` is *date*, then you must convert the time to milliseconds. For example, to set the interval between ticks to one day, set `dtick` to 86400000.0. *date* also has special values *M* gives ticks spaced by a number of months. `n` must be a positive integer. To set ticks on the 15th of every third month, set `tick0` to *2000-01-15* and `dtick` to *M3*. To set ticks every 4 years, set `dtick` to *M48*",
- "editType": "calc",
+ "editType": "colorbars",
"impliedEdits": {
"tickmode": "linear"
},
"valType": "any"
},
- "editType": "calc",
+ "editType": "colorbars",
"exponentformat": {
"description": "Determines a formatting rule for the tick exponents. For example, consider the number 1,000,000,000. If *none*, it appears as 1,000,000,000. If *e*, 1e+9. If *E*, 1E+9. If *power*, 1x10^9 (with 9 in a super script). If *SI*, 1G. If *B*, 1B.",
"dflt": "B",
- "editType": "calc",
+ "editType": "colorbars",
"valType": "enumerated",
"values": [
"none",
@@ -54399,14 +56654,14 @@
"len": {
"description": "Sets the length of the color bar This measure excludes the padding of both ends. That is, the color bar length is this length minus the padding on both ends.",
"dflt": 1,
- "editType": "calc",
+ "editType": "colorbars",
"min": 0,
"valType": "number"
},
"lenmode": {
"description": "Determines whether this color bar's length (i.e. the measure in the color variation direction) is set in units of plot *fraction* or in *pixels. Use `len` to set the value.",
"dflt": "fraction",
- "editType": "calc",
+ "editType": "colorbars",
"valType": "enumerated",
"values": [
"fraction",
@@ -54416,27 +56671,27 @@
"minexponent": {
"description": "Hide SI prefix for 10^n if |n| is below this number. This only has an effect when `tickformat` is *SI* or *B*.",
"dflt": 3,
- "editType": "calc",
+ "editType": "colorbars",
"min": 0,
"valType": "number"
},
"nticks": {
"description": "Specifies the maximum number of ticks for the particular axis. The actual number of ticks will be chosen automatically to be less than or equal to `nticks`. Has an effect only if `tickmode` is set to *auto*.",
"dflt": 0,
- "editType": "calc",
+ "editType": "colorbars",
"min": 0,
"valType": "integer"
},
"outlinecolor": {
"description": "Sets the axis line color.",
"dflt": "#444",
- "editType": "calc",
+ "editType": "colorbars",
"valType": "color"
},
"outlinewidth": {
"description": "Sets the width (in px) of the axis line.",
"dflt": 1,
- "editType": "calc",
+ "editType": "colorbars",
"min": 0,
"valType": "number"
},
@@ -54444,13 +56699,13 @@
"separatethousands": {
"description": "If \"true\", even 4-digit integers are separated",
"dflt": false,
- "editType": "calc",
+ "editType": "colorbars",
"valType": "boolean"
},
"showexponent": {
"description": "If *all*, all exponents are shown besides their significands. If *first*, only the exponent of the first tick is shown. If *last*, only the exponent of the last tick is shown. If *none*, no exponents appear.",
"dflt": "all",
- "editType": "calc",
+ "editType": "colorbars",
"valType": "enumerated",
"values": [
"all",
@@ -54462,13 +56717,13 @@
"showticklabels": {
"description": "Determines whether or not the tick labels are drawn.",
"dflt": true,
- "editType": "calc",
+ "editType": "colorbars",
"valType": "boolean"
},
"showtickprefix": {
"description": "If *all*, all tick labels are displayed with a prefix. If *first*, only the first tick is displayed with a prefix. If *last*, only the last tick is displayed with a suffix. If *none*, tick prefixes are hidden.",
"dflt": "all",
- "editType": "calc",
+ "editType": "colorbars",
"valType": "enumerated",
"values": [
"all",
@@ -54480,7 +56735,7 @@
"showticksuffix": {
"description": "Same as `showtickprefix` but for tick suffixes.",
"dflt": "all",
- "editType": "calc",
+ "editType": "colorbars",
"valType": "enumerated",
"values": [
"all",
@@ -54492,14 +56747,14 @@
"thickness": {
"description": "Sets the thickness of the color bar This measure excludes the size of the padding, ticks and labels.",
"dflt": 30,
- "editType": "calc",
+ "editType": "colorbars",
"min": 0,
"valType": "number"
},
"thicknessmode": {
"description": "Determines whether this color bar's thickness (i.e. the measure in the constant color direction) is set in units of plot *fraction* or in *pixels*. Use `thickness` to set the value.",
"dflt": "pixels",
- "editType": "calc",
+ "editType": "colorbars",
"valType": "enumerated",
"values": [
"fraction",
@@ -54508,7 +56763,7 @@
},
"tick0": {
"description": "Sets the placement of the first tick on this axis. Use with `dtick`. If the axis `type` is *log*, then you must take the log of your starting tick (e.g. to set the starting tick to 100, set the `tick0` to 2) except when `dtick`=*L* (see `dtick` for more info). If the axis `type` is *date*, it should be a date string, like date data. If the axis `type` is *category*, it should be a number, using the scale where each category is assigned a serial number from zero in the order it appears.",
- "editType": "calc",
+ "editType": "colorbars",
"impliedEdits": {
"tickmode": "linear"
},
@@ -54517,32 +56772,32 @@
"tickangle": {
"description": "Sets the angle of the tick labels with respect to the horizontal. For example, a `tickangle` of -90 draws the tick labels vertically.",
"dflt": "auto",
- "editType": "calc",
+ "editType": "colorbars",
"valType": "angle"
},
"tickcolor": {
"description": "Sets the tick color.",
"dflt": "#444",
- "editType": "calc",
+ "editType": "colorbars",
"valType": "color"
},
"tickfont": {
"color": {
- "editType": "calc",
+ "editType": "colorbars",
"valType": "color"
},
"description": "Sets the color bar's tick label font",
- "editType": "calc",
+ "editType": "colorbars",
"family": {
"description": "HTML font family - the typeface that will be applied by the web browser. The web browser will only be able to apply a font if it is available on the system which it operates. Provide multiple font families, separated by commas, to indicate the preference in which to apply fonts if they aren't available on the system. The Chart Studio Cloud (at https://chart-studio.plotly.com or on-premise) generates images on a server, where only a select number of fonts are installed and supported. These include *Arial*, *Balto*, *Courier New*, *Droid Sans*,, *Droid Serif*, *Droid Sans Mono*, *Gravitas One*, *Old Standard TT*, *Open Sans*, *Overpass*, *PT Sans Narrow*, *Raleway*, *Times New Roman*.",
- "editType": "calc",
+ "editType": "colorbars",
"noBlank": true,
"strict": true,
"valType": "string"
},
"role": "object",
"size": {
- "editType": "calc",
+ "editType": "colorbars",
"min": 1,
"valType": "number"
}
@@ -54550,7 +56805,7 @@
"tickformat": {
"description": "Sets the tick label formatting rule using d3 formatting mini-languages which are very similar to those in Python. For numbers, see: https://github.com/d3/d3-format/tree/v1.4.5#d3-format. And for dates see: https://github.com/d3/d3-time-format/tree/v2.2.3#locale_format. We add two items to d3's date formatter: *%h* for half of the year as a decimal number as well as *%{n}f* for fractional seconds with n digits. For example, *2016-10-13 09:15:23.456* with tickformat *%H~%M~%S.%2f* would display *09~15~23.46*",
"dflt": "",
- "editType": "calc",
+ "editType": "colorbars",
"valType": "string"
},
"tickformatstops": {
@@ -54558,41 +56813,41 @@
"tickformatstop": {
"dtickrange": {
"description": "range [*min*, *max*], where *min*, *max* - dtick values which describe some zoom level, it is possible to omit *min* or *max* value by passing *null*",
- "editType": "calc",
+ "editType": "colorbars",
"items": [
{
- "editType": "calc",
+ "editType": "colorbars",
"valType": "any"
},
{
- "editType": "calc",
+ "editType": "colorbars",
"valType": "any"
}
],
"valType": "info_array"
},
- "editType": "calc",
+ "editType": "colorbars",
"enabled": {
"description": "Determines whether or not this stop is used. If `false`, this stop is ignored even within its `dtickrange`.",
"dflt": true,
- "editType": "calc",
+ "editType": "colorbars",
"valType": "boolean"
},
"name": {
"description": "When used in a template, named items are created in the output figure in addition to any items the figure already has in this array. You can modify these items in the output figure by making your own item with `templateitemname` matching this `name` alongside your modifications (including `visible: false` or `enabled: false` to hide it). Has no effect outside of a template.",
- "editType": "calc",
+ "editType": "colorbars",
"valType": "string"
},
"role": "object",
"templateitemname": {
"description": "Used to refer to a named item in this array in the template. Named items from the template will be created even without a matching item in the input figure, but you can modify one by making an item with `templateitemname` matching its `name`, alongside your modifications (including `visible: false` or `enabled: false` to hide it). If there is no template or no matching item, this item will be hidden unless you explicitly show it with `visible: true`.",
- "editType": "calc",
+ "editType": "colorbars",
"valType": "string"
},
"value": {
"description": "string - dtickformat for described zoom level, the same as *tickformat*",
"dflt": "",
- "editType": "calc",
+ "editType": "colorbars",
"valType": "string"
}
}
@@ -54601,7 +56856,7 @@
},
"ticklabeloverflow": {
"description": "Determines how we handle tick labels that would overflow either the graph div or the domain of the axis. The default value for inside tick labels is *hide past domain*. In other cases the default is *hide past div*.",
- "editType": "calc",
+ "editType": "colorbars",
"valType": "enumerated",
"values": [
"allow",
@@ -54612,7 +56867,7 @@
"ticklabelposition": {
"description": "Determines where tick labels are drawn.",
"dflt": "outside",
- "editType": "calc",
+ "editType": "colorbars",
"valType": "enumerated",
"values": [
"outside",
@@ -54626,13 +56881,13 @@
"ticklen": {
"description": "Sets the tick length (in px).",
"dflt": 5,
- "editType": "calc",
+ "editType": "colorbars",
"min": 0,
"valType": "number"
},
"tickmode": {
"description": "Sets the tick mode for this axis. If *auto*, the number of ticks is set via `nticks`. If *linear*, the placement of the ticks is determined by a starting position `tick0` and a tick step `dtick` (*linear* is the default value if `tick0` and `dtick` are provided). If *array*, the placement of the ticks is set via `tickvals` and the tick text is `ticktext`. (*array* is the default value if `tickvals` is provided).",
- "editType": "calc",
+ "editType": "colorbars",
"impliedEdits": {},
"valType": "enumerated",
"values": [
@@ -54644,13 +56899,13 @@
"tickprefix": {
"description": "Sets a tick label prefix.",
"dflt": "",
- "editType": "calc",
+ "editType": "colorbars",
"valType": "string"
},
"ticks": {
"description": "Determines whether ticks are drawn or not. If **, this axis' ticks are not drawn. If *outside* (*inside*), this axis' are drawn outside (inside) the axis lines.",
"dflt": "",
- "editType": "calc",
+ "editType": "colorbars",
"valType": "enumerated",
"values": [
"outside",
@@ -54661,12 +56916,12 @@
"ticksuffix": {
"description": "Sets a tick label suffix.",
"dflt": "",
- "editType": "calc",
+ "editType": "colorbars",
"valType": "string"
},
"ticktext": {
"description": "Sets the text displayed at the ticks position via `tickvals`. Only has an effect if `tickmode` is set to *array*. Used with `tickvals`.",
- "editType": "calc",
+ "editType": "colorbars",
"valType": "data_array"
},
"ticktextsrc": {
@@ -54676,7 +56931,7 @@
},
"tickvals": {
"description": "Sets the values at which ticks on this axis appear. Only has an effect if `tickmode` is set to *array*. Used with `ticktext`.",
- "editType": "calc",
+ "editType": "colorbars",
"valType": "data_array"
},
"tickvalssrc": {
@@ -54687,29 +56942,29 @@
"tickwidth": {
"description": "Sets the tick width (in px).",
"dflt": 1,
- "editType": "calc",
+ "editType": "colorbars",
"min": 0,
"valType": "number"
},
"title": {
- "editType": "calc",
+ "editType": "colorbars",
"font": {
"color": {
- "editType": "calc",
+ "editType": "colorbars",
"valType": "color"
},
"description": "Sets this color bar's title font. Note that the title's font used to be set by the now deprecated `titlefont` attribute.",
- "editType": "calc",
+ "editType": "colorbars",
"family": {
"description": "HTML font family - the typeface that will be applied by the web browser. The web browser will only be able to apply a font if it is available on the system which it operates. Provide multiple font families, separated by commas, to indicate the preference in which to apply fonts if they aren't available on the system. The Chart Studio Cloud (at https://chart-studio.plotly.com or on-premise) generates images on a server, where only a select number of fonts are installed and supported. These include *Arial*, *Balto*, *Courier New*, *Droid Sans*,, *Droid Serif*, *Droid Sans Mono*, *Gravitas One*, *Old Standard TT*, *Open Sans*, *Overpass*, *PT Sans Narrow*, *Raleway*, *Times New Roman*.",
- "editType": "calc",
+ "editType": "colorbars",
"noBlank": true,
"strict": true,
"valType": "string"
},
"role": "object",
"size": {
- "editType": "calc",
+ "editType": "colorbars",
"min": 1,
"valType": "number"
}
@@ -54718,7 +56973,7 @@
"side": {
"description": "Determines the location of color bar's title with respect to the color bar. Note that the title's location used to be set by the now deprecated `titleside` attribute.",
"dflt": "top",
- "editType": "calc",
+ "editType": "colorbars",
"valType": "enumerated",
"values": [
"right",
@@ -54728,14 +56983,14 @@
},
"text": {
"description": "Sets the title of the color bar. Note that before the existence of `title.text`, the title's contents used to be defined as the `title` attribute itself. This behavior has been deprecated.",
- "editType": "calc",
+ "editType": "colorbars",
"valType": "string"
}
},
"x": {
"description": "Sets the x position of the color bar (in plot fraction).",
"dflt": 1.02,
- "editType": "calc",
+ "editType": "colorbars",
"max": 3,
"min": -2,
"valType": "number"
@@ -54743,7 +56998,7 @@
"xanchor": {
"description": "Sets this color bar's horizontal position anchor. This anchor binds the `x` position to the *left*, *center* or *right* of the color bar.",
"dflt": "left",
- "editType": "calc",
+ "editType": "colorbars",
"valType": "enumerated",
"values": [
"left",
@@ -54754,14 +57009,14 @@
"xpad": {
"description": "Sets the amount of padding (in px) along the x direction.",
"dflt": 10,
- "editType": "calc",
+ "editType": "colorbars",
"min": 0,
"valType": "number"
},
"y": {
"description": "Sets the y position of the color bar (in plot fraction).",
"dflt": 0.5,
- "editType": "calc",
+ "editType": "colorbars",
"max": 3,
"min": -2,
"valType": "number"
@@ -54769,7 +57024,7 @@
"yanchor": {
"description": "Sets this color bar's vertical position anchor This anchor binds the `y` position to the *top*, *middle* or *bottom* of the color bar.",
"dflt": "middle",
- "editType": "calc",
+ "editType": "colorbars",
"valType": "enumerated",
"values": [
"top",
@@ -54780,7 +57035,7 @@
"ypad": {
"description": "Sets the amount of padding (in px) along the y direction.",
"dflt": 10,
- "editType": "calc",
+ "editType": "colorbars",
"min": 0,
"valType": "number"
}
@@ -54800,6 +57055,39 @@
"valType": "string"
},
"editType": "calc",
+ "gradient": {
+ "color": {
+ "arrayOk": true,
+ "description": "Sets the final color of the gradient fill: the center color for radial, the right for horizontal, or the bottom for vertical.",
+ "editType": "calc",
+ "valType": "color"
+ },
+ "colorsrc": {
+ "description": "Sets the source reference on Chart Studio Cloud for `color`.",
+ "editType": "none",
+ "valType": "string"
+ },
+ "editType": "calc",
+ "role": "object",
+ "type": {
+ "arrayOk": true,
+ "description": "Sets the type of gradient used to fill the markers",
+ "dflt": "none",
+ "editType": "calc",
+ "valType": "enumerated",
+ "values": [
+ "radial",
+ "horizontal",
+ "vertical",
+ "none"
+ ]
+ },
+ "typesrc": {
+ "description": "Sets the source reference on Chart Studio Cloud for `type`.",
+ "editType": "none",
+ "valType": "string"
+ }
+ },
"line": {
"autocolorscale": {
"description": "Determines whether the colorscale is a default palette (`autocolorscale: true`) or the palette determined by `marker.line.colorscale`. Has an effect only if in `marker.line.color`is set to a numerical array. In case `colorscale` is unspecified or `autocolorscale` is true, the default palette will be chosen according to whether numbers in the `color` array are all positive, all negative or mixed.",
@@ -54818,7 +57106,7 @@
"cmax": {
"description": "Sets the upper bound of the color domain. Has an effect only if in `marker.line.color`is set to a numerical array. Value should have the same units as in `marker.line.color` and if set, `marker.line.cmin` must be set as well.",
"dflt": null,
- "editType": "calc",
+ "editType": "plot",
"impliedEdits": {
"cauto": false
},
@@ -54834,7 +57122,7 @@
"cmin": {
"description": "Sets the lower bound of the color domain. Has an effect only if in `marker.line.color`is set to a numerical array. Value should have the same units as in `marker.line.color` and if set, `marker.line.cmax` must be set as well.",
"dflt": null,
- "editType": "calc",
+ "editType": "plot",
"impliedEdits": {
"cauto": false
},
@@ -54843,7 +57131,7 @@
"color": {
"arrayOk": true,
"description": "Sets themarker.linecolor. It accepts either a specific color or an array of numbers that are mapped to the colorscale relative to the max and min values of the array or relative to `marker.line.cmin` and `marker.line.cmax` if set.",
- "editType": "calc",
+ "editType": "style",
"valType": "color"
},
"coloraxis": {
@@ -54871,14 +57159,14 @@
"reversescale": {
"description": "Reverses the color mapping if true. Has an effect only if in `marker.line.color`is set to a numerical array. If true, `marker.line.cmin` will correspond to the last color in the array and `marker.line.cmax` will correspond to the first color.",
"dflt": false,
- "editType": "calc",
+ "editType": "plot",
"valType": "boolean"
},
"role": "object",
"width": {
"arrayOk": true,
"description": "Sets the width (in px) of the lines bounding the marker points.",
- "editType": "calc",
+ "editType": "style",
"min": 0,
"valType": "number"
},
@@ -54888,10 +57176,17 @@
"valType": "string"
}
},
+ "maxdisplayed": {
+ "description": "Sets a maximum number of points to be drawn on the graph. *0* corresponds to no limit.",
+ "dflt": 0,
+ "editType": "plot",
+ "min": 0,
+ "valType": "number"
+ },
"opacity": {
"arrayOk": true,
"description": "Sets the marker opacity.",
- "editType": "calc",
+ "editType": "style",
"max": 1,
"min": 0,
"valType": "number"
@@ -54904,7 +57199,7 @@
"reversescale": {
"description": "Reverses the color mapping if true. Has an effect only if in `marker.color`is set to a numerical array. If true, `marker.cmin` will correspond to the last color in the array and `marker.cmax` will correspond to the first color.",
"dflt": false,
- "editType": "calc",
+ "editType": "plot",
"valType": "boolean"
},
"role": "object",
@@ -54954,7 +57249,7 @@
"arrayOk": true,
"description": "Sets the marker symbol type. Adding 100 is equivalent to appending *-open* to a symbol name. Adding 200 is equivalent to appending *-dot* to a symbol name. Adding 300 is equivalent to appending *-open-dot* or *dot-open* to a symbol name.",
"dflt": "circle",
- "editType": "calc",
+ "editType": "style",
"valType": "enumerated",
"values": [
0,
@@ -55476,19 +57771,13 @@
"min": 0,
"valType": "number"
},
- "r": {
- "description": "Sets the radial coordinates",
+ "real": {
+ "description": "Sets the real component of the data, in units of normalized impedance such that real=1, imag=0 is the center of the chart.",
"editType": "calc+clearAxisTypes",
"valType": "data_array"
},
- "r0": {
- "description": "Alternate to `r`. Builds a linear space of r coordinates. Use with `dr` where `r0` is the starting coordinate and `dr` the step.",
- "dflt": 0,
- "editType": "calc+clearAxisTypes",
- "valType": "any"
- },
- "rsrc": {
- "description": "Sets the source reference on Chart Studio Cloud for `r`.",
+ "realsrc": {
+ "description": "Sets the source reference on Chart Studio Cloud for `real`.",
"editType": "none",
"valType": "string"
},
@@ -55558,8 +57847,8 @@
}
},
"subplot": {
- "description": "Sets a reference between this trace's data coordinates and a polar subplot. If *polar* (the default value), the data refer to `layout.polar`. If *polar2*, the data refer to `layout.polar2`, and so on.",
- "dflt": "polar",
+ "description": "Sets a reference between this trace's data coordinates and a smith subplot. If *smith* (the default value), the data refer to `layout.smith`. If *smith2*, the data refer to `layout.smith2`, and so on.",
+ "dflt": "smith",
"editType": "calc",
"valType": "subplotid"
},
@@ -55573,7 +57862,7 @@
"textfont": {
"color": {
"arrayOk": true,
- "editType": "calc",
+ "editType": "style",
"valType": "color"
},
"colorsrc": {
@@ -55639,7 +57928,7 @@
},
"texttemplate": {
"arrayOk": true,
- "description": "Template string used for rendering the information text that appear on points. Note that this will override `textinfo`. Variables are inserted using %{variable}, for example \"y: %{y}\". Numbers are formatted using d3-format's syntax %{variable:d3-format}, for example \"Price: %{y:$.2f}\". https://github.com/d3/d3-format/tree/v1.4.5#d3-format for details on the formatting syntax. Dates are formatted using d3-time-format's syntax %{variable|d3-time-format}, for example \"Day: %{2019-01-01|%A}\". https://github.com/d3/d3-time-format/tree/v2.2.3#locale_format for details on the date formatting syntax. Every attributes that can be specified per-point (the ones that are `arrayOk: true`) are available. variables `r`, `theta` and `text`.",
+ "description": "Template string used for rendering the information text that appear on points. Note that this will override `textinfo`. Variables are inserted using %{variable}, for example \"y: %{y}\". Numbers are formatted using d3-format's syntax %{variable:d3-format}, for example \"Price: %{y:$.2f}\". https://github.com/d3/d3-format/tree/v1.4.5#d3-format for details on the formatting syntax. Dates are formatted using d3-time-format's syntax %{variable|d3-time-format}, for example \"Day: %{2019-01-01|%A}\". https://github.com/d3/d3-time-format/tree/v2.2.3#locale_format for details on the date formatting syntax. Every attributes that can be specified per-point (the ones that are `arrayOk: true`) are available. variables `real`, `imag` and `text`.",
"dflt": "",
"editType": "plot",
"valType": "string"
@@ -55649,33 +57938,6 @@
"editType": "none",
"valType": "string"
},
- "theta": {
- "description": "Sets the angular coordinates",
- "editType": "calc+clearAxisTypes",
- "valType": "data_array"
- },
- "theta0": {
- "description": "Alternate to `theta`. Builds a linear space of theta coordinates. Use with `dtheta` where `theta0` is the starting coordinate and `dtheta` the step.",
- "dflt": 0,
- "editType": "calc+clearAxisTypes",
- "valType": "any"
- },
- "thetasrc": {
- "description": "Sets the source reference on Chart Studio Cloud for `theta`.",
- "editType": "none",
- "valType": "string"
- },
- "thetaunit": {
- "description": "Sets the unit of input *theta* values. Has an effect only when on *linear* angular axes.",
- "dflt": "degrees",
- "editType": "calc+clearAxisTypes",
- "valType": "enumerated",
- "values": [
- "radians",
- "degrees",
- "gradians"
- ]
- },
"transforms": {
"items": {
"transform": {
@@ -55686,7 +57948,7 @@
},
"role": "object"
},
- "type": "scatterpolargl",
+ "type": "scattersmith",
"uid": {
"description": "Assign an id to this trace, Use this to provide object constancy between traces during animations and transitions.",
"editType": "plot",
@@ -55745,18 +58007,16 @@
}
},
"categories": [
- "gl",
- "regl",
- "polar",
+ "smith",
"symbols",
"showLegend",
"scatter-like"
],
"meta": {
- "description": "The scatterpolargl trace type encompasses line charts, scatter charts, and bubble charts in polar coordinates using the WebGL plotting engine. The data visualized as scatter point or lines is set in `r` (radial) and `theta` (angular) coordinates Bubble charts are achieved by setting `marker.size` and/or `marker.color` to numerical arrays.",
- "hrName": "scatter_polar_gl"
+ "description": "The scattersmith trace type encompasses line charts, scatter charts, text charts, and bubble charts in smith coordinates. The data visualized as scatter point or lines is set in `real` and `imag` (imaginary) coordinates Text (appearing either on the chart or on hover only) is via `text`. Bubble charts are achieved by setting `marker.size` and/or `marker.color` to numerical arrays.",
+ "hrName": "scatter_smith"
},
- "type": "scatterpolargl"
+ "type": "scattersmith"
},
"scatterternary": {
"animatable": false,