2

I consider myself an intermediate GIS user but keep running in a problem with the newest QGIS version I cannot fix and wonder if it may be a bug or if I am just too stupid. The problem mostly centers around reprojection in QGIS 2.4.0 under Windows 8.1. I am trying to reproject several files (world map shp file from NaturalEarth (ne_10m_land), Coastline map (ne_10m_coastline) or csv files) from WGS 84 to World Mercator as I need units in meters for a buffer analysis (global scale).
The world map (originally WGS 84) will reproject when the layer CRS is set to the new CRS (using Set Layer CRS) but trying to do a buffer analysis on the reprojected world map in World Mercator results in empty attribute tables. Same happens when saving the reprojected map in the new CRS (using Save as). The buffer analysis creates a new (empty) file but does not operate at all. Tried several other projected CRSs and it is either the same, the map won't reproject at all or QGIS crashes while trying to do it.
Trying to load the CSV file in a Projected CRS layer results in the layer having the new CRS but points being displayed somewhere completely different, no reprojection to other Projected CRS nor saving in new CRS changes that.
Glad for any help or information, thanks a lot!

  • It might help to exclude the poles from NE shapefiles if you want to use World Mercator. Otherwise, please explain your steps, and/or update to QGIS 2.6. – AndreJ Nov 28 '14 at 16:23
  • Thanks AndreJ - wasn't aware that there is a newer version. I will try this, maybe it works better. – Kristina Nov 28 '14 at 16:26
  • You might wait until next week, a bugfix version 2.6.1 is on its way... – AndreJ Nov 28 '14 at 17:07
  • Alright, good to know. So far same problems with the new version. – Kristina Nov 28 '14 at 17:30
  • The new version is out now, but I think it is rather a step you did not do the right way. Can you edit your question what files from NE you use, and what steps you do to reproject? – AndreJ Dec 1 '14 at 8:24
1

You are right, the way you want to reproject is wrong.

Set Layer CRS does NOT reproject your data, but assignes the new CRS to unchanged coordinates, making the world 360x180 meters large.

Save As... is the right way, but only on the original data, not on the corrupted data from the previous step.

The world map from natural Earth includes the south pole. That point can not be reprojected to World Mercator, because the poles end up in infinity with that projection. So you have to cut off the bottom line, or remove Antarctica if you don't need that part of the world. Since ne_10m_land is a multipart geometry, you might have to convert it into singleparts before you can delete the Antarctic.

  • You are right, I tried that, too. However, it does not save the world map in a new file, just gives me an error message or crashes. I guess it's got to do with the attribute table the file comes with with has ID 0. I loaded the coastline shp with has more attribute values in the blank canvas and saved it in the new CRS and the buffer analysis worked. It seemed to be the corrupted data as you said. However, the csv file still projects completely wrong, wrong location and wrong scale, even after saving it... – Kristina Dec 1 '14 at 14:35
  • Ok, the next pitfall ;-) See my extended answer on the South pole. I'm not sure what went wrong with CSV files. They should avoid the poles too. You have to save them as shapefile before you can do statistics on them. – AndreJ Dec 1 '14 at 16:10
  • Thanks for the hint with the Antarctic, looks very weird indeed. Will do that. Reprojection works fine with the coastal shp file, so I'll stick with that in the meantime. – Kristina Dec 1 '14 at 17:44
  • Regarding the csv file, saving as shapefile does not change anything - my point file for the North Pacific projects really cramped and tiny in the Gulf of Guinea off the west African coast. Tried to load it first, re-save it with new CRS from the original file... nothing helped. Running out of ideas. The points have decimal lat/long, not sure if QGIS has a problem to reproject these... – Kristina Dec 1 '14 at 17:50
  • Try Settings -> Options, CRS tab; Prompt for CRS for new layers. Then you will be asked for the CRS whenever importing CSV data. EPSG:4326 should do fine, then you can Save As ... to any other CRS you want. – AndreJ Dec 1 '14 at 19:09

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.