Skip to content

Commit d3be761

Browse files
author
y-p
committed
Merge pull request #5599 from y-p/PR_doc_set_max_rows
DOC: limit code snippet output to max_rows=15
2 parents 4264e99 + 313bd50 commit d3be761

23 files changed

+49
-8
lines changed

doc/source/10min.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
import pandas as pd
1414
np.set_printoptions(precision=4, suppress=True)
1515
options.display.mpl_style='default'
16+
options.display.max_rows=15
1617
1718
#### portions of this were borrowed from the
1819
#### Pandas cheatsheet

doc/source/basics.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
randn = np.random.randn
1010
np.set_printoptions(precision=4, suppress=True)
1111
from pandas.compat import lrange
12+
options.display.max_rows=15
1213
1314
==============================
1415
Essential Basic Functionality

doc/source/comparison_with_r.rst

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,12 @@
11
.. currentmodule:: pandas
22
.. _compare_with_r:
33

4+
.. ipython:: python
5+
:suppress:
6+
7+
from pandas import *
8+
options.display.max_rows=15
9+
410
Comparison with R / R libraries
511
*******************************
612

doc/source/computation.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
import matplotlib.pyplot as plt
1414
plt.close('all')
1515
options.display.mpl_style='default'
16+
options.display.max_rows=15
1617
1718
Computational tools
1819
===================

doc/source/cookbook.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
import os
1111
np.random.seed(123456)
1212
from pandas import *
13+
options.display.max_rows=15
1314
import pandas as pd
1415
randn = np.random.randn
1516
randint = np.random.randint

doc/source/dsintro.rst

Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,6 @@
11
.. currentmodule:: pandas
22
.. _dsintro:
33

4-
************************
5-
Intro to Data Structures
6-
************************
7-
8-
We'll start with a quick, non-comprehensive overview of the fundamental data
9-
structures in pandas to get you started. The fundamental behavior about data
10-
types, indexing, and axis labeling / alignment apply across all of the
11-
objects. To get started, import numpy and load pandas into your namespace:
124

135
.. ipython:: python
146
:suppress:
@@ -18,6 +10,17 @@ objects. To get started, import numpy and load pandas into your namespace:
1810
randn = np.random.randn
1911
np.set_printoptions(precision=4, suppress=True)
2012
set_option('display.precision', 4, 'display.max_columns', 8)
13+
options.display.max_rows=15
14+
15+
16+
************************
17+
Intro to Data Structures
18+
************************
19+
20+
We'll start with a quick, non-comprehensive overview of the fundamental data
21+
structures in pandas to get you started. The fundamental behavior about data
22+
types, indexing, and axis labeling / alignment apply across all of the
23+
objects. To get started, import numpy and load pandas into your namespace:
2124

2225
.. ipython:: python
2326

doc/source/enhancingperf.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
import csv
1010
from pandas import DataFrame
1111
import pandas as pd
12+
pd.options.display.max_rows=15
1213
1314
import numpy as np
1415
np.random.seed(123456)

doc/source/faq.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ Frequently Asked Questions (FAQ)
1212
import numpy as np
1313
np.random.seed(123456)
1414
from pandas import *
15+
options.display.max_rows=15
1516
randn = np.random.randn
1617
randint = np.random.randint
1718
np.set_printoptions(precision=4, suppress=True)

doc/source/gotchas.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
import os
88
import numpy as np
99
from pandas import *
10+
options.display.max_rows=15
1011
randn = np.random.randn
1112
np.set_printoptions(precision=4, suppress=True)
1213
from pandas.compat import lrange

doc/source/groupby.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
import numpy as np
88
np.random.seed(123456)
99
from pandas import *
10+
options.display.max_rows=15
1011
randn = np.random.randn
1112
np.set_printoptions(precision=4, suppress=True)
1213
import matplotlib.pyplot as plt

0 commit comments

Comments
 (0)