Replies: 5 comments
This comment was marked as off-topic.
This comment was marked as off-topic.
-
it is documented here: https://d3js.org/d3-shape/stack#stack_value |
Beta Was this translation helpful? Give feedback.
0 replies
This comment was marked as off-topic.
This comment was marked as off-topic.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
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.
Beta Was this translation helpful? Give feedback.
All reactions