Search All of the Math Forum:
Views expressed in these public forums are not endorsed by
NCTM or The Math Forum.


Oliver
Posts:
30
Registered:
4/14/09


plot points with dynamic colour
Posted:
Mar 23, 2012 6:51 AM


Hi all,
I'm trying to plot a large amount of data with colour of the point representing some of the data.
I have some position data and speed data. I want to plot the lat and longs of the data and colour the points based on their value.
something like this... DATA is a structure and ValidTimes a logical array.
R = 160./abs([DATA(ValidTimes).Speed]); %160 is max speed in the data set G = R.*0; B = R.*0;
plot([DATA(ValidTimes).PlotLongitude],[DATA(ValidTimes).PlotLatitude],'Color',[R G B],'Marker','.','LineStyle','none')
'Color' can only be a 3 element numeric vector, I could loop through all the ValidTimes but there are thousands of points and it takes a while, any ideas?
cheers, Ollie



