How to set number of digits for float point output in Ipython

ipython

Solution

If you are using numpy a lot, then `numpy.set_printoptions` lets you tweak that.

Another option is to use the magic `%precision` command (only in IPython 0.11 or greater).

I guess that you can put your defaults in your startup configuration file.

Problem

In octave the output of float point numbers is limited by default to 4 digits (%.4f). Is there a way to set this behavior using IPython?

Original source