Visualizing large datasets with LeafletVisualising clustered features in web maps?Effectively displaying a large amount of data on Google Maps APiServer side clusterer for Google MapsVisualizing large datasets of polygons with LeafletProblem with multipolygon in LeafletHow to use Leaflet marker clustering with image map only?Super large scale maps with Leaflet, how?Visualization of a field in LeafletProblem with legends, leafletVisualizing large datasets of polygons with LeafletVisualizing BIG datasets with leaflet-heatUsing Leaflet with large data?Turf intersect point with Leaflet GeoJSON errorUsing Leaflet Search plugin with GeoJSON layer (L.Control.Search)

Why can't we play rap on piano?

Doing something right before you need it - expression for this?

Is it unprofessional to ask if a job posting on GlassDoor is real?

Do I have a twin with permutated remainders?

I would say: "You are another teacher", but she is a woman and I am a man

What exploit are these user agents trying to use?

Took a trip to a parallel universe, need help deciphering

AES: Why is it a good practice to use only the first 16bytes of a hash for encryption?

Infinite Abelian subgroup of infinite non Abelian group example

Where does SFDX store details about scratch orgs?

In Romance of the Three Kingdoms why do people still use bamboo sticks when paper had already been invented?

Why is Collection not simply treated as Collection<?>

Should I tell management that I intend to leave due to bad software development practices?

Is it canonical bit space?

Watching something be written to a file live with tail

Theorems that impeded progress

How is it possible to have an ability score that is less than 3?

Memorizing the Keyboard

Why "Having chlorophyll without photosynthesis is actually very dangerous" and "like living with a bomb"?

I Accidentally Deleted a Stock Terminal Theme

What to put in ESTA if staying in US for a few days before going on to Canada

Did Shadowfax go to Valinor?

Why is consensus so controversial in Britain?

How can I tell someone that I want to be his or her friend?



Visualizing large datasets with Leaflet


Visualising clustered features in web maps?Effectively displaying a large amount of data on Google Maps APiServer side clusterer for Google MapsVisualizing large datasets of polygons with LeafletProblem with multipolygon in LeafletHow to use Leaflet marker clustering with image map only?Super large scale maps with Leaflet, how?Visualization of a field in LeafletProblem with legends, leafletVisualizing large datasets of polygons with LeafletVisualizing BIG datasets with leaflet-heatUsing Leaflet with large data?Turf intersect point with Leaflet GeoJSON errorUsing Leaflet Search plugin with GeoJSON layer (L.Control.Search)






.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty margin-bottom:0;








33















When using Leaflet to visualize a large dataset (GeoJSON with 10,000 point features), not surprisingly the browser crashes or hangs. A sub-sample of 1000 features from the same dataset works flawlessly. Unfortunately I can't share the dataset for others to try out.



Does anybody have better solutions for visualizing such large datasets? (ultimate aim is to scale this to 2 million features) I'm even willing to consider offline visualization frameworks in case browser based alternatives such as Polymaps or d3.js etc. are deemed incapable.



Edit: Forgot to mention, the user needs to be able to filter the dataset by attributes. So out of N features, only the matching n <= N features might need to be dynamically rendered.










share|improve this question



















  • 3





    Similar discussions: gis.stackexchange.com/questions/4096/ gis.stackexchange.com/questions/14882 gis.stackexchange.com/questions/6954

    – julien
    Oct 1 '12 at 10:45












  • Reposting links so they'll work gis.stackexchange.com/questions/4096/… gis.stackexchange.com/questions/14882/… gis.stackexchange.com/questions/6954/…

    – raphael
    Jun 22 '17 at 19:42


















33















When using Leaflet to visualize a large dataset (GeoJSON with 10,000 point features), not surprisingly the browser crashes or hangs. A sub-sample of 1000 features from the same dataset works flawlessly. Unfortunately I can't share the dataset for others to try out.



Does anybody have better solutions for visualizing such large datasets? (ultimate aim is to scale this to 2 million features) I'm even willing to consider offline visualization frameworks in case browser based alternatives such as Polymaps or d3.js etc. are deemed incapable.



Edit: Forgot to mention, the user needs to be able to filter the dataset by attributes. So out of N features, only the matching n <= N features might need to be dynamically rendered.










share|improve this question



















  • 3





    Similar discussions: gis.stackexchange.com/questions/4096/ gis.stackexchange.com/questions/14882 gis.stackexchange.com/questions/6954

    – julien
    Oct 1 '12 at 10:45












  • Reposting links so they'll work gis.stackexchange.com/questions/4096/… gis.stackexchange.com/questions/14882/… gis.stackexchange.com/questions/6954/…

    – raphael
    Jun 22 '17 at 19:42














33












33








33


13






When using Leaflet to visualize a large dataset (GeoJSON with 10,000 point features), not surprisingly the browser crashes or hangs. A sub-sample of 1000 features from the same dataset works flawlessly. Unfortunately I can't share the dataset for others to try out.



Does anybody have better solutions for visualizing such large datasets? (ultimate aim is to scale this to 2 million features) I'm even willing to consider offline visualization frameworks in case browser based alternatives such as Polymaps or d3.js etc. are deemed incapable.



