i got this result after FindSegment (1,1)
Error in FindSegment/myCallBack (line 60) myplot();Error while evaluating figure WindowButtonMotionFcnUndefined function or variable 'myplot'.Error in FindSegment/myCallBack (line 60) myplot();Error while evaluating figure WindowButtonMotionFcnUndefined function or variable 'myplot'.Error in FindSegment/myCallBack (line 60)
my full code is in this attachment
Best Answer