Tags: colors, coordinates, graph, helloi, map, matlab, programming, size, terrainheight, vectors
2D graph with colors
On Programmer » Matlab
1,705 words with 1 Comments; publish: Tue, 06 May 2008 23:45:00 GMT; (20062.50, « »)
Hello
I have three vectors: X, Y, Z.
Each of them has size 16.
In X and Y i have "coordinates on the map" and in Z i have "terrain
height".
I wanted to draw it using meshz(X,Y,Z), but the problem was that i had
only very few points which described my terrain (only 18 points, and each
of them describe location and it's height). And i do not want to use "any
interpolation".
So i decided to draw it using 2D (for example plot) - i want to draw 18
dots and each dot's color should describe height (for example, if it's
higher it sould be more red).
Is there any function which could do it for me (like mesh), or i have to
do it by hand ?
Thanx for any help.
Michal
http://matlab.itags.org/q_matlab_981.html
All Comments
Leave a comment...
- 1 Comments

- "vertigo" <null.matlab.itags.org.com.pl> wrote in message news:op.s0uvlsq5zn8jyu.matlab.itags.org.highland...
> Hello
> I have three vectors: X, Y, Z.
> Each of them has size 16.
> In X and Y i have "coordinates on the map" and in Z i have "terrain
> height".
> I wanted to draw it using meshz(X,Y,Z), but the problem was that i had
> only very few points which described my terrain (only 18 points, and each
> of them describe location and it's height). And i do not want to use "any
> interpolation".
> So i decided to draw it using 2D (for example plot) - i want to draw 18
> dots and each dot's color should describe height (for example, if it's
> higher it sould be more red).
> Is there any function which could do it for me (like mesh), or i have to
> do it by hand ?
Look at the SCATTER and SCATTER3 functions.
Steve Lord
slord.matlab.itags.org.mathworks.com
#1; Tue, 06 May 2008 23:47:00 GMT