Cluster Size Style

The cluster_size_style helper creates a cluster map with continuously sized points.Use help(cluster_size_style) to get more information about the different settings that can be applied.

Cluster operations are performed in the back-end, so the cluster_size_style helper can be used only with CARTO tables or SQL queries. It cannot be used with GeoDataFrames.


In [1]:
from cartoframes.auth import set_default_credentials

set_default_credentials('cartoframes')

In [2]:
from cartoframes.viz import Layer, cluster_size_style

Layer('vancouver_trees', cluster_size_style('diameter'))


Out[2]:
:
StackTrace
    ">
    
    
    In [3]:
    Layer('vancouver_trees', cluster_size_style('diameter', operation='sum', resolution=64))
    
    
    
    
    Out[3]:
    :
    StackTrace
      ">