I found that it is possible to disable scientific notation for numpy objects with np.set_printoptions(suppress=True)
. It does not however work for 'normal' variables, i.e. not numpy python floats:
a = 0.0000000000000000001
b = np.array([a])
print(a)
print(b)
The output is
1e-19
[0.]
and we see that the variable a
is still printed with scientific notation. Is there a way to completely disable scientific notation for all variables in python?
In R you can do it for virtually every scenario with options(scipen=999)
:
> 0.000000001
[1] 1e-09
> options(scipen=999)
> 0.000000001
[1] 0.000000001
> 0.0000000000000000000000000000000001
[1] 0.0000000000000000000000000000000001