geobubble

Bubble chart of data located by latitude and longitude on a map.

Category: Graphics > 2-D and 3-D Plots

Syntax

geobubble(lat, lon)

Draws a bubble at each coordinate; repeated locations make larger bubbles.

geobubble(lat, lon, sizedata)

Sets the bubble size from the values in sizedata.

geobubble(___, Name, Value)

Sets chart properties such as 'Title' or 'Basemap'.

gb = geobubble(___)

Also returns the chart object.

Description

geobubble places bubbles over a geographic map so that a count or measurement can be compared across places. Points with identical coordinates are combined into one bubble.

Input arguments

lat, lon
Vectors of latitudes and longitudes in degrees, of the same length.
sizedata
Vector with one value per point that sets the bubble area.

Output arguments

gb
GeographicBubbleChart object.

Example

Three cities

lat = [-23.55 -22.91 -15.78];
lon = [-46.63 -43.17 -47.93];
pop = [12.3 6.7 3.1];
geobubble(lat, lon, pop)

In the app, the chart is drawn below the code.

Notes

MatLivre draws the bubbles without a basemap.

See also

scatter bubblechart heatmap plot