In [1]:
from cartoframes.auth import set_default_credentials
from cartoframes.viz import Map, Layer
set_default_credentials('cartoframes')
In [2]:
Map([
Layer('countries'),
Layer('global_power_plants'),
Layer('world_rivers')
])
Out[2]:
In [3]:
from cartoframes.viz import default_legend
Map([
Layer('countries', legends=default_legend('Countries')),
Layer('global_power_plants', legends=default_legend('Global Power Plants')),
Layer('world_rivers', legends=default_legend('World Rivers'))
])
Out[3]:
In [4]:
from cartoframes.viz import default_legend
Map([
Layer('countries', title='Countries', legends=default_legend()),
Layer('global_power_plants', title='Global Power Plants', legends=default_legend()),
Layer('world_rivers', title='World Rivers', legends=default_legend())
], layer_selector=True)
Out[4]: