Skip to content

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

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

What does mean the sample code? #3821

Closed
dimat2 opened this issue Feb 5, 2024 · 0 comments
Closed

What does mean the sample code? #3821

dimat2 opened this issue Feb 5, 2024 · 0 comments

Comments

@dimat2
Copy link

dimat2 commented Feb 5, 2024

const series = d3.stack()
.keys(d3.union(this.data.map(d => d.age))) // distinct series keys, in input order
.value(([,D], key, ) => D.get(key).population) // get value for each series key and stack
(d3.index(this.data, d => d.state, d => d.age)); // group by stack then series key

I don't understand what does mean the value() function?

Please help.

@d3 d3 locked and limited conversation to collaborators Feb 5, 2024
@mbostock mbostock converted this issue into discussion #3822 Feb 5, 2024

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

Labels
None yet
Development

No branches or pull requests

1 participant