Menu

[r1078]: / trunk / course / examples / mpl_set_get.py  Maximize  Restore  History

Download this file

15 lines (13 with data), 439 Bytes

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
from pylab import *
x = rand(20); y = rand(20)
lines = plot(x,y,'o')
type(lines) # plot always returns a list
len(lines) # even if it is lenght 1
savefig('../fig/mpl_set_get1')
get(lines)
set(lines)
set(lines, markerfacecolor='green', markeredgecolor='red',
markersize=20, markeredgewidth=3, linestyle='--', linewidth=3)
t = xlabel('time (s)')
set(t, fontsize=20, color='darkslategray')
savefig('../fig/mpl_set_get2')
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.