summaryrefslogtreecommitdiff
path: root/numpy/matlib.py
diff options
context:
space:
mode:
Diffstat (limited to 'numpy/matlib.py')
-rw-r--r--numpy/matlib.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/numpy/matlib.py b/numpy/matlib.py
index 06bbaa02b..f55f763c3 100644
--- a/numpy/matlib.py
+++ b/numpy/matlib.py
@@ -160,10 +160,10 @@ def identity(n,dtype=None):
Examples
--------
>>> import numpy.matlib
- >>> np.identity(3, dtype=int)
- array([[1, 0, 0],
- [0, 1, 0],
- [0, 0, 1]])
+ >>> np.matlib.identity(3, dtype=int)
+ matrix([[1, 0, 0],
+ [0, 1, 0],
+ [0, 0, 1]])
"""
a = array([1]+n*[0],dtype=dtype)