Hi, I’m trying to figure out a few things with a treetable.
Here is a simplified example of what I’m trying to do:
Given a dataset as follows:
[
{round:1, bidder:'A', bid:100},
{round:1, bidder:'B', bid:110},
{round:1, bidder:'C', bid:120},
{round:2, bidder:'A', bid:200},
{round:2, bidder:'B', bid:300},
{round:3, bidder:'A', bid:310}
]
I’d like to be able to create a table with the headers: “bidder”, and “bid”
with the rows grouped by ‘round’.
e.g.:
Bidder | Bid
Round 1
A | 100
B | 110
C | 120
Round 2
A | 200
B | 300
Round 3
A | 310
In other words, the column which is used for the grouping (‘round’) changes from a column to a whole row.
I’m almost there, using a treetable, but it can’t get the ‘round’ column to work properly.
Thanks