Error grouping data by csv column

FileAttachment(...).csv() returns a Promise. Observable’s Runtime resolves Promises automatically for you, but only when they are referenced from other cells/blocks.

If you want to consume the value of the Promise in the same cell you have to await it:

const a = await FileAttachment("./data/trimmed.csv").csv({typed: true});
Inputs.select(d3.group(a, d => d.Aggressor))

or

const a = FileAttachment("./data/trimmed.csv").csv({typed: true});
Inputs.select(d3.group(await a, d => d.Aggressor))

Not at all! :slight_smile: