-
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Open
Labels
Description
<head>
<!-- Load plotly.js into the DOM -->
<script src='https://cdn.plot.ly/plotly-2.20.0.min.js'></script>
</head>
<body>
<div id='myDiv'><!-- Plotly chart will be drawn inside this DIV --></div>
<script>
var data = [
{
type: "scattermapbox",
mode: "markers+text+lines",
lon: [-75, -80, -50],
lat: [45, 20, -20],
color:'red',
marker: { size: 20, symbol: 'bus' },
text: 'bus',
textposition: "bottom right"
}
];
var layout = {
mapbox: { style: "outdoors", zoom: 0.7 },
showlegend: false, height: 500, width: 700
};
var config = {mapboxAccessToken: mytoken};
Plotly.newPlot("myDiv", data, layout, config);
</script>
</body>
I tried to change the color of the MAKI icons by trying to specify it inside marker dict but it does not work. However, changing the style of mapbox in the layout changes the color of the icons. So it should be possible to specify the color in the marker too (without changing the style). I could not find any information about this in the documentation.
Many thanks in advance.