Tutorial: Collect Open Data from online sources
7. Import a CSV file
In this section we're going to import a CSV file with Ramsar sites in Malawi.
Ramsar sites can be downloaded from the Ramsar Sites Information Service. It contains 2,403 Sites covering 254,307,159 ha.
1. Browse to the Ramsar Sites Information Service.
2. Under Explore by filters choose Africa.
3. After the map with Ramsar sites in Africa has loaded choose Malawi from the list under Explore by filters.
4. After the map of Malawi is loaded choose the Exports tab.
5. Choose the CSV file under Format, type your e-mail address and click Generate.
You'll receive immediately an e-mail from the Ramsar Sites Information Service with the link to download the CSV file.
6. Download the CSV file to the folder of your GIS project.
7. Open the CSV file in a text editor such as Notepad and check the contents.
You can see that the first line contains the column headers. The columns are separated by commas. Strings are in double quotes. Because it has columns for latitude and longitude we can load the CSV file in a GIS as a points layer with the other columns as attributes.
8. Go back to QGIS
9. Click the Open Data Source Manager button .
10. Go to the Delimited Text tab by clicking
11. In the Delimited Text dialogue use to browse to the CSV file.
- Replace the Layer name with Ramsar sites Malawi.
- Check that under Geometry Definition the Longitude column is selected for the X field and the Latitude column is selected for the Y field. Choose EPSG: 4326 for the Geometry CRS. This information is needed to plot the file on the map.
12. Check the preview under Sample Data. If everything looks okay click Add and Close the dialogue.
Now the Ramsar sites Malawi layer is added to the Layers panel. This layer, however, is not yet a GIS vector file, so we need to export it and reproject the data to the UTM Zone 36S / WGS 84 projection like we did for the GeoNode data.
13. Click right on the Ramsar sites Malawi layer in the Layers panel and choose Export | Save Features As...
14. In the Save Vector Layer as... dialogue choose ESRI Shapefile as the output Format. Use the button to browse to the project folder and save the output layer as ramsar_sites_malawi.shp.
15. Click the Select CRS button .
16. In the Coordinate Reference System Selector type 32736 at Filter and select the WGS 84 / UTM zone 36 S projection.
17. Click OK to return to the Save Vector Layer as... dialogue, which should look like the figure below.
18. Click OK to perform the layer export.
After processing the layer is added to the map canvas.
19. Remove the Ramsar sites Malawi layer from the Layers panel (make sure you remove the CSV file! When you hover your mouse over the layer name it will display the file name and the projection in a tool tip).
21. Click on Simple marker and change the Symbol layer type to SVG marker. Under SVG Groups choose symbol and look for the red marker
22. Change the width and height to 12 mm.
The project should now look like the figure below.
In the next section we're going to add more data.