plotCurves bug fixed