diff options
author | Stefan van der Walt <stefan@sun.ac.za> | 2009-07-04 12:45:31 +0000 |
---|---|---|
committer | Stefan van der Walt <stefan@sun.ac.za> | 2009-07-04 12:45:31 +0000 |
commit | f826c7b7f2719a95731da14102d28cc7f3147c01 (patch) | |
tree | 58fb20c2f06a8f480d80c901abe9d36d2d90c83d /numpy/lib/io.py | |
parent | a3a99e2f84e36ef876094494464e6bcecb7ee0ab (diff) | |
download | numpy-f826c7b7f2719a95731da14102d28cc7f3147c01.tar.gz |
Add example to savez.
Diffstat (limited to 'numpy/lib/io.py')
-rw-r--r-- | numpy/lib/io.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/numpy/lib/io.py b/numpy/lib/io.py index 9199a0de2..3a962c7e1 100644 --- a/numpy/lib/io.py +++ b/numpy/lib/io.py @@ -300,6 +300,12 @@ def savez(file, *args, **kwds): The .npz file format is a zipped archive of files named after the variables they contain. Each file contains one variable in .npy format. + Examples + -------- + >>> x = np.random.random((3, 3)) + >>> y = np.zeros((3, 2)) + >>> np.savez('data', x=x, y=y) + """ # Import is postponed to here since zipfile depends on gzip, an optional |