Wednesday, December 19, 2018

QuickTip: Default Color Cycle in Matplotlib

For reasonably recent versions of matplotlib [v > 1.5], you can extract the default color scheme into a string array by:

clr = [p['color'] for p in plt.rcParams['axes.prop_cycle']]

No comments:

Post a Comment