Menu

Tree [r6044] / trunk / toolkits / basemap / examples /
 History

HTTPS access


File Date Author Commit
 200706041200-msg-ch01-SAfrica.jpg 2007-06-04 jswhit [r3355] geostationary example contributed by Scott Sinc...
 500hgtdata.gz 2006-02-28 jswhit [r2114] add data files back in
 500hgtlats.gz 2006-02-28 jswhit [r2114] add data files back in
 500hgtlons.gz 2006-02-28 jswhit [r2114] add data files back in
 NetCDFFile_tst.py 2008-08-09 jswhit [r6014] added NetCDFFile test
 README 2008-08-17 jswhit [r6038] added cubed_sphere.py example
 barb_demo.py 2008-07-25 jswhit [r5872] update barb_demo comments.
 ccsm_popgrid.nc 2006-10-10 jswhit [r2801] new example from Ivan Lima (CCSM POP grid)
 ccsm_popgrid.py 2008-05-31 jswhit [r5342] use "import numpy.ma as ma" instead of "from nu...
 cities.dbf 2007-12-06 jswhit [r4659] add initial support for reading shapefiles with...
 cities.shp 2007-12-06 jswhit [r4659] add initial support for reading shapefiles with...
 cities.shx 2007-12-06 jswhit [r4659] add initial support for reading shapefiles with...
 contour_demo.py 2008-05-17 jswhit [r5168] convert to pyplot/numpy namespace
 cubed_sphere.py 2008-08-18 jswhit [r6041] another minor tweak
 customticks.py 2008-05-20 jswhit [r5196] convert more examples to numpy/pyplot namespace
 earth_lights_lrg.jpg 2008-02-15 jswhit [r4968] add warpimage method.
 etopo20data.gz 2006-02-28 jswhit [r2114] add data files back in
 etopo20lats.gz 2006-02-28 jswhit [r2114] add data files back in
 etopo20lons.gz 2006-02-28 jswhit [r2114] add data files back in
 fcover.dat 2005-04-16 jswhit [r1199] data file for quiver_demo.py
 fcstmaps.py 2008-06-06 jswhit [r5413] fix typos
 fillstates.py 2008-05-20 jswhit [r5197] more examples updated to numpy/pyplot namespace
 garp.py 2008-05-20 jswhit [r5197] more examples updated to numpy/pyplot namespace
 geos_demo.py 2008-08-02 jswhit [r5956] make land_color, ocean_color kwargs in drawlsmask
 geos_demo_2.py 2008-05-20 jswhit [r5196] convert more examples to numpy/pyplot namespace
 geos_demo_3.py 2008-05-20 jswhit [r5196] convert more examples to numpy/pyplot namespace
 hires.py 2008-05-20 jswhit [r5196] convert more examples to numpy/pyplot namespace
 huralll020.dbf 2006-06-09 jswhit [r2461] update for hurricanes thru 2004
 huralll020.shp 2006-06-09 jswhit [r2460] update for hurricanes thru 2004
 huralll020.shx 2006-06-09 jswhit [r2460] update for hurricanes thru 2004
 hurrtracks.py 2008-05-20 jswhit [r5197] more examples updated to numpy/pyplot namespace
 land_shallow_topo_2048.jpg 2006-07-26 jswhit [r2614] image for warpimage.py demo
 nws_precip_conus_20061222.nc 2007-05-25 jswhit [r3298] data file for plotprecip.py example.
 nytolondon.py 2008-05-20 jswhit [r5196] convert more examples to numpy/pyplot namespace
 ortho_demo.py 2008-08-02 jswhit [r5956] make land_color, ocean_color kwargs in drawlsmask
 panelplot.py 2008-05-20 jswhit [r5197] more examples updated to numpy/pyplot namespace
 plot_tissot.py 2008-07-14 jswhit [r5770] add moll and robin examples
 plotcities.py 2008-05-31 jswhit [r5340] replace "faceted=False" with "edgecolors='none'...
 plotmap.py 2008-05-17 jswhit [r5166] convert to pyplot/numpy namespace
 plotmap_masked.py 2008-05-31 jswhit [r5342] use "import numpy.ma as ma" instead of "from nu...
 plotmap_oo.py 2008-05-17 jswhit [r5166] convert to pyplot/numpy namespace
 plotprecip.py 2008-05-20 jswhit [r5197] more examples updated to numpy/pyplot namespace
 plotsst.py 2008-05-20 jswhit [r5197] more examples updated to numpy/pyplot namespace
 pnganim.py 2008-06-05 jswhit [r5393] adjust for new num2date defaults.
 polarmaps.py 2008-05-20 jswhit [r5197] more examples updated to numpy/pyplot namespace
 quiver_demo.py 2008-05-20 jswhit [r5196] convert more examples to numpy/pyplot namespace
 randompoints.py 2008-05-31 jswhit [r5340] replace "faceted=False" with "edgecolors='none'...
 run_all.py 2008-08-06 jswhit [r5985] update warpimage, include plotsst
 setwh.py 2008-05-20 jswhit [r5197] more examples updated to numpy/pyplot namespace
 show_colormaps.py 2008-05-20 jswhit [r5197] more examples updated to numpy/pyplot namespace
 simpletest.py 2008-05-16 jswhit [r5157] convert more examples to pyplot and numpy names...
 simpletest_oo.py 2008-05-20 jswhit [r5198] more examples converted to numpy/pyplot namespace.
 st99_d00.dbf 2006-06-09 jswhit [r2457] update state shape files for fillstates.py
 st99_d00.shp 2006-06-09 jswhit [r2457] update state shape files for fillstates.py
 st99_d00.shx 2006-06-09 jswhit [r2457] update state shape files for fillstates.py
 test.py 2008-08-09 jswhit [r6012] print proj4string attribute.
 testgdal.py 2008-08-07 jswhit [r5995] fix another typo
 us_25m.dem 2008-08-07 jswhit [r5991] update testgdal example (now exercises more gda...
 warpimage.py 2008-08-06 jswhit [r5985] update warpimage, include plotsst
 wiki_example.py 2008-06-03 jswhit [r5373] forgot to plot circles in last plot (bluemarble...

Read Me

Basemap example scripts

simpletest.py is the simple example given in the Basemap docstrings.

simpletest_oo.py is the same example, but using the "OO" interface (does
not import pylab).

test.py exercises all the available map projections by plotting the etopo 
20 minute bathymetry/topography data using imshow.

contour_demo.py demonstrates the use of filled contours with map projections.

customticks.py shows how to create custom tick labels for a cylindrical
projection.

plotcities.py shows how to read and plot data from a shapefile containing
Point data.

plotmap.py is the example on the matplotlib 'screenshots' page (included
in test.py) which shows the ETOPO topography as an image on a Lambert
Conformal projection (using imshow).

plotmap_oo.py is a version of plotmap.py that does not import pylab - it uses
the matplotlib OO interface instead.

plotmap_masked.py is a version of plotmap.py that shows how to mask out
portions of the plot (in this case the oceans) using pcolor and imshow.

nytolondon.py shows how to draw a great circle on a map (NY to London)

hires.py illustrates the use of the high-resolution coastlines, by
drawing the coastlines, political boundaries and rivers of the British
Isles. Shows how to pickle and re-load a Basemap class instance (useful
for high-res coastlines when you are plotting the same small map region
many times in different scripts).

quiver_demo.py shows how to plot wind vectors on a map.

barbs_demo.py shows how to plot wind barbs on a map.

randompoints.py demonstrates the use of scatter to plot randomly distributed
points on the earth.

ortho_demo.py demonstrates the orthographic projection - you can interactively
enter the reference lat/lon (the viewpoint of the satellite). Also shows
how to plot the default 5 minute land-sea mask, specifying the colors
to be used for land and ocean areas.

geos_demo.py demonstrates the geostationary projection - you can interactively
enter the reference longitude and height above the equator of the
satellite.

geos_demo_2.py demonstrates how to read in a geostationary satellite image
from a jpeg file, then plot only a portion of the full earth (contributed
by Scott Sinclair, requires PIL).

geos_demo_3.py shows how to make a regional geostationary or orthographic 
plot, where part of the region is outside the projection limb.

fcstmaps.py is a sample multi-panel plot that accesses
data over http using the dap module. An internet connection is required.

plotsst.py also uses dap client to access the data, and also illustrates
how the NetCDFFile function deals with missing values.

wiki_example.py is the example from the MatplotlibCookbook scipy wiki page
(http://www.scipy.org/wikis/topical_software/MatplotlibCookbook/wikipage_view).

fillstates.py is an example that shows how to draw 
and fill polygons (in this case U.S. States) from
and ESRI shapefile. 

hurrtrack.py plots hurricane tracks from shapefile data 
(from nationalatlas.gov).

testgdal.py is an example that shows how to plot GIS data 
using the gdal module (http://gdal.maptools.org).

panelplot.py shows how to make multi-panel plots, taking special care to 
make sure that map aspect ratios are preserved (so you don't get squished
and/or stretched maps).

polarmaps.py illustrates the use of the special-case versions of the 
stereographic, lambert azimuthal equal area, azimuthal equidistant 
projections (prefixed by 'np' and 'sp').

warpimage.py shows how to use an image as a map background with the
'warpimage' and 'bluemarble' Basemap methods. Requires PIL.

garp.py makes a 'World According to Garp' map - an azimuthal equidistant
projection centered on a specified location.  Straight lines from that
location to any point on the map have true scale and show the shortest
route.  Shows how to use the 'width' and 'height' keywords
to specify the map projection region (instead of specifying
the lat/lon of the upper right and lower left corners).

More examples of using the 'width' and 'height' keywords (instead of
'llcrnrlat','llcrnrlon','urcrnrlat','urcrnrlon') are given in setwh.py.

plot_tissot.py - tissot's indicatrix, shows the distorting effects of
different map projections.

pnganim.py shows how to make an animation.

ccsm_popgrid.py shows how to plot data on 2d grids which are not 
rectilinear in map projection or geographic coordinates.  The NCAR
Parallel Ocean Program grid is used as an example.

show_colormaps.py plots the extra colormaps included with basemap.

plotprecip.py use nonlinear precip colormap included with basemap
to make a rainfall plot.

cubed_sphere.py - plot a "cubed globe" suitable for cutting and folding,
a la http://www.progonos.com/furuti/MapProj/Normal/ProjPoly/Foldout/Cube/cube.html.

run_all.py is a driver script that runs all the examples except fcstmaps.py,
testgdal.py, geos_demo_2.py, warpimage.py, and pnganim.py (which
rely on external dependencies and/or an internet connection).
Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.