Contact
CoCalc Logo Icon
StoreFeaturesDocsShareSupport News AboutSign UpSign In
| Download

All published worksheets from http://sagenb.org

Views: 168733
Image: ubuntu2004
import urllib from xml.dom import minidom url = 'http://cell.electrostallion.com/images/sample.xml' doc = minidom.parse(urllib.urlopen(url)) #doc = minidom.parse('/Volumes/home/Applications/FD1097E2-B8D9-47D9-9910-3F9#AE7/Documents/2009-03-19_132739.xml') S = [] for a in doc.childNodes: for b in a.childNodes: if b.nodeName == "samples": for c in b.childNodes: if c.nodeName == "sample": x = float(c.childNodes[3].firstChild.data) y = float(c.childNodes[1].firstChild.data) S.append((x,y)) Sp = list_plot(S,rgbcolor=(.5,.5,.5)) show (Sp, figsize=[10,5])