Edit: Forgot to mention, the user needs to be able to filter the dataset by attributes. So out of N features, only the matching n <= N features might need to be dynamically rendered.










share|improve this question
















When using Leaflet to visualize a large dataset (GeoJSON with 10,000 point features), not surprisingly the browser crashes or hangs. A sub-sample of 1000 features from the same dataset works flawlessly. Unfortunately I can't share the dataset for others to try out.



Does anybody have better solutions for visualizing such large datasets? (ultimate aim is to scale this to 2 million features) I'm even willing to consider offline visualization frameworks in case browser based alternatives such as Polymaps or d3.js etc. are deemed incapable.



Edit: Forgot to mention, the user needs to be able to filter the dataset by attributes. So out of N features, only the matching n <= N features might need to be dynamically rendered.







web-mapping javascript visualisation leaflet polymaps






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Oct 1 '12 at 9:20







Imad

















asked Sep 30 '12 at 21:40









ImadImad

266135




266135







  • 3





    Similar discussions: gis.stackexchange.com/questions/4096/ gis.stackexchange.com/questions/14882 gis.stackexchange.com/questions/6954

    – julien
    Oct 1 '12 at 10:45












  • Reposting links so they'll work gis.stackexchange.com/questions/4096/… gis.stackexchange.com/questions/14882/… gis.stackexchange.com/questions/6954/…

    – raphael
    Jun 22 '17 at 19:42













  • 3





    Similar discussions: gis.stackexchange.com/questions/4096/ gis.stackexchange.com/questions/14882 gis.stackexchange.com/questions/6954

    – julien
    Oct 1 '12 at 10:45












  • Reposting links so they'll work gis.stackexchange.com/questions/4096/… gis.stackexchange.com/questions/14882/… gis.stackexchange.com/questions/6954/…

    – raphael
    Jun 22 '17 at 19:42








3




3





Similar discussions: gis.stackexchange.com/questions/4096/ gis.stackexchange.com/questions/14882 gis.stackexchange.com/questions/6954

– julien
Oct 1 '12 at 10:45






Similar discussions: gis.stackexchange.com/questions/4096/ gis.stackexchange.com/questions/14882 gis.stackexchange.com/questions/6954

– julien
Oct 1 '12 at 10:45














Reposting links so they'll work gis.stackexchange.com/questions/4096/… gis.stackexchange.com/questions/14882/… gis.stackexchange.com/questions/6954/…

– raphael
Jun 22 '17 at 19:42






Reposting links so they'll work gis.stackexchange.com/questions/4096/… gis.stackexchange.com/questions/14882/… gis.stackexchange.com/questions/6954/…

– raphael
Jun 22 '17 at 19:42











6 Answers
6






active

oldest

votes


















22














I'm Leaflet author. There's an awesome clustering plugin for this, Leaflet.markercluster. It's very fast and efficient (take a look at 50k markers example), looks and works very smoothly with nice animations, and has lots of options to suit to your needs.






share|improve this answer




















  • 3





    Also PruneCluster looks promising.

    – TLama
    Jan 19 '15 at 8:53






  • 1





    I would like to expand the original question. I need to do something like this: matall.in/posts/deep-insights-visualizing-1m-flight-routes How can I cluster paths intead of markers?

    – guilhermecgs
    Jan 6 '17 at 15:34


















15














You can use TileMill and render points as raster images, with fast interactivity from UTFGrid. It scales to millions of points and polygons, like this census map, since it intelligently sends only the data needed for specific areas, exactly when it's needed.



As far as I know, there are no other fast methods for doing this other than having a very fast WFS server, which is rather hard to maintain/scale to many viewers.



Disclosure: work for MapBox, wrote quite a bit of the code. But TileMill is free/open source, etc.






share|improve this answer




















  • 1





    I forgot to mention the user should be able to filter the dataset by attributes and display only matching records. So let's say out of 10,000 records, only 500 may actually need to be rendered for a given case. Can (or how would) I do this with TileMill?

    – Imad
    Oct 1 '12 at 9:16







  • 3





    Nope. You might want to try CartoDB, but you should know that making things dynamic and making things performant are opposing goals.

    – tmcw
    Oct 1 '12 at 14:31






  • 1





    the census map link is dead!

    – Daniel R
    Nov 22 '18 at 15:20











  • All the links are daed.

    – LeeGee
    Jan 25 at 3:41


















8














Have you looked into the leaflet clusterer? A blog post by the author describes it
here



Another option worth a look may be to use leaflet in combination with GIS Cloud. Take a look at this demo to see it handle a lot of geometries very quickly. Very impressive. I am in no way affiliated with GISCloud.






