Lesson 3.4Lesson 3.4 · Georeferencing & Data Preparation
Data Cleaning & CRS Transforms
Making messy layers valid, consistent and correctly placed
Two layers of the same neighbourhood open side by side, kilometres apart.
The roads sit near the equator in tiny decimal numbers; the plots sit in the hundreds of thousands. Nothing overlaps, an area calculation returns a nonsense figure, and an overlay refuses to run. Nothing is broken — the layers are just speaking different coordinate languages, and one has a self-intersecting polygon for good measure. Most GIS pain is not analysis; it is preparation. This lesson is the cleaning bench: valid geometry, consistent fields, and layers reprojected onto one common CRS so everything finally lines up.
Keep the raw file. Every 'fix' is a bet, and the original is how you unwind a losing one.
Why real data is dirty
Data reaches you from scans, downloads, other people's projects and field devices, and each source adds its own mess. Geometries can be invalid — a polygon that crosses itself (a "bowtie"), a ring that does not close, duplicate vertices. Attributes can be inconsistent — the same land use spelled three ways, numbers stored as text, nulls where zeros belong, units mixed. And whole layers can be in the wrong or mismatched coordinate reference system, so they will not overlay.
Cleaning is unglamorous and it is most of the job. The payoff is that everything downstream — the joins of the last lesson, the buffers and overlays of Module 4, the terrain work of Module 5 — assumes clean, valid, consistently-projected data. Skip the bench and every later result inherits the dirt.
Analysis is the 20% everyone photographs; cleaning is the 80% that makes it true.
Fixing invalid geometries
An invalid geometry is a shape that violates the rules of what a geometry may be — most commonly a polygon whose boundary crosses itself, or one with a self-touching ring. Invalid shapes make area calculations wrong and make overlay tools (clip, intersect, union) fail or return garbage.
The workflow is simple: detect, then repair. A validity check lists each problem feature and often names the fault ("self-intersection at…"). A fix-geometries operation then rebuilds the shapes into valid, simple rings — splitting a bowtie, closing an open ring, removing duplicate points. Run the check first so you know what you are fixing, run the fix, then re-check to confirm zero errors remain. Do this before any overlay or area work, not after you get a strange result.
Cleaning attributes
Geometry is only half of clean. The attribute table usually needs work too. Standardise category values so "Resi", "residential" and "RESIDENTIAL" become one class — inconsistent spellings fracture every count and join. Fix field types so numeric fields really are numeric (recall last lesson's silent-join failures). Distinguish a genuine null (unknown) from a zero (known to be none), because averaging over nulls versus zeros gives different answers. Trim whitespace, reconcile units into one system, and remove duplicate records.
Use the field calculator and find-and-replace for bulk fixes, and — crucially — keep a copy of the raw data. Cleaning is editing, and editing is destructive; a preserved original is your only way back if a "fix" turns out to be a mistake.
A null is 'I don't know'; a zero is 'I know it's none'. Averaging them together is how reports lie.
Define vs reproject: the distinction that saves you
Coordinate work has two operations that beginners fatally confuse. Defining (assigning) a CRS tells the software what system the existing numbers are already in — it relabels, it does not move a single coordinate. You do this only when a layer's CRS is missing or wrong (a lost .prj from Module 0). Reprojecting (transforming) actually recomputes every coordinate from one CRS into another — the numbers change so the features land in the same real place under a new system.
Get these backwards and you cause disasters. Reproject a correctly-defined layer and it is fine; but re-define a layer that was already correct and you have lied about where it is — it will jump across the map. The rule: if a layer sits in the wrong place because its CRS label is missing/incorrect, define. If it sits correctly but you need it in a different system to match others or to measure, reproject.
Choosing the right CRS to work in
Most GIS shows layers of different CRSs together using on-the-fly reprojection — a convenience that displays them aligned without changing the files. Do not mistake that for done: many geoprocessing and every honest measurement should run on data actually stored in one appropriate projected CRS.
Tie this back to Module 0's codes. Store and share in geographic EPSG:4326 (WGS 84) — but never measure area in degrees. To measure length or area over a region, reproject into the local UTM zone — EPSG:32643 / 32644 / 32645 for much of India — which is in metres. For pan-India work in one metric frame, ISRO's national EPSG:7755 (WGS 84 / India NSF LCC) is a Lambert Conformal Conic, not a Transverse Mercator despite a widespread myth. Reproject a working copy for the task, keep your master in a stable CRS with its .prj intact, and record the CRS in the metadata.
On-the-fly alignment is a display trick, not a saved fact — measure only in a real projected CRS.
EPSG:4326
WGS 84 — geographic 2D, degrees (global)
The common storage/sharing CRS you reproject from; correct for position, wrong for measuring area.
EPSG:32644
WGS 84 / UTM zone 44N — projected metres
Reproject to your local UTM zone (32643/44/45 for India) before measuring length or area.
EPSG:7755
WGS 84 / India NSF LCC (national)
ISRO NNRMS national metric frame — a Lambert Conformal Conic, NOT a Transverse Mercator; good for pan-India work.
GDAL/OGR (v3.13.2)
The transform engine under most GIS (global)
Both QGIS 'Reproject' and ArcGIS 'Project' rely on this class of library to recompute coordinates.
Workshop — clean and reproject two misaligned layers
Take two layers that will not overlay, diagnose the problem, fix any invalid geometry, reproject both onto one projected CRS, and confirm they align and measure correctly.
QGIS 3.44 (Check/Fix Geometries, Reproject Layer, Assign Projection) or ArcGIS Pro 3.7 (Repair Geometry, Project, Define Projection).
Given: two vector layers of the same area that do not overlap + one layer with an invalid polygon Target CRS: your local UTM (e.g. EPSG:32644) or EPSG:7755 Goal: valid geometry + both layers in one CRS, measuring in metres
- 1Diagnose the mismatch. Check each layer's CRS. In QGIS: Layer Properties ▸ Information / Source. In ArcGIS Pro: Layer Properties ▸ Source ▸ Spatial Reference. Decide whether a layer's CRS is missing/wrong (define) or correct but different (reproject).
- 2If a CRS is missing or wrong, DEFINE it — without moving coordinates. In QGIS: Processing ▸ 'Assign Projection' (or set Layer CRS). In ArcGIS Pro: Tools ▸ Define Projection. Only do this when you know the true CRS.
- 3Validate and fix geometry. In QGIS: Vector ▸ Geometry Tools ▸ Check Validity, then Processing ▸ Fix Geometries. In ArcGIS Pro: Data Management ▸ Check Geometry, then Repair Geometry. Re-check for zero errors.
- 4Reproject both layers to the one target CRS. In QGIS: Processing ▸ 'Reproject Layer' to EPSG:32644 (or 7755). In ArcGIS Pro: Data Management ▸ Projections and Transformations ▸ Project.
- 5Clean the attributes — standardise a category field, fix any text-vs-number type, and separate nulls from zeros using the field calculator (QGIS) or Calculate Field (ArcGIS Pro).
- 6Confirm success: the layers now overlay, and an area computed in the projected CRS returns a sensible value in square metres. Export the cleaned layers to a new GeoPackage / feature class and record the CRS in the metadata.
You’ll walk away with
Two valid, attribute-clean layers stored in one projected CRS that overlay correctly and measure in metres — plus a note of which layer was defined vs reprojected, and why.
Three altitudes on the same idea
Read the band that fits you — or all three.
Before you trust one dimension off a layer, put it in a metric CRS and validate its geometry. Areas, setbacks and coverage measured in EPSG:4326 degrees are meaningless; reproject the site's working layers into your local UTM zone first. Fix any invalid plot polygon before you compute a single area, or every number after it is suspect.
Statutory analysis mixes datasets from many sources and vintages — the CRS reconciliation is yours to own. Reproject Census, land-use and infrastructure layers onto one agreed projected CRS (a UTM zone, or EPSG:7755 for pan-India) before area and density work, and document it. Clean, consistently-projected data is what makes a plan defensible in review.
Walkability and morphology metrics are distances and areas, so they demand a metric CRS and valid geometry. A network in degrees or a self-intersecting block will quietly corrupt catchments and figure-ground ratios. Reproject to UTM, fix geometries, and only then measure the street lengths and block sizes your arguments rest on.
“Assigning a coordinate system and reprojecting are basically the same fix for misaligned data.”
Do it yourself
No software — diagnose before you touch the data.
- 1A layer opens far from where it should be, in tiny decimal numbers. State whether you would define or reproject, and how you would decide.
- 2You measured a plot's area and got 0.00004. What unit are you almost certainly in, and what is the fix?
- 3Explain, in one sentence each, the difference between defining a CRS and reprojecting.
- 4A colleague says EPSG:7755 is 'India's national TM zone'. Correct them.
- 5Why is on-the-fly reprojection not a substitute for actually reprojecting before a measurement?
The one line to carry out
Peer-reviewed journals & authoritative standards
- 01de Smith, M.J., Goodchild, M.F. & Longley, P.A. — Geospatial Analysis: A Comprehensive Guide, 7th ed. — Winchelsea Press, 2025.
- 02Bolstad, P. & Manson, S. — GIS Fundamentals: A First Text on Geographic Information Systems, 7th ed. — Eider Press, 2022.
- 03Chang, K.-T. — Introduction to Geographic Information Systems, 9th ed. — McGraw-Hill Education, 2019.
- 04Burrough, P.A., McDonnell, R.A. & Lloyd, C.D. — Principles of Geographical Information Systems, 3rd ed. — Oxford University Press, 2015.
- 05Longley, P.A., Goodchild, M.F., Maguire, D.J. & Rhind, D.W. — Geographic Information Science and Systems, 4th ed. — Wiley, 2015.
With Module 3's data now georeferenced, digitised, joined, cleaned and correctly projected, you finally have trustworthy layers — and Module 4 puts them to work with the core vector toolkit: buffers, overlays, queries and networks.
The author
Amogh N P
Architect, interior designer, and creative polymath. Studio Matrx began in his notebooks — his vision of design made honest, useful, and open to everyone. Its Academy is written and taught in his memory, and free, forever.
More about Amogh →