title: Add marker count to GMap by location
body: <p>I'm looking to add a marker count for each location on my map. You'll notice that each of the three places shown on the map has a different number of markers:</p>
  
  <p><a href="https://jsfiddle.net/JimmyRivvers/hwdfgmdk/" rel="nofollow">Here's my jsfiddle.</a></p>
  
  <p>And here's the code if you can eyeball it:</p>
  
  <pre><code>function initialize() {
  
      var locations = [
          [40.82829, -73.9271, 'Marker 1'],
          [40.756421, -73.845897, 'Marker 2'],
          [40.756421, -73.845897, 'Marker 3'],
          [40.750704, -73.993752, 'Marker 4'],
          [40.750704, -73.993752, 'Marker 5'],
          [40.750704, -73.993752, 'Marker 6']
      ];
  
      var map = new google.maps.Map(document.getElementById("map-canvas"), {
          zoom: 12,
          center: new google.maps.LatLng(40.773522, -73.944039),
          mapTypeId: google.maps.MapTypeId.ROADMAP
      });
  
      // Create markers on the map
      for (var i = 0; i &lt; locations.length; i++) {
          var pos = new google.maps.LatLng(locations[i][0], locations[i][1]); 
  
          var marker = new google.maps.Marker({
              position: pos,
              map: map,
              title: locations[i][2]
          });
      }
  }
  
  initialize();
  </code></pre>
  
  <p>I'd like to display the count in a div below each marker.</p>