1
1
from __future__ import absolute_import , division , print_function
2
2
3
- from larray .util .misc import basestring
4
-
5
3
6
4
__all__ = ['set_options' , 'get_options' ]
7
5
@@ -52,6 +50,7 @@ class set_options(object):
52
50
Currently supported options:
53
51
54
52
- ``display_precision``: number of digits of precision for floating point output.
53
+ Print as many digits as necessary to uniquely specify the value by default (None).
55
54
- ``display_width``: maximum display width for ``repr`` on larray objects. Defaults to 80.
56
55
- ``display_maxlines``: Maximum number of lines to show. All lines are shown if -1.
57
56
Defaults to 200.
@@ -91,6 +90,11 @@ class set_options(object):
91
90
a497 49700.12 49701.12 49702.12 ... 49797.12 49798.12 49799.12
92
91
a498 49800.12 49801.12 49802.12 ... 49897.12 49898.12 49899.12
93
92
a499 49900.12 49901.12 49902.12 ... 49997.12 49998.12 49999.12
93
+
94
+ To put back the default options, you can use:
95
+
96
+ >>> set_options(display_precision=None, display_width=80, display_maxlines=200, display_edgeitems=5)
97
+ ... # doctest: +SKIP
94
98
"""
95
99
96
100
def __init__ (self , ** kwargs ):
@@ -118,7 +122,7 @@ def get_options():
118
122
-------
119
123
Dictionary of current print options with keys
120
124
121
- - display_precision: int
125
+ - display_precision: int or None
122
126
- display_width: int
123
127
- display_maxlines: int
124
128
- display_edgeitems : int
@@ -134,4 +138,4 @@ def get_options():
134
138
>>> get_options()
135
139
{'display_precision': None, 'display_width': 80, 'display_maxlines': 200, 'display_edgeitems': 5}
136
140
"""
137
- return _OPTIONS .copy ()
141
+ return _OPTIONS .copy ()
0 commit comments