In this example, a default Legend with a title, description, and footer is added to the map.
For more information, run help(Layer)
or help(Legend)
.
from cartoframes.auth import set_default_credentials
from cartoframes.viz import Layer, Legend
set_default_credentials('cartoframes')
Layer(
'global_power_plants',
legend=Legend(
'default',
title='Global Power Plants',
description='Power plant locations around the world',
footer='Source: World Resources Institute'
)
)