Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

React finance precursor #2525

Merged
merged 10 commits into from Apr 5, 2018
@@ -65,10 +65,6 @@ module.exports = function calc(gd, trace) {
// create conversion functions that depend on the data
trace.setScale();

// Convert cartesian-space x/y coordinates to screen space pixel coordinates:
t.xp = trace._xp = map2dArray(trace._xp, x, xa.c2p);
t.yp = trace._yp = map2dArray(trace._yp, y, ya.c2p);

This comment has been minimized.

Copy link
@etpinard

// This is a rather expensive scan. Nothing guarantees monotonicity,
// so we need to scan through all data to get proper ranges:
var xrange = arrayMinmax(x);
@@ -92,8 +88,8 @@ module.exports = function calc(gd, trace) {

// Enumerate the gridlines, both major and minor, and store them on the trace
// object:
calcGridlines(trace, t, 'a', 'b');
calcGridlines(trace, t, 'b', 'a');
calcGridlines(trace, 'a', 'b');
calcGridlines(trace, 'b', 'a');

// Calculate the text labels for each major gridline and store them on the
// trace object:
@@ -11,7 +11,7 @@
var Axes = require('../../plots/cartesian/axes');
var extendFlat = require('../../lib/extend').extendFlat;

module.exports = function calcGridlines(trace, cd, axisLetter, crossAxisLetter) {
module.exports = function calcGridlines(trace, axisLetter, crossAxisLetter) {
var i, j, j0;
var eps, bounds, n1, n2, n, value, v;
var j1, v0, v1, d;
ProTip! Use n and p to navigate between commits in a pull request.
You can’t perform that action at this time.