Size: 10824
Comment:
|
Size: 11019
Comment:
|
Deletions are marked like this. | Additions are marked like this. |
Line 6: | Line 6: |
Warning: Web apps can break frequently due to websites or services changing locations or formats! | |
Line 69: | Line 69: |
import urllib2, csv | import urllib.request, csv, io |
Line 72: | Line 72: |
L = list(zip(range(1,13),longmonths)) | |
Line 73: | Line 74: |
def iceplotter(month = selector(zip(range(1,13),longmonths),default = (4, 'April'),label="Month")): month_str = months[month-1] + '/N_%02d_area.txt'%(month) |
def iceplotter(month = selector(L, default = 4, label="Month")): month_str = '/north/monthly/data/N_%02d_extent_v3.0.csv'%(month) |
Line 77: | Line 78: |
icedata_f = urllib2.urlopen('ftp://sidads.colorado.edu/DATASETS/NOAA/G02135/%s'%month_str) cr = csv.reader(icedata_f,delimiter=' ', dialect=dialect) icedata = list(cr) |
icedata_f = urllib.request.urlopen('ftp://sidads.colorado.edu/DATASETS/NOAA/G02135%s'%month_str) cr = csv.reader(io.StringIO(icedata_f.read().decode()), delimiter=',', dialect=dialect) icedata = [row for row in cr] |
Line 99: | Line 100: |
html('<h3>Extent of Arctic sea ice coverage in %s, %d - %d</h3>'%(longmonths[month-1],min(years),max(years))) html('Data from the <a href="http://nsidc.org/">National Snow and Ice Data Center</a>') |
pretty_print(html('<h3>Extent of Arctic sea ice coverage in %s, %d - %d</h3>'%(longmonths[month-1],min(years),max(years)))) pretty_print(html('Data from the <a href="http://nsidc.org/">National Snow and Ice Data Center</a>')) |
Sage Interactions - Web applications
goto interact main page
Contents
Warning: Web apps can break frequently due to websites or services changing locations or formats!
CO2 data plot, fetched from NOAA
by Marshall Hampton
One can do many things with scipy.stats. This only scratches the surface.
Arctic sea ice extent data plot, fetched from NSIDC
by Marshall Hampton
Pie Chart from the Google Chart API
by Harald Schilly
Stock Market data, fetched from Yahoo and Google FIXME
by William Stein
(Need to fix plotting warnings as well as some stocks give index errors (like bcc), and Python 3 changes, etc.)