Fix #2031 - Create a map from an array.

The d3.map constructor can now be used to index the elements of an array by an optional key function, providing a convenient (and faster) alternative to using d3.nest. Before:

```js
var objectByKey = d3.nest()
    .key(function(d) { return d.key; })
    .rollup(function(values) { return values[0]; })
    .map(objects, d3.map);
```

After:

```js
var objectByKey = d3.map(objects, function(d) { return d.key; });
```

Note that the behavior of the d3.map constructor now changes slightly when a sparse array is used. Previously, missing elements from sparse arrays were skipped by the for-in loop, but now missing elements are indexed.