title: Define function in leaflet cluster options
body: <p>How do I custom the cluster options so that the markers aren't clustered by the default Leaflet markerOptions(count of markers), but by a function (mean, maximum or whatelse) that I choose?
  For Java i could find tons of examples, but for R I couldn't find anything.
  Only thing I could find is something that has to do with 
  "iconCreateFunction" and "JS()", but I don't know if it's right and how it works..</p>
  
  <pre><code>leaflet(data) %&gt;%
  addTiles() %&gt;%
  addMarkers(lng=data$lon, lat=data$lat, clusterOptions = list(iconCreateFunction = JS(...
  </code></pre>
  
  <p>Can somebody help me? Thanks in advance</p>