share|improve this answer






























    7














    You should never display millions of points on a map. Not only because of the major performance problems, but also from a user's perspective because for them it most certainly will be difficult to interpret this data. Use some means of aggregating the data (clustering, aggregating to polygon areas etc.) combined with different display types at different zoom levels (e.g. show the "raw" point data only on very high zoom levels and use aggregated data everywhere else). An example would be a real estate site such as zillow.com.






    share|improve this answer


















    • 8





      You should never say "you should never". Locals & Tourists is a great example of the kind of insight that visualizing millions (or billions in this case) of points can give.

      – Joseph Sheedy
      Mar 13 '15 at 18:30






    • 1





      Agree w/ @velotron, e.g. six million points beautifully and quickly rendered: mapbox.com/blog/supercluster

      – Max von Hippel
      Oct 28 '16 at 4:07







    • 1





      Yeah, but in this case those points are clustered as well (depending on zoom level), making it very easy to interpret and understand the data.

      – chriserik
      Oct 30 '16 at 10:22






    • 2





      @chriserik right, so the correct answer would be "you should use clustering or heat maps if you have that many points, and here is how to do that ..."

      – Max von Hippel
      Nov 2 '16 at 8:35






    • 3





      My point was that unclustered plots of millions of points can provide insight.

      – Joseph Sheedy
      Nov 15 '16 at 0:45


















    0














    I suggest you reduce the rendered amount of point features: The human eye won't be able to see 10,000 points, not to speak of 2,000,000.



    What you could try is dynamically requesting the dataset from a custom server (which you'd have to set up), e.g.



     map = ...
    map.on('moveend', function(e)
    getGeoJson(e);
    );
    map.on('zoomend', function(e)
    getGeoJson(e);
    );
    map.setView([2,3], 2);

    function getGeoJson(event)
    // todo determine current viewport
    $http.get('someGeoJsonDataProvider.someLanguage?currentView=[lat0,lon0,lat1,lon1]').then(function (resp)
    // todo clear layers
    // new layer
    map.addLayer(
    L.geoJson(resp.data)
    );
    );



    Your server would then calculate which points to return, depending on what the user wants to see right now. Depending on zoom factor and clipping, you will only need to return a very small percentage of points without worsening user experience.



    Downsides: Setting up a server (you should find libraries for filtering the geo points) & slower rendering (after every zoom or drag, a server request needs to be made)






    share|improve this answer






























      -5














      I had solutions to map out 50 to 100 million records, you need to use server-side solutions to do grid and dynamic based. You can not reply on web map APIs (Google,or others) to do client-side's rendering....



      [http://96.231.36.9:8080/rbgis/google_map.html][1]
      try the above links and see how






      share|improve this answer


















      • 2





        Please expand your answer, so it will be helpful even when your server is inaccessible.

        – lynxlynxlynx
        Sep 4 '13 at 15:28











      • Yeah that's ironic. Since your server-side link doesn't work.

        – Max von Hippel
        Oct 25 '16 at 6:04











      Your Answer








      StackExchange.ready(function()
      var channelOptions =
      tags: "".split(" "),
      id: "79"
      ;
      initTagRenderer("".split(" "), "".split(" "), channelOptions);

      StackExchange.using("externalEditor", function()
      // Have to fire editor after snippets, if snippets enabled
      if (StackExchange.settings.snippets.snippetsEnabled)
      StackExchange.using("snippets", function()
      createEditor();
      );

      else
      createEditor();

      );

      function createEditor()
      StackExchange.prepareEditor(
      heartbeatType: 'answer',
      autoActivateHeartbeat: false,
      convertImagesToLinks: false,
      noModals: true,
      showLowRepImageUploadWarning: true,
      reputationToPostImages: null,
      bindNavPrevention: true,
      postfix: "",
      imageUploader:
      brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
      contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
      allowUrls: true
      ,
      onDemand: true,
      discardSelector: ".discard-answer"
      ,immediatelyShowMarkdownHelp:true
      );



      );













      draft saved

      draft discarded


















      StackExchange.ready(
      function ()
      StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fgis.stackexchange.com%2fquestions%2f34589%2fvisualizing-large-datasets-with-leaflet%23new-answer', 'question_page');

      );

      Post as a guest















      Required, but never shown

























      6 Answers
      6






      active

      oldest

      votes








      6 Answers
      6






      active

      oldest

      votes









      active

      oldest

      votes






      active

      oldest

      votes









      22














      I'm Leaflet author. There's an awesome clustering plugin for this, Leaflet.markercluster. It's very fast and efficient (take a look at 50k markers example), looks and works very smoothly with nice animations, and has lots of options to suit to your needs.






      share|improve this answer




















      • 3





        Also PruneCluster looks promising.

        – TLama
        Jan 19 '15 at 8:53






      • 1





        I would like to expand the original question. I need to do something like this: matall.in/posts/deep-insights-visualizing-1m-flight-routes How can I cluster paths intead of markers?

        – guilhermecgs
        Jan 6 '17 at 15:34















      22














      I'm Leaflet author. There's an awesome clustering plugin for this, Leaflet.markercluster. It's very fast and efficient (take a look at 50k markers example), looks and works very smoothly with nice animations, and has lots of options to suit to your needs.






      share|improve this answer




















      • 3





        Also PruneCluster looks promising.

        – TLama
        Jan 19 '15 at 8:53






      • 1





        I would like to expand the original question. I need to do something like this: matall.in/posts/deep-insights-visualizing-1m-flight-routes How can I cluster paths intead of markers?

        – guilhermecgs
        Jan 6 '17 at 15:34













      22












      22








      22







      I'm Leaflet author. There's an awesome clustering plugin for this, Leaflet.markercluster. It's very fast and efficient (take a look at 50k markers example), looks and works very smoothly with nice animations, and has lots of options to suit to your needs.






      share|improve this answer















      I'm Leaflet author. There's an awesome clustering plugin for this, Leaflet.markercluster. It's very fast and efficient (take a look at 50k markers example), looks and works very smoothly with nice animations, and has lots of options to suit to your needs.







      share|improve this answer














      share|improve this answer



      share|improve this answer








      edited Apr 1 at 22:23









      Mateusz Konieczny

      612415




      612415










      answered Oct 16 '12 at 8:34









      MournerMourner

      54626




      54626







      • 3





        Also PruneCluster looks promising.

        – TLama
        Jan 19 '15 at 8:53






      • 1





        I would like to expand the original question. I need to do something like this: matall.in/posts/deep-insights-visualizing-1m-flight-routes How can I cluster paths intead of markers?

        – guilhermecgs
        Jan 6 '17 at 15:34












      • 3





        Also PruneCluster looks promising.

        – TLama
        Jan 19 '15 at 8:53






      • 1





        I would like to expand the original question. I need to do something like this: matall.in/posts/deep-insights-visualizing-1m-flight-routes How can I cluster paths intead of markers?

        – guilhermecgs
        Jan 6 '17 at 15:34







      3




      3





      Also PruneCluster looks promising.

      – TLama
      Jan 19 '15 at 8:53





      Also PruneCluster looks promising.

      – TLama
      Jan 19 '15 at 8:53




      1




      1





      I would like to expand the original question. I need to do something like this: matall.in/posts/deep-insights-visualizing-1m-flight-routes How can I cluster paths intead of markers?

      – guilhermecgs
      Jan 6 '17 at 15:34





      I would like to expand the original question. I need to do something like this: matall.in/posts/deep-insights-visualizing-1m-flight-routes How can I cluster paths intead of markers?

      – guilhermecgs
      Jan 6 '17 at 15:34













      15














      You can use TileMill and render points as raster images, with fast interactivity from UTFGrid. It scales to millions of points and polygons, like this census map, since it intelligently sends only the data needed for specific areas, exactly when it's needed.



      As far as I know, there are no other fast methods for doing this other than having a very fast WFS server, which is rather hard to maintain/scale to many viewers.



      Disclosure: work for MapBox, wrote quite a bit of the code. But TileMill is free/open source, etc.






      share|improve this answer




















      • 1





        I forgot to mention the user should be able to filter the dataset by attributes and display only matching records. So let's say out of 10,000 records, only 500 may actually need to be rendered for a given case. Can (or how would) I do this with TileMill?

        – Imad
        Oct 1 '12 at 9:16







      • 3





        Nope. You might want to try CartoDB, but you should know that making things dynamic and making things performant are opposing goals.

        – tmcw
        Oct 1 '12 at 14:31






      • 1





        the census map link is dead!

        – Daniel R
        Nov 22 '18 at 15:20











      • All the links are daed.

        – LeeGee
        Jan 25 at 3:41















      15














      You can use TileMill and render points as raster images, with fast interactivity from UTFGrid. It scales to millions of points and polygons, like this census map, since it intelligently sends only the data needed for specific areas, exactly when it's needed.



      As far as I know, there are no other fast methods for doing this other than having a very fast WFS server, which is rather hard to maintain/scale to many viewers.



      Disclosure: work for MapBox, wrote quite a bit of the code. But TileMill is free/open source, etc.






      share|improve this answer




















      • 1





        I forgot to mention the user should be able to filter the dataset by attributes and display only matching records. So let's say out of 10,000 records, only 500 may actually need to be rendered for a given case. Can (or how would) I do this with TileMill?

        – Imad
        Oct 1 '12 at 9:16







      • 3





        Nope. You might want to try CartoDB, but you should know that making things dynamic and making things performant are opposing goals.

        – tmcw
        Oct 1 '12 at 14:31






      • 1





        the census map link is dead!

        – Daniel R
        Nov 22 '18 at 15:20











      • All the links are daed.

        – LeeGee
        Jan 25 at 3:41













      15












      15








      15







      You can use TileMill and render points as raster images, with fast interactivity from UTFGrid. It scales to millions of points and polygons, like this census map, since it intelligently sends only the data needed for specific areas, exactly when it's needed.



      As far as I know, there are no other fast methods for doing this other than having a very fast WFS server, which is rather hard to maintain/scale to many viewers.



      Disclosure: work for MapBox, wrote quite a bit of the code. But TileMill is free/open source, etc.






      share|improve this answer















      You can use TileMill and render points as raster images, with fast interactivity from UTFGrid. It scales to millions of points and polygons, like this census map, since it intelligently sends only the data needed for specific areas, exactly when it's needed.



      As far as I know, there are no other fast methods for doing this other than having a very fast WFS server, which is rather hard to maintain/scale to many viewers.



      Disclosure: work for MapBox, wrote quite a bit of the code. But TileMill is free/open source, etc.







      share|improve this answer














      share|improve this answer



      share|improve this answer








      edited Feb 26 at 23:53









      robinmetral

      33




      33










      answered Oct 1 '12 at 0:19









      tmcwtmcw

      3,8941418




      3,8941418







      • 1





        I forgot to mention the user should be able to filter the dataset by attributes and display only matching records. So let's say out of 10,000 records, only 500 may actually need to be rendered for a given case. Can (or how would) I do this with TileMill?

        – Imad
        Oct 1 '12 at 9:16







      • 3





        Nope. You might want to try CartoDB, but you should know that making things dynamic and making things performant are opposing goals.

        – tmcw
        Oct 1 '12 at 14:31






      • 1





        the census map link is dead!

        – Daniel R
        Nov 22 '18 at 15:20











      • All the links are daed.

        – LeeGee
        Jan 25 at 3:41












      • 1





        I forgot to mention the user should be able to filter the dataset by attributes and display only matching records. So let's say out of 10,000 records, only 500 may actually need to be rendered for a given case. Can (or how would) I do this with TileMill?

        – Imad
        Oct 1 '12 at 9:16







      • 3





        Nope. You might want to try CartoDB, but you should know that making things dynamic and making things performant are opposing goals.

        – tmcw
        Oct 1 '12 at 14:31






      • 1





        the census map link is dead!

        – Daniel R
        Nov 22 '18 at 15:20











      • All the links are daed.

        – LeeGee
        Jan 25 at 3:41







      1




      1





      I forgot to mention the user should be able to filter the dataset by attributes and display only matching records. So let's say out of 10,000 records, only 500 may actually need to be rendered for a given case. Can (or how would) I do this with TileMill?

      – Imad
      Oct 1 '12 at 9:16






      I forgot to mention the user should be able to filter the dataset by attributes and display only matching records. So let's say out of 10,000 records, only 500 may actually need to be rendered for a given case. Can (or how would) I do this with TileMill?

      – Imad
      Oct 1 '12 at 9:16





      3




      3





      Nope. You might want to try CartoDB, but you should know that making things dynamic and making things performant are opposing goals.

      – tmcw
      Oct 1 '12 at 14:31





      Nope. You might want to try CartoDB, but you should know that making things dynamic and making things performant are opposing goals.

      – tmcw
      Oct 1 '12 at 14:31




      1




      1





      the census map link is dead!

      – Daniel R
      Nov 22 '18 at 15:20





      the census map link is dead!

      – Daniel R
      Nov 22 '18 at 15:20













      All the links are daed.

      – LeeGee
      Jan 25 at 3:41





      All the links are daed.

      – LeeGee
      Jan 25 at 3:41











      8














      Have you looked into the leaflet clusterer? A blog post by the author describes it
      here



      Another option worth a look may be to use leaflet in combination with GIS Cloud. Take a look at this demo to see it handle a lot of geometries very quickly. Very impressive. I am in no way affiliated with GISCloud.






      share|improve this answer



























        8














        Have you looked into the leaflet clusterer? A blog post by the author describes it
        here



        Another option worth a look may be to use leaflet in combination with GIS Cloud. Take a look at this demo to see it handle a lot of geometries very quickly. Very impressive. I am in no way affiliated with GISCloud.






        share|improve this answer

























          8












          8








          8







          Have you looked into the leaflet clusterer? A blog post by the author describes it
          here



          Another option worth a look may be to use leaflet in combination with GIS Cloud. Take a look at this demo to see it handle a lot of geometries very quickly. Very impressive. I am in no way affiliated with GISCloud.






          share|improve this answer













          Have you looked into the leaflet clusterer? A blog post by the author describes it
          here



          Another option worth a look may be to use leaflet in combination with GIS Cloud. Take a look at this demo to see it handle a lot of geometries very quickly. Very impressive. I am in no way affiliated with GISCloud.







          share|improve this answer












          share|improve this answer



          share|improve this answer










          answered Sep 30 '12 at 23:15









          KelsoKelso

          1,7011120




          1,7011120





















              7














              You should never display millions of points on a map. Not only because of the major performance problems, but also from a user's perspective because for them it most certainly will be difficult to interpret this data. Use some means of aggregating the data (clustering, aggregating to polygon areas etc.) combined with different display types at different zoom levels (e.g. show the "raw" point data only on very high zoom levels and use aggregated data everywhere else). An example would be a real estate site such as zillow.com.






              share|improve this answer


















              • 8





                You should never say "you should never". Locals & Tourists is a great example of the kind of insight that visualizing millions (or billions in this case) of points can give.

                – Joseph Sheedy
                Mar 13 '15 at 18:30






              • 1





                Agree w/ @velotron, e.g. six million points beautifully and quickly rendered: mapbox.com/blog/supercluster

                – Max von Hippel
                Oct 28 '16 at 4:07







              • 1





                Yeah, but in this case those points are clustered as well (depending on zoom level), making it very easy to interpret and understand the data.

                – chriserik
                Oct 30 '16 at 10:22






              • 2





                @chriserik right, so the correct answer would be "you should use clustering or heat maps if you have that many points, and here is how to do that ..."

                – Max von Hippel
                Nov 2 '16 at 8:35






              • 3





                My point was that unclustered plots of millions of points can provide insight.

                – Joseph Sheedy
                Nov 15 '16 at 0:45















              7














              You should never display millions of points on a map. Not only because of the major performance problems, but also from a user's perspective because for them it most certainly will be difficult to interpret this data. Use some means of aggregating the data (clustering, aggregating to polygon areas etc.) combined with different display types at different zoom levels (e.g. show the "raw" point data only on very high zoom levels and use aggregated data everywhere else). An example would be a real estate site such as zillow.com.






              share|improve this answer


















              • 8





                You should never say "you should never". Locals & Tourists is a great example of the kind of insight that visualizing millions (or billions in this case) of points can give.

                – Joseph Sheedy
                Mar 13 '15 at 18:30






              • 1





                Agree w/ @velotron, e.g. six million points beautifully and quickly rendered: mapbox.com/blog/supercluster

                – Max von Hippel
                Oct 28 '16 at 4:07







              • 1





                Yeah, but in this case those points are clustered as well (depending on zoom level), making it very easy to interpret and understand the data.

                – chriserik
                Oct 30 '16 at 10:22






              • 2





                @chriserik right, so the correct answer would be "you should use clustering or heat maps if you have that many points, and here is how to do that ..."

                – Max von Hippel
                Nov 2 '16 at 8:35






              • 3





                My point was that unclustered plots of millions of points can provide insight.

                – Joseph Sheedy
                Nov 15 '16 at 0:45













              7












              7








              7







              You should never display millions of points on a map. Not only because of the major performance problems, but also from a user's perspective because for them it most certainly will be difficult to interpret this data. Use some means of aggregating the data (clustering, aggregating to polygon areas etc.) combined with different display types at different zoom levels (e.g. show the "raw" point data only on very high zoom levels and use aggregated data everywhere else). An example would be a real estate site such as zillow.com.






              share|improve this answer













              You should never display millions of points on a map. Not only because of the major performance problems, but also from a user's perspective because for them it most certainly will be difficult to interpret this data. Use some means of aggregating the data (clustering, aggregating to polygon areas etc.) combined with different display types at different zoom levels (e.g. show the "raw" point data only on very high zoom levels and use aggregated data everywhere else). An example would be a real estate site such as zillow.com.







              share|improve this answer












              share|improve this answer



              share|improve this answer










              answered Sep 30 '12 at 23:21









              chriserikchriserik

              1,103717




              1,103717







              • 8





                You should never say "you should never". Locals & Tourists is a great example of the kind of insight that visualizing millions (or billions in this case) of points can give.

                – Joseph Sheedy
                Mar 13 '15 at 18:30






              • 1





                Agree w/ @velotron, e.g. six million points beautifully and quickly rendered: mapbox.com/blog/supercluster

                – Max von Hippel
                Oct 28 '16 at 4:07







              • 1





                Yeah, but in this case those points are clustered as well (depending on zoom level), making it very easy to interpret and understand the data.

                – chriserik
                Oct 30 '16 at 10:22






              • 2





                @chriserik right, so the correct answer would be "you should use clustering or heat maps if you have that many points, and here is how to do that ..."

                – Max von Hippel
                Nov 2 '16 at 8:35






              • 3





                My point was that unclustered plots of millions of points can provide insight.

                – Joseph Sheedy
                Nov 15 '16 at 0:45












              • 8





                You should never say "you should never". Locals & Tourists is a great example of the kind of insight that visualizing millions (or billions in this case) of points can give.

                – Joseph Sheedy
                Mar 13 '15 at 18:30






              • 1





                Agree w/ @velotron, e.g. six million points beautifully and quickly rendered: mapbox.com/blog/supercluster

                – Max von Hippel
                Oct 28 '16 at 4:07







              • 1





                Yeah, but in this case those points are clustered as well (depending on zoom level), making it very easy to interpret and understand the data.

                – chriserik
                Oct 30 '16 at 10:22






              • 2





                @chriserik right, so the correct answer would be "you should use clustering or heat maps if you have that many points, and here is how to do that ..."

                – Max von Hippel
                Nov 2 '16 at 8:35






              • 3





                My point was that unclustered plots of millions of points can provide insight.

                – Joseph Sheedy
                Nov 15 '16 at 0:45







              8




              8





              You should never say "you should never". Locals & Tourists is a great example of the kind of insight that visualizing millions (or billions in this case) of points can give.

              – Joseph Sheedy
              Mar 13 '15 at 18:30





              You should never say "you should never". Locals & Tourists is a great example of the kind of insight that visualizing millions (or billions in this case) of points can give.

              – Joseph Sheedy
              Mar 13 '15 at 18:30




              1




              1





              Agree w/ @velotron, e.g. six million points beautifully and quickly rendered: mapbox.com/blog/supercluster

              – Max von Hippel
              Oct 28 '16 at 4:07






              Agree w/ @velotron, e.g. six million points beautifully and quickly rendered: mapbox.com/blog/supercluster

              – Max von Hippel
              Oct 28 '16 at 4:07





              1




              1





              Yeah, but in this case those points are clustered as well (depending on zoom level), making it very easy to interpret and understand the data.

              – chriserik
              Oct 30 '16 at 10:22





              Yeah, but in this case those points are clustered as well (depending on zoom level), making it very easy to interpret and understand the data.

              – chriserik
              Oct 30 '16 at 10:22




              2




              2





              @chriserik right, so the correct answer would be "you should use clustering or heat maps if you have that many points, and here is how to do that ..."

              – Max von Hippel
              Nov 2 '16 at 8:35





              @chriserik right, so the correct answer would be "you should use clustering or heat maps if you have that many points, and here is how to do that ..."

              – Max von Hippel
              Nov 2 '16 at 8:35




              3




              3





              My point was that unclustered plots of millions of points can provide insight.

              – Joseph Sheedy
              Nov 15 '16 at 0:45





              My point was that unclustered plots of millions of points can provide insight.

              – Joseph Sheedy
              Nov 15 '16 at 0:45











              0














              I suggest you reduce the rendered amount of point features: The human eye won't be able to see 10,000 points, not to speak of 2,000,000.



              What you could try is dynamically requesting the dataset from a custom server (which you'd have to set up), e.g.



               map = ...
              map.on('moveend', function(e)
              getGeoJson(e);
              );
              map.on('zoomend', function(e)
              getGeoJson(e);
              );
              map.setView([2,3], 2);

              function getGeoJson(event)
              // todo determine current viewport
              $http.get('someGeoJsonDataProvider.someLanguage?currentView=[lat0,lon0,lat1,lon1]').then(function (resp)
              // todo clear layers
              // new layer
              map.addLayer(
              L.geoJson(resp.data)
              );
              );



              Your server would then calculate which points to return, depending on what the user wants to see right now. Depending on zoom factor and clipping, you will only need to return a very small percentage of points without worsening user experience.



              Downsides: Setting up a server (you should find libraries for filtering the geo points) & slower rendering (after every zoom or drag, a server request needs to be made)






              share|improve this answer



























                0














                I suggest you reduce the rendered amount of point features: The human eye won't be able to see 10,000 points, not to speak of 2,000,000.



                What you could try is dynamically requesting the dataset from a custom server (which you'd have to set up), e.g.



                 map = ...
                map.on('moveend', function(e)
                getGeoJson(e);
                );
                map.on('zoomend', function(e)
                getGeoJson(e);
                );
                map.setView([2,3], 2);

                function getGeoJson(event)
                // todo determine current viewport
                $http.get('someGeoJsonDataProvider.someLanguage?currentView=[lat0,lon0,lat1,lon1]').then(function (resp)
                // todo clear layers
                // new layer
                map.addLayer(
                L.geoJson(resp.data)
                );
                );



                Your server would then calculate which points to return, depending on what the user wants to see right now. Depending on zoom factor and clipping, you will only need to return a very small percentage of points without worsening user experience.



                Downsides: Setting up a server (you should find libraries for filtering the geo points) & slower rendering (after every zoom or drag, a server request needs to be made)






                share|improve this answer

























                  0












                  0








                  0







                  I suggest you reduce the rendered amount of point features: The human eye won't be able to see 10,000 points, not to speak of 2,000,000.



                  What you could try is dynamically requesting the dataset from a custom server (which you'd have to set up), e.g.



                   map = ...
                  map.on('moveend', function(e)
                  getGeoJson(e);
                  );
                  map.on('zoomend', function(e)
                  getGeoJson(e);
                  );
                  map.setView([2,3], 2);

                  function getGeoJson(event)
                  // todo determine current viewport
                  $http.get('someGeoJsonDataProvider.someLanguage?currentView=[lat0,lon0,lat1,lon1]').then(function (resp)
                  // todo clear layers
                  // new layer
                  map.addLayer(
                  L.geoJson(resp.data)
                  );
                  );



                  Your server would then calculate which points to return, depending on what the user wants to see right now. Depending on zoom factor and clipping, you will only need to return a very small percentage of points without worsening user experience.



                  Downsides: Setting up a server (you should find libraries for filtering the geo points) & slower rendering (after every zoom or drag, a server request needs to be made)






                  share|improve this answer













                  I suggest you reduce the rendered amount of point features: The human eye won't be able to see 10,000 points, not to speak of 2,000,000.



                  What you could try is dynamically requesting the dataset from a custom server (which you'd have to set up), e.g.



                   map = ...
                  map.on('moveend', function(e)
                  getGeoJson(e);
                  );
                  map.on('zoomend', function(e)
                  getGeoJson(e);
                  );
                  map.setView([2,3], 2);

                  function getGeoJson(event)
                  // todo determine current viewport
                  $http.get('someGeoJsonDataProvider.someLanguage?currentView=[lat0,lon0,lat1,lon1]').then(function (resp)
                  // todo clear layers
                  // new layer
                  map.addLayer(
                  L.geoJson(resp.data)
                  );
                  );



                  Your server would then calculate which points to return, depending on what the user wants to see right now. Depending on zoom factor and clipping, you will only need to return a very small percentage of points without worsening user experience.



                  Downsides: Setting up a server (you should find libraries for filtering the geo points) & slower rendering (after every zoom or drag, a server request needs to be made)







                  share|improve this answer












                  share|improve this answer



                  share|improve this answer










                  answered Nov 27 '16 at 2:06









                  BlauhirnBlauhirn

                  1012




                  1012





















                      -5














                      I had solutions to map out 50 to 100 million records, you need to use server-side solutions to do grid and dynamic based. You can not reply on web map APIs (Google,or others) to do client-side's rendering....



                      [http://96.231.36.9:8080/rbgis/google_map.html][1]
                      try the above links and see how






                      share|improve this answer


















                      • 2





                        Please expand your answer, so it will be helpful even when your server is inaccessible.

                        – lynxlynxlynx
                        Sep 4 '13 at 15:28











                      • Yeah that's ironic. Since your server-side link doesn't work.

                        – Max von Hippel
                        Oct 25 '16 at 6:04















                      -5














                      I had solutions to map out 50 to 100 million records, you need to use server-side solutions to do grid and dynamic based. You can not reply on web map APIs (Google,or others) to do client-side's rendering....



                      [http://96.231.36.9:8080/rbgis/google_map.html][1]
                      try the above links and see how






                      share|improve this answer


















                      • 2





                        Please expand your answer, so it will be helpful even when your server is inaccessible.

                        – lynxlynxlynx
                        Sep 4 '13 at 15:28











                      • Yeah that's ironic. Since your server-side link doesn't work.

                        – Max von Hippel
                        Oct 25 '16 at 6:04













                      -5












                      -5








                      -5







                      I had solutions to map out 50 to 100 million records, you need to use server-side solutions to do grid and dynamic based. You can not reply on web map APIs (Google,or others) to do client-side's rendering....



                      [http://96.231.36.9:8080/rbgis/google_map.html][1]
                      try the above links and see how






                      share|improve this answer













                      I had solutions to map out 50 to 100 million records, you need to use server-side solutions to do grid and dynamic based. You can not reply on web map APIs (Google,or others) to do client-side's rendering....



                      [http://96.231.36.9:8080/rbgis/google_map.html][1]
                      try the above links and see how







                      share|improve this answer












                      share|improve this answer



                      share|improve this answer










                      answered Sep 4 '13 at 15:06









                      bdv_enginebdv_engine

                      1




                      1







                      • 2





                        Please expand your answer, so it will be helpful even when your server is inaccessible.

                        – lynxlynxlynx
                        Sep 4 '13 at 15:28











                      • Yeah that's ironic. Since your server-side link doesn't work.

                        – Max von Hippel
                        Oct 25 '16 at 6:04












                      • 2





                        Please expand your answer, so it will be helpful even when your server is inaccessible.

                        – lynxlynxlynx
                        Sep 4 '13 at 15:28











                      • Yeah that's ironic. Since your server-side link doesn't work.

                        – Max von Hippel
                        Oct 25 '16 at 6:04







                      2




                      2





                      Please expand your answer, so it will be helpful even when your server is inaccessible.

                      – lynxlynxlynx
                      Sep 4 '13 at 15:28





                      Please expand your answer, so it will be helpful even when your server is inaccessible.

                      – lynxlynxlynx
                      Sep 4 '13 at 15:28













                      Yeah that's ironic. Since your server-side link doesn't work.

                      – Max von Hippel
                      Oct 25 '16 at 6:04





                      Yeah that's ironic. Since your server-side link doesn't work.

                      – Max von Hippel
                      Oct 25 '16 at 6:04

















                      draft saved

                      draft discarded
















































                      Thanks for contributing an answer to Geographic Information Systems Stack Exchange!


                      • Please be sure to answer the question. Provide details and share your research!

                      But avoid


                      • Asking for help, clarification, or responding to other answers.

                      • Making statements based on opinion; back them up with references or personal experience.

                      To learn more, see our tips on writing great answers.




                      draft saved


                      draft discarded














                      StackExchange.ready(
                      function ()
                      StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fgis.stackexchange.com%2fquestions%2f34589%2fvisualizing-large-datasets-with-leaflet%23new-answer', 'question_page');

                      );

                      Post as a guest















                      Required, but never shown





















































                      Required, but never shown














                      Required, but never shown












                      Required, but never shown







                      Required, but never shown

































                      Required, but never shown














                      Required, but never shown












                      Required, but never shown







                      Required, but never shown







                      Popular posts from this blog

                      រឿង រ៉ូមេអូ និង ហ្ស៊ុយលីយេ សង្ខេបរឿង តួអង្គ បញ្ជីណែនាំ

                      QGIS export composer to PDF scale the map [closed] Planned maintenance scheduled April 23, 2019 at 23:30 UTC (7:30pm US/Eastern) Announcing the arrival of Valued Associate #679: Cesar Manara Unicorn Meta Zoo #1: Why another podcast?Print Composer QGIS 2.6, how to export image?QGIS 2.8.1 print composer won't export all OpenCycleMap base layer tilesSave Print/Map QGIS composer view as PNG/PDF using Python (without changing anything in visible layout)?Export QGIS Print Composer PDF with searchable text labelsQGIS Print Composer does not change from landscape to portrait orientation?How can I avoid map size and scale changes in print composer?Fuzzy PDF export in QGIS running on macSierra OSExport the legend into its 100% size using Print ComposerScale-dependent rendering in QGIS PDF output

                      PDF-ში გადმოწერა სანავიგაციო მენიუproject page