IoTPy.modules.Geomap package¶
Submodules¶
IoTPy.modules.Geomap.geomap module¶
-
class
IoTPy.modules.Geomap.geomap.
Geomap
(figsize=(1000, 800), **kwargs)[source]¶ Mapping framework for plotting data onto a map.
Given latitude - longitude coordinates, this framework allows data to be plotted onto a world map with specified region and projection. Data can be plotted with different colors as well as labels. Previous data can also be cleared.
Parameters: figsize : tuple
A tuple containing the width and height of the plot for the map (the default is (1000, 800)).
kwargs : keyword arguments
Keyword arguments. The valid keywords are the keywords for the __init__ method of GMapOptions.
Methods
clear
()Clears all plotted data on the map. plot
(x[, index, text, color, s])Plots data onto the map. -
plot
(x, index=None, text=None, color='Blue', s=30)[source]¶ Plots data onto the map.
This function allows data in the form of latitude-longitude coordinates to be plotted on the map. Supports coloring by index or name as well as text labels.
Parameters: x : numpy.ndarray
A numpy array containing data to be plotted. Dimensions must be n * 2, where n is the number of data points. The first column is the latitude and the second column is the longitude.
index : numpy.ndarray or list, optional
A numpy array or list containing indices for coloring the data. Dimensions must be n * 1, where n is the number of data points. If not provided, data is colored with color.
text : numpy.ndarray, optional
A numpy array containing string labels for each data point. Dimensions must be n * 1, where n is the number of data points.
color : string, optional
A string specifying the color of the data points (the default is blue). Used if index is not provided.
s : int, optional
An int specifying the size of the data points (the default is 30).
-