%% Downsample the Prism Colormap
% Create a scatter plot with the default colors.

x = [3.5 3.3 5 6.1 4 2];
y = [14 5.7 12 6 8 9];
sz = 100*[6 100 20 3 15 20];
c = [1 2 3 4 5 6];
scatter(x,y,sz,c,'filled','MarkerEdgeColor','k','MarkerFaceAlpha',.5);
xlim([1 7]);
ylim([1 16]);

%
% Get the prism colormap array with six entries. Then replace the colormap in the scatter plot.

c = prism(6);
colormap(c);

% Copyright 2012 The MathWorks, Inc.