Exercise – 8 / How to use Intersection , Dissolve & Union in QGIS
- Dissolve
The Dissolve Tool unifies boundaries based on common attribute values. In other words, dissolve merges neighboring boundaries if the neighbors have the same attributes.The dissolve geoprocessing tool erases borders and unifies them into one.
- Add Polygon Layer to Layers panel
Figure 109 - Shapefile before Dissolve
- Choose Vector → Geoprocessing tools →Dissolve to open dissolve window
- Select Input layer (Ex: IND_adm1)
- Open Attribute table to choose the field on which Dissolve tool will be executed, in this case TYPE_1 has choose.
Figure 110 - Attribute table with selected attribute value
Figure 111 - Dissolve window
- Click on Dissolve field(s) [optional] and select the attribute value and click on OKand Run.
Figure 112 - Attribute field selection window for dissolve
- Temporary layer will be created and added to Layer panel with Dissolved layer. Right click on the layer and save to destination folder.
Figure 113 - Shapefile after Dissolve
2. Intersection
The Intersect Tool is very similar to the clip tool because the extents of input features defines the output. The only exception is that it preserves attributes from all the data sets that overlap each other in the output.
The Intersect Tool performs a geometric overlap. All features that overlap in all layers will be part of the output feature class – attributes preserved.
Intersection – Line
- Add Line Layer to Layers panel
- Add polygon boundary to Layers panel for intersection
Figure 114 - Line and Polygon layers for Intersection
- Open attribute table and check the attribute values of both the layers.
Figure 115 - Attribute table showing the values of Line & Polygon layers
- Choose Vector → Geoprocessing tools →Intersection to open intersection window
- Select Input layer (Ex: Network)
- Select Overlay layer (Ex: Clip_Boundary), click on Run to execute.
Figure 116 - Intersection Window
- Temporary layer will be created and added to Layer panel with Intersection layer. Right click on the layer and save to destination folder.
- Open attribute table and see attributes pertaining to overlay layer is also added to the created layer.
Figure 117 - Attribute table showing the data of both line and polygon in created layer
Note: Procedure of Intersection for Point and Polygon follows the same.
3. Union
The Union tool spatially combines two data layers. It preserves features from both layers at the same extents.
Union – Polygon
- Add Polygon Layer to Layers panel
Figure 118 - Polygon layers for Union
- Open Attribute tables for both the layers
Figure 119 - Attribute data of input layer
Figure 120 - Attribute data of Overlay layer
- Choose Vector → Geoprocessing tools →Union to open union window
Figure 121 - Union window
- Select input layer (Ex: Boundary)
- Select Overlay layer (Ex: Clip_Boundary)
- Click on Run.
- Temporary layer will be created and added to Layer panel with Union layer. Right click on the layer and save to destination folder.
Figure 122 – Union of both polygon layers
- Open Attribute Table of created Union layer to check the attribute data of created union layer.
Figure 123 - Attribute data of union layer
Note: Procedure for Union of Point and Line layers follows the same.
Comments
Post a Comment