Azzera filtri
Azzera filtri

Combine scatter3 with a map plot?

3 visualizzazioni (ultimi 30 giorni)
HRmatlab
HRmatlab il 6 Dic 2017
Risposto: Chad Greene il 30 Mag 2018
I have flight data (Longitude, Latitude, Altitude, property_x) from an airborne experiment. The data is plotted and colored by property_x using the scatter3 function: scatter3(Longitude, Latitude, Altitude, point size, property_x); This works very well and produces the desired 3D plot and I can easily set the colorbar and its limits. However, I was trying to find a way to plot this over a specific geographical area map defined by the Longitude, Latitude limits. In other words, I want to the existing scatter3 plot to be over a map in the XY plane. I have not found a way to do this.
Alternatively, I generated the desired map and used plot3m to plot my data but plot3m does not use a colorbar and it's not easy to adjust the colors of the flight data.
Any help would be greatly appreciated. Thank you

Risposte (1)

Chad Greene
Chad Greene il 30 Mag 2018
You can do the coordinate transformation yourself and plot over a map pretty easily. First, make the base map just as if you were about to use plot3m. Then do this:
[x,y] = mfwdtran(lat,lon),
scatter3(x,y,z,30,c,'filled')

Prodotti

Community Treasure Hunt

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

Start Hunting!

Translated by