Plotting google earth polygon data in a longitude latitude grid
Afficher commentaires plus anciens
I am stuck with the following:
I have a data set with google earth polygons (in a .kml) file and want to process this in matlab. The data set consists of polygons at many different positions(latitude longitude). I want to use this as a mask on an exisiting gridded latitude longitude DEM, so want to set values of the DEM inside the Polygons to zero (or NaN).
The problem is I have no idea how the original google earth file is formatted and using the Google Earth toolbox I cannot figure it out. Could somebody give me a hint how to process google earth data in matlab in general (i can't really get it to work, I only manage to output existing gridded data into .kml/.kmz files but not the other way around).
Right now I am trying to interpolate the polygon data on the original grid, but as said, the problem is how the .kml is structured...When I input the .kml data with kmlread I get 3 vectors: a latitude, longitude and a z vector only consisting of zeros (and this is a 40000x1 vector, consisting of many small polygons (I presume)).
Thanks in advance!
Réponses (2)
JMvanwessem
le 13 Fév 2012
1 vote
Athmajan Vivekananthan
le 31 Juil 2018
0 votes
I encountered a similar problem but what I wanted was coordinates of the points of the google earth KML polygon. What I did was I opened KML file in notepad and read the text file in Matlab to manipulate the coordinate values
Catégories
En savoir plus sur Standard File Formats dans Centre d'aide et File Exchange
Produits
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!