Skip to content

Commit 87cbc9c

Browse files
committed
no warnings in lineLayer
1 parent 8580f21 commit 87cbc9c

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

src/traces/parcoords/lineLayer.js

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,6 @@ module.exports = function(canvasGL, layout, data, unitToColor, context) {
8585
};
8686

8787
var variables = data;
88-
var data = variables.map(function(v) {return v.values;});
8988
var variableCount = variables.length;
9089
var sampleCount = variables[0].values.length;
9190

@@ -110,7 +109,7 @@ module.exports = function(canvasGL, layout, data, unitToColor, context) {
110109
var coloringVariableUnitScale = variables[coloringVariable].domainToUnitScale;
111110

112111
function colorProjection(j) {
113-
return colorScale(coloringVariableUnitScale(data[coloringVariable][j]));
112+
return colorScale(coloringVariableUnitScale(data[coloringVariable].values[j]));
114113
}
115114

116115
var gpuVariableCount = 60; // don't change this; 3 + 1 extra variables also apply
@@ -123,7 +122,7 @@ module.exports = function(canvasGL, layout, data, unitToColor, context) {
123122
var points = []
124123
for(var j = 0; j < sampleCount; j++)
125124
for(var i = 0; i < gpuVariableCount; i++)
126-
points.push(i < variableCount ? paddedUnit(variables[i].domainToUnitScale(data[i][j])) : 0.5);
125+
points.push(i < variableCount ? paddedUnit(variables[i].domainToUnitScale(data[i].values[j])) : 0.5);
127126

128127
var pointPairs = [];
129128

@@ -145,7 +144,7 @@ module.exports = function(canvasGL, layout, data, unitToColor, context) {
145144
var depthUnitScale = variables[depthVariable].domainToUnitScale;
146145
var depth = utils.range(sampleCount * 2).map(function(d) {
147146
return Math.max(depthLimitEpsilon, Math.min(1 - depthLimitEpsilon,
148-
depthUnitScale(data[depthVariable][Math.round((d - d % 2) / 2)])));
147+
depthUnitScale(data[depthVariable].values[Math.round((d - d % 2) / 2)])));
149148
})
150149
*/
151150

@@ -201,7 +200,7 @@ module.exports = function(canvasGL, layout, data, unitToColor, context) {
201200
pf: styling
202201
};
203202

204-
for(var i = 0; i < gpuVariableCount / 4; i++) {
203+
for(i = 0; i < gpuVariableCount / 4; i++) {
205204
attributes['p' + i.toString(16)] = {
206205
offset: i * 16,
207206
stride: positionStride,

0 commit comments

Comments
 (0)