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

[deck] allow an array of dynamic of aggregations #6198

Merged
merged 3 commits into from Oct 29, 2018

Conversation

mistercrunch
Copy link
Member

@mistercrunch mistercrunch commented Oct 26, 2018

screen shot 2018-10-25 at 9 59 20 pm

Also used this JS snipped as the tooltip to validate:

g => {
    const acc = p => p.weight;
    let arr = g.object.points.sort((o1, o2) => d3array.ascending(acc(o1), acc(o2)));
    return `
      <div>count: ${arr.length}</div>
      <div>sum: ${d3array.sum(arr, acc)}</div>
      <div>min: ${d3array.min(arr, acc)}</div>
      <div>max: ${d3array.max(arr, acc)}</div>
      <div>mean: ${d3array.mean(arr, acc)}</div>
      <div>median: ${d3array.quantile(arr, 0.5, acc)}</div>
      <div>variance: ${d3array.variance(arr, acc)}</div>
      <div>deviation: ${d3array.deviation(arr, acc)}</div>
      <div>p1: ${d3array.quantile(arr, 0.01, acc)}</div>
      <div>p99: ${d3array.quantile(arr, 0.99, acc)}</div>
    `
}

screen shot 2018-10-25 at 9 50 13 pm

Copy link
Contributor

@sumedhsakdeo sumedhsakdeo left a comment

Choose a reason for hiding this comment

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

Thank you @mistercrunch

@codecov-io
Copy link

codecov-io commented Oct 26, 2018

Codecov Report

Merging #6198 into master will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master    #6198   +/-   ##
=======================================
  Coverage   76.91%   76.91%           
=======================================
  Files          47       47           
  Lines        9393     9393           
=======================================
  Hits         7225     7225           
  Misses       2168     2168

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update d6908ee...24e0dc9. Read the comment docs.

@betodealmeida
Copy link
Member

This is awesome! Should/can we add it to screengrid as well?

@betodealmeida
Copy link
Member

+1

@betodealmeida betodealmeida merged commit acb4416 into apache:master Oct 29, 2018
bipinsoniguavus pushed a commit to ThalesGroup/incubator-superset that referenced this pull request Dec 26, 2018
* [deck] allow an array of dynamic of aggregations

* Adding quantiles

* lint & tests
@mistercrunch mistercrunch added 🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels 🚢 0.34.0 labels Feb 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels 🚢 0.34.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants