I am plotting two time series and computing varies indices for them.
How to write these indices for these plots outside the plot using annotation
or t
Looks like the text is there but it lies outside of the figure boundary. Use subplots_adjust() to make room for the text:
import matplotlib.pyplot as plt
textstr = 'NSE=%.2f\nRMSE=%.2f\n'%(1, 2)
plt.xlim(2002, 2008)
plt.ylim(0, 4500)
# print textstr
plt.text(2000, 2000, textstr, fontsize=14)
plt.grid(True)
plt.subplots_adjust(left=0.25)
plt.show()