MATLAB: Mark max value and min value with red circle

max

Hey I need to mark max and min value of this graph with a red circle.
f = importdata("croc.txt");
deviation = f.data(:,1);
dates = f.textdata;
x = datenum(dates, "yyyy/mm");
y = deviation;
figure(1);
plot(x,y)
datetick('x','yyyy')
How can I then mark min and max peak with red circle?

Best Answer

[~,imx]=max(y);
[~,imn]=min(y);
hold on
plot(x([imn;imx]),y([imn;imx]),'or')
or as I was going to do originally as noted in comment:
ix=[imn;imx];
plot(x(ix),y(ix),'or')