109 coordinate grids
Uncomment the following line to install geemap if needed.
In [ ]:
Copied!
# !pip install geemap
# !pip install geemap
Import libraries.
In [ ]:
Copied!
import ee
import geemap
import ee
import geemap
In [ ]:
Copied!
Map = geemap.Map()
Map = geemap.Map()
Create a latitude grid.
In [ ]:
Copied!
lat_grid = geemap.latitude_grid(step=5.0, west=-180, east=180, south=-85, north=85)
lat_grid = geemap.latitude_grid(step=5.0, west=-180, east=180, south=-85, north=85)
In [ ]:
Copied!
Map.addLayer(lat_grid, {}, 'Latitude Grid')
Map.addLayer(lat_grid, {}, 'Latitude Grid')
In [ ]:
Copied!
Map
Map
Convert ee.FeatureCollection
to pandas.DataFrame
.
In [ ]:
Copied!
df = geemap.ee_to_df(lat_grid)
df
df = geemap.ee_to_df(lat_grid)
df
Create a longitude grid.
In [ ]:
Copied!
lon_grid = geemap.longitude_grid(step=5.0, west=-180, east=180, south=-85, north=85)
lon_grid = geemap.longitude_grid(step=5.0, west=-180, east=180, south=-85, north=85)
In [ ]:
Copied!
Map = geemap.Map()
Map.addLayer(lon_grid, {}, 'Longitude Grid')
Map
Map = geemap.Map()
Map.addLayer(lon_grid, {}, 'Longitude Grid')
Map
Create a rectangular grid.
In [ ]:
Copied!
grid = geemap.latlon_grid(
lat_step=10, lon_step=10, west=-180, east=180, south=-85, north=85
)
grid = geemap.latlon_grid(
lat_step=10, lon_step=10, west=-180, east=180, south=-85, north=85
)
In [ ]:
Copied!
Map = geemap.Map()
Map.addLayer(grid, {}, 'Coordinate Grid')
Map
Map = geemap.Map()
Map.addLayer(grid, {}, 'Coordinate Grid')
Map