Old matplotlib style


In [6]:
import prettyplotlib as ppl

# prettyplotlib imports 
import matplotlib.pyplot as plt
from prettyplotlib import mpl
from prettyplotlib import brewer2mpl

# Set the random seed for consistency
np.random.seed(12)

fig, ax = plt.subplots(1)

# Show the whole color range
for i in range(8):
    y1 = np.random.normal(size=1000).cumsum()
    y2 = np.random.normal(size=1000).cumsum()
    x = np.arange(1000)

    ax.fill_betweenx(x, y1, y2, label=str(i))
    
ax.legend()

fig.savefig('fill_betweenx_matplotlib_default.png')


Prettyplotlib


In [7]:
import prettyplotlib as ppl

# prettyplotlib imports 
import matplotlib.pyplot as plt
from prettyplotlib import mpl
from prettyplotlib import brewer2mpl

# Set the random seed for consistency
np.random.seed(12)

fig, ax = plt.subplots(1)

# Show the whole color range
for i in range(8):
    y1 = np.random.normal(size=1000).cumsum()
    y2 = np.random.normal(size=1000).cumsum()
    x = np.arange(1000)

    ppl.fill_betweenx(x, y1, y2, label=str(i))
    
ax = ppl.legend()

fig.savefig('fill_betweenx_prettyplotlib_default.png')



In [ ]: