I am trying to plot data (45*56*6) only inside polygon and i tried these steps
imported shapefile and run query to sperate data point inside and outside polygon as
isin = inpolygon(X,Y,S.X,S.Y);
test(:,:,i(~isin)) = NaN;
for i =1:6
but it did not work for me as
xyz here is equal to 45*56 2d data.
Any kind of help is appreciatable.