Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 1 addition & 7 deletions src/transforms/group.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ import {
import {ascendingDefined} from "../defined.js";
import {
column,
first,
identity,
isObject,
isTemporal,
Expand Down Expand Up @@ -230,12 +229,7 @@ export function maybeEvaluator(name, reduce, inputs, asReduce = maybeReduce) {
}

export function maybeGroup(I, X) {
return X
? sort(
grouper(I, (i) => X[i]),
first
)
: [[, I]];
return X ? grouper(I, (i) => X[i]) : [[, I]];
}

export function maybeReduce(reduce, value, fallback = invalidReduce) {
Expand Down
32 changes: 16 additions & 16 deletions test/output/athletesBirthdays.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1,018 changes: 509 additions & 509 deletions test/output/athletesHeightWeightSex.svg
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should probably use multiply blending so the appearance is not affected by order, but that makes it unacceptably slow. 😞

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we could switch to computing the end color directly? challenge unrelated to this PR though :)

Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
48 changes: 24 additions & 24 deletions test/output/athletesSexWeight.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
14 changes: 7 additions & 7 deletions test/output/athletesSortWeightLimit.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
40 changes: 20 additions & 20 deletions test/output/athletesSportSex.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion test/output/autoBarMode.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
12 changes: 6 additions & 6 deletions test/output/autoBarStackColor.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
8 changes: 4 additions & 4 deletions test/output/autoBarTimeSeriesReduce.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading