MATLAB 3D MESH PLOT USING PEAKS FUNCTION

4 Ansichten (letzte 30 Tage)
Samuel Olatunji
Samuel Olatunji am 24 Aug. 2013
Pls I have this serious issue regarding plotting a particular set of data in 3D using Matlab mesh plot along with the 'peaks' function
My values are given below: LAT = [8.46241;8.46523;8.46529;8.4661;8.46329;8.45955;8.46096;8.46732;8.46818;8.4674;8.46775;8.46609;8.4674;8.4687;8.46984]; LONG = [4.52119;4.52215;4.52374;4.52899;4.52898;4.52625;4.52363;4.51978;4.52141;4.52355;4.52532;4.52715;4.52822;4.52809;4.52693]; ELEVATION = [3.40 ;3.32 ;3.30; 3.20;3.22;3.26;3.30;3.30;3.25;3.20;3.32;3.31;3.25;3.22;0];
I need to plot Latitude (LAT) vs Longitude (LONG) on the X , Y axis respectively and then Elevation on the Z axis.
The plot I'm getting using codes such as this: LAT = [8.46241;8.46523;8.46529;8.46612;8.46329;8.45955;8.46096;8.46732;8.46818;8.4674;8.46775;8.46609;8.4674;8.4687;8.46984]; LONG = [4.52119;4.52215;4.52374;4.52899;4.52898;4.52625;4.52363;4.51978;4.52141;4.52355;4.52532;4.52715;4.52822;4.52809;4.52693]; ELEVATION = [3.40 ;3.32 ;3.30; 3.20;3.22;3.26;3.30;3.30;3.25;3.20;3.32;3.31;3.25;3.22;0];
[LAT,LONG,ELEVATION]=peaks; figure mesh(LAT,LONG,ELEVATION);
axis tight; xlabel('Lat(Deg)'); ylabel('Long (Deg)'); zlabel('Elevation (100m)');
Is just giving me the default 3D plot that Matlab generates, i.e. my data is not included in the plot.
Please how do i go about it?
Please...

Antworten (0)

Kategorien

Mehr zu 2-D and 3-D Plots finden Sie in Help Center und File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by