How to display all the columns and rows in the a Jupyter notebook output

Here’s the code I use in my jupyter notebook to display all the columns, rows, and characters. I usually put in the beginning of my notebook, after the import statements.

# set display options
pd.set_option('display.max_columns', None)
pd.set_option('display.max_rows', None)
pd.set_option('display.max_colwidth', -1)

How to print all the output of a cell in Jupyter notebook.

Normally, Jupyter notebook only displays the last output of the cell; all others are ignored unless you use the print() function (for Python 3).

For example:


Jupyter only displays the following as the output:


3, the output for 1+2 gets totally ignored. The simple hack below will fix this.

from IPython.core.interactiveshell import InteractiveShell  InteractiveShell.ast_node_interactivity = "all"

Basically, put the code above in the beginning of your notebook and voilĂ , all the output is printed.