plt.pause( code example Example: draw networkx graph using plt.pause plt.clf() nx.draw(G) plt.pause(1) # 1 here is time gap