How can I round and replace an array at the same time? My code line:
plt.text(*max_p_tranformed[:-1][0]+1, *max_p_tranformed[:-1][1], (str(np.round(deflp1[idx]),2).replace(' [', '').replace('[', '').replace(']', '')))
And the return is: str() argument 2 must be str, not int
Any suggestion to overcome this?