returns dictionary for input into d3 visualization