|
|
|
@ -5952,6 +5952,8 @@ nv.models.scatterChart = function() {
|
|
|
|
|
, yAxis = nv.models.axis().orient('left').tickPadding(10)
|
|
|
|
|
, legend = nv.models.legend().height(30)
|
|
|
|
|
, controls = nv.models.legend().height(30)
|
|
|
|
|
, distX = nv.models.distribution().axis('x')
|
|
|
|
|
, distY = nv.models.distribution().axis('y')
|
|
|
|
|
, dispatch = d3.dispatch('tooltipShow', 'tooltipHide')
|
|
|
|
|
;
|
|
|
|
|
|
|
|
|
@ -5962,9 +5964,7 @@ nv.models.scatterChart = function() {
|
|
|
|
|
// Private Variables
|
|
|
|
|
//------------------------------------------------------------
|
|
|
|
|
|
|
|
|
|
var distX = nv.models.distribution().axis('x').scale(x)
|
|
|
|
|
, distY = nv.models.distribution().axis('y').scale(y)
|
|
|
|
|
, x0, y0; //TODO: abstract distribution component and have old scales stored there
|
|
|
|
|
var x0, y0;
|
|
|
|
|
|
|
|
|
|
var showTooltip = function(e, offsetElement) {
|
|
|
|
|
//TODO: make tooltip style an option between single or dual on axes (maybe on all charts with axes?)
|
|
|
|
@ -6103,6 +6103,7 @@ nv.models.scatterChart = function() {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
distX
|
|
|
|
|
.scale(x)
|
|
|
|
|
.width(availableWidth)
|
|
|
|
|
.color(data.map(function(d,i) {
|
|
|
|
|
return d.color || color[i % color.length];
|
|
|
|
@ -6116,6 +6117,7 @@ nv.models.scatterChart = function() {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
distY
|
|
|
|
|
.scale(y)
|
|
|
|
|
.width(availableHeight)
|
|
|
|
|
.color(data.map(function(d,i) {
|
|
|
|
|
return d.color || color[i % color.length];
|
|
|
|
@ -6266,6 +6268,8 @@ nv.models.scatterChart = function() {
|
|
|
|
|
chart.controls = legend;
|
|
|
|
|
chart.xAxis = xAxis;
|
|
|
|
|
chart.yAxis = yAxis;
|
|
|
|
|
chart.distX = distX;
|
|
|
|
|
chart.distY = distY;
|
|
|
|
|
|
|
|
|
|
d3.rebind(chart, scatter, 'id', 'interactive', 'pointActive', 'shape', 'size', 'xScale', 'yScale', 'zScale', 'xDomain', 'yDomain', 'sizeDomain', 'forceX', 'forceY', 'forceSize', 'clipVoronoi', 'clipRadius');
|
|
|
|
|
|
|
|
|
|