Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

area calculation error after CRS changes #19197

Closed
qgib opened this issue Jul 5, 2014 · 2 comments
Closed

area calculation error after CRS changes #19197

qgib opened this issue Jul 5, 2014 · 2 comments
Labels
Bug Either a bug report, or a bug fix. Let's hope for the latter! Projections/Transformations Related to coordinate reference systems or coordinate transformation

Comments

@qgib
Copy link
Contributor

qgib commented Jul 5, 2014

Author Name: Gavin Fleming (@gubuntu)
Original Redmine Issue: 10821
Affected QGIS version: 2.4.0
Redmine category:projection_support


Submitted on behalf of Therese Forsyth

Testing QGIS 2.4 with area calculations. File used attached.

I had a veg map with correct areas calculated using ArcView/ArcGIS (Xarea, Xhectares).

Just opened QGIS 2.4, loaded the projected veg shapefile and calculated the areas (Auto_ha) CORRECT

Went to “Settings | Options”, ticked on “enable on-the-fly….” and then again calculated the areas (otf_tm_ha) CORRECT

Then I went to “Project properties | CRS”, ticked on “projection-on-the-fly”, selected TM and calculated areas (otfr_tm) ERROR

Then back at “Project properties | CRS”, changed projection to UTM and calculated areas (otfr_utm) ERROR

Then I closed QGIS and reopen it. When I opened it from scratch, I checked the settings and the system kept the settings as it were when I closed the software. Under “Settings | Options” the “Enable on-the-fly…” was selected, and under “Project properties | CRS” the “projection-on-the-fly” box was ticked on. I ran a calculation without making any changes (area) CORRECT

Then I went to “Project properties | CRS”, changed the projection to UTM and apply, but then immediately changed it rather to TM and apply. I then again ran the calculation of the areas (area1) ERROR

I am not sure what to think of this and how to fix this. I am not even to sure how to pinpoint where the problem comes in. It just seems that the minute you make changes (does not matter what) under “Project properties | CRS”, your area calculations go absolutely haywire.

I can confirm the same error in 2.5 Master. The layer's geometry is in "South African CRS : HBK_NO_27" CRS. I know that Therese is mistaken in some of her experiments thinking that projecting on the fly might affect area calculations since the calculations occur on the native geometry, not in the projected space (right?). Which means that the area calculation should be the same no matter what project CRS is set and also should be correct every time, which is not the case.


@qgib
Copy link
Contributor Author

qgib commented Jul 7, 2014

Author Name: Giovanni Manghi (@gioman)


Which means that the area calculation should be the same no matter what project CRS is set and also should be correct every time, which is not the case.

well... no. QGIS by design works in a different way: when OTFR is ON the values are computed in project CTS units and using the ellipsoid defined in

project properties -> general -> measure tools -> ellipsoid

you can also choose to manually set it to "none/planar" to have always your measures done on a plane.


  • status_id was changed from Open to Feedback

@qgib
Copy link
Contributor Author

qgib commented Oct 8, 2014

Author Name: Giovanni Manghi (@gioman)


closing for lack of feedback, please reopen if necessary.


  • resolution was changed from to worksforme
  • status_id was changed from Feedback to Closed

@qgib qgib added Bug Either a bug report, or a bug fix. Let's hope for the latter! Projections/Transformations Related to coordinate reference systems or coordinate transformation labels May 25, 2019
@qgib qgib closed this as completed May 25, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Either a bug report, or a bug fix. Let's hope for the latter! Projections/Transformations Related to coordinate reference systems or coordinate transformation
Projects
None yet
Development

No branches or pull requests

1 participant