consider using a d3.set instead of a list, closer match to the semantics you want, better perf
https://github.com/mbostock/d3/wiki/Arrays#d3_set