Is it possible to query the current state of the matplotlib color cycle? In other words is there a function get_cycle_state that will behave in the following wa
get_cycle_state
In matplotlib version 2.2.3 there is a get_next_color() method on the _get_lines property:
get_next_color()
_get_lines
import from matplotlib import pyplot as plt fig, ax = plt.subplots() next_color = ax._get_lines.get_next_color()
get_next_color() returns an html color string, and advances the color cycle iterator.