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

GH-521 Adds N-D Data to Column Chart #534

Closed
wants to merge 29 commits into
base: candidate-1.2.2
from

Conversation

Projects
None yet
3 participants
@anmoljagetia
Contributor

anmoljagetia commented Jun 28, 2015

GordonSmith and others added some commits May 29, 2015

Bumped version to 1.3.0
Signed-off-by: Gordon Smith <gordon.smith@lexisnexis.com>
GH-429 Surface Right/Bottom is getting clipped
Fixes GH-429

Signed-off-by: Gordon Smith <gordon.smith@lexisnexis.com>
Merge pull request #460 from GordonSmith/GH-429
GH-429 Surface Right/Bottom is getting clipped
Refactors X and Y to Data & Column
Removes the generic X and Y reference, and renames the axis to data and column axis.
All the instances of axis are renamed to dataAxis and columnAxis, but the variables x and y are left as it is, as they are heavily used in calculations in the Line and Column files.

Signed-off-by: Anmol Jagetia <anmoljagetia@gmail.com>
Merge pull request #471 from hpcc-systems/revert-460-GH-429
Revert "GH-429 Surface Right/Bottom is getting clipped"
Merge pull request #462 from anmoljagetia/refactorXY
Refactors X and Y to Data & Column in XYAxis
Adds HTML Surface Buttons
Signed-off-by: Mathew Zummo <mzummo@gmail.com>
Signed-off-by: Dan Snell <Dan.Snell@lexisnexis.com>
Adds ThemeEditor & Playground
Signed-off-by: Mathew Zummo <mzummo@gmail.com>
Signed-off-by: Jay Brundage <jaman.brundage@lexisnexis.com>
changes
Signed-off-by: Mathew Zummo <mzummo@gmail.com>
changes to docs_sections
Signed-off-by: Mathew Zummo <mzummo@gmail.com>
Merge pull request #499 from mlzummo/DEMO_SAMPLE_SITE
Adds ThemeEditor & Playground
GH-495 Adds the Scatter Chart
Fixed GH-495

Signed-off-by: Anmol Jagetia <anmoljagetia@gmail.com>
GH-508 XAxis Scales
Add support for linear scale.
Add support for time scale.
Publish "sample" data property.

Fixes GH-508

Signed-off-by: Gordon Smith <gordon.smith@lexisnexis.com>
@@ -31,46 +31,62 @@
this._palette = this._palette.switch(this.paletteID());
var column = this.svgData.selectAll(".columnRect")
var insideScale = d3.scale.ordinal();

This comment has been minimized.

@GordonSmith

GordonSmith Jun 29, 2015

Member

rename to "columnScale" and move either this declaration or the initialization code so they are beside each other.

var column = this.svgData.selectAll(".columnRect")
var insideScale = d3.scale.ordinal();
var column = this.svgData.selectAll(".rectSubject")

This comment has been minimized.

@GordonSmith

GordonSmith Jun 29, 2015

Member

rename "rectSubject" to something more suitable (the data won't always be about subjects) - ".dataRow"?

title
.text(function (d) { return d[0] + " (" + d[1] + ")"; })
;
insideScale.domain(context._columns.filter(function (d, idx) { return idx > 0; })).rangeRoundBands([0, context.dataScale.rangeBand()]);

This comment has been minimized.

@GordonSmith

GordonSmith Jun 29, 2015

Member

Rename and move to beside the declaration.

})
.append("title")
column.enter().append("g")
.attr("class", "rectSubject")

This comment has been minimized.

@GordonSmith

GordonSmith Jun 29, 2015

Member

rename "rectSubject"

.each(function (dataRow, i) {
var element = d3.select(this);
var yearMarks = element.selectAll("rect").data(dataRow.filter(function(d, i) {return i > 0;}));

This comment has been minimized.

@GordonSmith

GordonSmith Jun 29, 2015

Member

rename yearMarks to something more suitable "columnsRects"?

.enter().append("rect")
.attr("class", "columnRect")
.on("click", function (d, idx) {
context.click(context.rowToObj(idx), dataRow[0] + " " + context._columns[idx + 1]);

This comment has been minimized.

@GordonSmith

GordonSmith Jun 29, 2015

Member

Click is not passing the correct data, it should be the entire dataRow and Column Name.

}
title
.text(function (d, idx) { return dataRow[0] + " (" + d + ")"; })

This comment has been minimized.

@GordonSmith

GordonSmith Jun 29, 2015

Member

Tooltip should include Column Title.

@GordonSmith

This comment has been minimized.

Member

GordonSmith commented Jun 29, 2015

Can you rebase and re-issue against master.

var column = this.svgData.selectAll(".columnRect")
var columnScale = d3.scale.ordinal();
columnScale.domain(context._columns.filter(function (d, idx) { return idx > 0; })).rangeRoundBands([0, context.dataScale.rangeBand()]);

This comment has been minimized.

@GordonSmith

GordonSmith Jun 29, 2015

Member

Line 34 + 36 can be rolled into a single line:

var columnScale = d3.scale.ordinal()
    .domain(context._columns.filter(function (d, idx) { return idx > 0; }))
    .rangeRoundBands([0, context.dataScale.rangeBand()])
;
.enter().append("rect")
.attr("class", "columnRect")
.on("click", function (d, idx) {
context.click(context.rowToObj(idx), dataRow + " " + context._columns[idx + 1]);

This comment has been minimized.

@GordonSmith

GordonSmith Jun 29, 2015

Member

Click is not passing the correct data, it should be the entire dataRow and Column Name. See the console output for click here: http://rawgit.com/anmoljagetia/Visualization/ndColumn/demos/dermatology.html?src/google/Column

@anmoljagetia anmoljagetia force-pushed the anmoljagetia:ndColumn branch 5 times, most recently from 2fee084 to 0a2fa1f Jun 29, 2015

GH-521 Adds N-D Data to Column Chart
Fixes GH-521

Signed-off-by: Anmol Jagetia <anmoljagetia@gmail.com>

@anmoljagetia anmoljagetia force-pushed the anmoljagetia:ndColumn branch from 0a2fa1f to 733965c Jun 29, 2015

@GordonSmith

This comment has been minimized.

Member

GordonSmith commented Jun 29, 2015

Closing as retargtting to master #535

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment