JavaScript D3.js TopoJSON map of Brooklyn not rendering

I am attempting to render a map of Brooklyn's building and lots using D3.js. To accomplish this task, I have done the following:

  1. Obtained shapefile from MapPLUTO:

http://www.nyc.gov/html/dcp/html/bytes/dwn_pluto_mappluto.shtml.

  1. Converted shapefile to GeoJSON with the following ogr2ogr command:

ogr2ogr -f GeoJSON -lco COORDINATE_PRECISION=4 -select 'geometry, BBL' -s_srs EPSG:2263 -t_srs EPSG:4326 bk-gll1.json BKMapPLUTO.shp

  1. Transformed GeoJSON to TopoJSON with the following: topojson -o bkgll1-topojson.json bk-gll1.json

I've experimented with different projections, scales, and data bindings, but I've only managed to render either a black square that fills the SVG viewport, or nothing.

The TopoJSON and GeoJSON files are located here: https://github.com/RobertPTC/nyc_maps. Also included is a screenshot of the TopoJSON rendered through mapshaper.org

$(function() {
    var width = 960,
        height = 500;
    var svg = d3.select('body').append('svg')
        .attr('width', width)
        .attr('height', height)
    var projection = d3.geo.mercator()
             .rotate([96,0])
             .center([-73.98, 40.70])
             .scale(237000)
             .translate([width/2, height/2])
    var path = d3.geo.path()
                 .projection(projection)
    d3.json('bk-gll1-topojson.json', function(error, bk) {
             console.log(bk);
             var featureCollection = topojson.feature(bk, bk.objects['bk-gll1']);
             var bounds = d3.geo.bounds(featureCollection);

             svg.append('path')
                .datum(featureCollection)
                .attr('d', path)
 });
});

As a D3.js megafan, I would be tremendously appreciative if anyone could help solve this problem!

UPDATE

I seem to have results with this code:

$(function() {

var width = 1260,
  height = 1000;

var svg = d3.select("body").append("svg")
   .attr("width", width)
   .attr("height", height);

var projection = d3.geo.mercator()
  .center([-73.98, 40.70])
  .scale(237000)
  .translate([width/2, height/2]);

var features = svg.append('g')
            .attr('class', 'features');
var path = d3.geo.path()
        .projection(projection);

var zoom = d3.behavior.zoom()
        .scaleExtent([1, Infinity])
        .on('zoom', zoomed);

d3.json('bk-gll1-topojson.json', function(error, bk) {
    console.log(bk);
var featureCollection = topojson.feature(bk, bk.objects['bk-gll1']);
var bounds = d3.geo.bounds(featureCollection);
console.log(featureCollection.features[0]);

features.selectAll('path')
  .data(featureCollection.features.slice(0, 241000))
  .enter()
  .append('path')
  .attr('d', path)
 });
function zoomed() {
console.log('zooming');
features.attr("transform", "translate(" + zoom.translate() + ")scale("  + zoom.scale() + ")")
    .selectAll("path").style("stroke-width", 1 / zoom.scale() + "px"      );
 };
});

However, I'm only able to render about a third of the 670000 elements in the featuresCollection array. Any advice as to how I can load the entire dataset without crashing the browser? Is it possible?

UPDATE 2

So, it would seem that load the data in incrementally helps...still a long load time, however, so probably not feasible for production environment:

features.selectAll('path')
  .data(featureCollection.features.slice(0, 241500))//after this number of elements point, map renders as giant black square
  .enter()
  .append('path')
  .attr('d', path)
  .on('click', clicked);
features.selectAll('path')
  .data(featureCollection.features.slice(241500, 246500))
  .enter()
  .append('path')
  .attr('d', path)
  .on('clicked', clicked);
Answer:1

I'm building a web app where users can connect to each other and chat. So each chat holds two users. I'm having some general questions concerning Pusher API, (http://pusher.com). First question. ...

I'm building a web app where users can connect to each other and chat. So each chat holds two users. I'm having some general questions concerning Pusher API, (http://pusher.com). First question. ...

  1. pusher channels react
  2. pusher channels pricing
  3. pusher channels vs beams
  4. pusher channels vs chatkit
  5. pusher channels flutter
  6. pusher channels docs
  7. pusher channels websocket
  8. pusher channels name
  9. pusher channels methods
  10. pusher private channels
  11. pusher multiple channels
  12. pusher presence channels
  13. laravel pusher channels
  14. pusher max channels
  15. pusher js channels
  16. authenticated pusher channels
  17. using pusher channels
  18. pusher node js channels
  19. pusher subscribe multiple channels
  20. pusher vs django channels

I have a list of bootstrap component class="list-group" I have a folder of videos/category, I want to when I click on a category, the list updates without loading a page (by changing the path). Have ...

I have a list of bootstrap component class="list-group" I have a folder of videos/category, I want to when I click on a category, the list updates without loading a page (by changing the path). Have ...

  1. dynamic list html javascript
  2. dynamic list html
  3. dynamic list html jquery
  4. dynamic list html c#
  5. dynamic drop down list html
  6. dynamic search list html
  7. create dynamic list html
  8. dynamic select list html
  9. dynamic checkbox list html
  10. dynamic unordered list html
  11. dynamic list filter html
  12. dynamic list display html
  13. dynamic list data html
  14. dynamic drop down list html form
  15. dynamic drop down list html javascript
  16. dynamic drop down list html jquery
  17. dynamic list view in html
  18. dynamic drop down list html python
  19. dynamic drop down list html php
  20. dynamic drop down list html w3schools

I have a object in my HTML site which I expand/add to with a little JavaScript bit (below) on button click. Can I refresh the dropdown/select on it's own to show the new choices automaticaly or can ...

I have a object in my HTML site which I expand/add to with a little JavaScript bit (below) on button click. Can I refresh the dropdown/select on it's own to show the new choices automaticaly or can ...

I have an XSLT with javascript in it which uses "&lt ;" and "&gt ;" inside for loop <?xml version="1.0" encoding="UTF-8"?> <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/...

I have an XSLT with javascript in it which uses "&lt ;" and "&gt ;" inside for loop <?xml version="1.0" encoding="UTF-8"?> <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/...

  1. python lxml library
  2. python lxml library install
  3. lxml python library installed on the managed machine
  4. lxml python library ubuntu
  5. lxml python library download
  6. python lxml parser library
  7. lxml python standard library
  8. python install parser library lxml