Matlab v7.5 still has trouble with vector graphics. When trying to create a vector image it, instead, generates a bitmap image if you use rgb colors (for example in scatter) instead of colormap indices.
Here's an example:

But there is a workaround. Instead of doing this:
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
scatter(data(:,1), data(:,2), size, rgb, 'filled'); |
Do it like this to be able to export in vector format (like eps):
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
colormap(rgb); | |
n = size(rgb, 1); | |
indices = cumsum( ones(n,1) ); | |
scatter(data(:,1), data(:,2), size, indices, 'filled'); |
Now each point, instead of being colored by the rgb data, it is indexed to the custom colormap, which is exactly made up of the rgb data we want. Now it is possible to export to vector.
(Sorry, blogger doesn't like svg.)