Importing Spreadsheets or CSV files¶

Many times the GIS data comes in a table or an Excel spreadsheet. As well, if y'all have a list lat/long coordinates, you can easily import this data in your GIS project.

Overview of the job¶

We volition be importing a text file of earthquake data to QGIS.

Go the data¶

NOAA'southward National Geophysical Data Center produces a great dataset of all significant earthquakes since 2150 BC. Learn more.

Download Significant Convulsion Database text file.

For convenience, yous may directly download a copy of both the datasets from the links beneath:

signif.txt

Data Source [NCEI]

Procedure¶

  1. Examine your tabular data source. To import this information to QGIS, you volition have to save it equally a text file and demand at least 2 columns which comprise the X and Y coordinates. If you lot accept a spreadsheet, apply Salve As function in your program to save it every bit a Tab Delimited File or a Comma Separated Values (CSV) file. In one case you accept the data exported this way, yous can open information technology in a text editor such as Notepad to view the contents. In case of the Significant Earthquake Database, the data already comes as a text file which contains latitude and longitude of the earthquake centers along with other related attributes. Y'all will see that each field is separated by a TAB.

../_images/1174.png
  1. Open QGIS. Click on .

../_images/2140.png
  1. In the Create a Layer from a Delimited Text File dialog, click on Browse and specify the path to the text file y'all downloaded. In the File format section, select Custom delimiters and check Tab. The Geometry definition secction volition exist auto-populated if it finds a suitable 10 and Y coordinate fields. In our example they are LONGITUDE and LATITUDE. Yous may change it if the import selects the wrong fields. Click OK.

Annotation

Information technology is piece of cake to confuse X and Y coordinates. Latitude specifies the n-south position of a point and hence it is a Y coordinate. Similarly Longitude specifies the east-west position of a point and it is a X coordinate.

../_images/375.png
  1. You may see some errors displayed in the next dialog. The erros in this file are mainly due to missing X or Y fields. Yous may examine these errors and set up the problems in your source file. For this tutorial, you may ignore these errors.

../_images/446.png
  1. Next, a Coordinate Reference System Selector volition ask y'all to select a coordinate reference system. Since the earthquake coordinates are in latitudes and longitudes, yous should select WGS 84. Click OK.

../_images/547.png
  1. You volition now see that the information will be imported and displayed in the QGIS sheet.

../_images/645.png

comments powered by