One of the most common routines in the use of Geographic Information Systems is the construction of spatial layers based on information from the field. Whether this represents coordinates, plot vertices or elevation lattices, the information usually comes in comma-separated files or Excel spreadsheets.
1. The geographic coordinates file in Excel.
In this case, I am trying to import the human settlements of the Republic of Cuba, which I have Diva-GIS, Which by the way is one of the best sites to download geographic data from any country. As you can see, columns B and C contain information on latitude and longitude in the form of Geographical coordinates.
2 Import the file in QGIS
To import the coordinates of the Excel file, it is done:
Vector> XY tools> OpenExcele file as attribute table or Point layer
In case the file is saved with extension .xlsx the browser will not show it, because it filters only files with extension .xls. Non is problem, we can apply old DOS techniques and write in rename, filter: *. * (Asterisk dot an asterisk) and enter; This will allow all files in that location to be viewed. We might have written * .xls and filtered only the .xls extension files.
Then we have a panel in which we must indicate which column corresponds to the coordinate in X, in this case we choose the column of length, the column of latitude for the coordinate Y.
And there we have it. The query shows that the layer has been saved with the data contained in Cuba's human settlements file, which includes the name, latitude, longitude, classification and administrative province.
3. Create polygons from coordinates
In case, we want not only to import the vertices but also to create a polygon in the order of these coordinates, we can use the plugin Points2One. This plugin allows you to identify what the target layer will be called, if what we import will be built as lines or as a polygon.