Geopandas and QGIS Calulating Different Polygon Area Values?
Change your QGIS map projection to match your custom CRS:
Then re-compute your areas and you should get
I am not sure why this matters, but clearly QGIS gets some information for computing area from the canvas's CRS (which seems dumb). One way to avoid this is to re-project and save your shapefile, so when you pull it into a fresh map canvas it will automatically set the canvas to the same CRS.
EDIT: the area tool description states:
The area calculated by this function respects both the current project's ellipsoid setting and area unit settings. For example, if an ellipsoid has been set for the project then the calculated area will be ellipsoidal, and if no ellipsoid is set then the calculated area will be planimetric.
When you re-project your shapefile, the project's ellipsoid setting (specified by EPSG:4326 or whatever your map CRS is set to) does not change, so you need to manually change it to ensure the same ellipsoid as your new shapefile CRS.
QGIS has two different area functions. One respects the project settings, while the other uses the layer's spatial reference system. To see identical results to the GeoPandas area calculation, use area($geometry)
of the $area
.
$area
The area calculated by this function respects both the current project's ellipsoid setting and area unit settings. For example, if an ellipsoid has been set for the project then the calculated area will be ellipsoidal, and if no ellipsoid is set then the calculated area will be planimetric.
area()
Calculations are always planimetric in the Spatial Reference System (SRS) of this geometry, and the units of the returned area will match the units for the SRS. This differs from the calculations performed by the $area function, which will perform ellipsoidal calculations based on the project's ellipsoid and area unit settings.