Notice. Now I have checked the result comparing with the result of ArcGIS. Those result are little different. The counting method may be different between QGIS and ArcGIS. Please be careful. 2020/02/07

Concept of Tabulate area

Tabulate area function is really famous in ArcGIS. You can use this function to calculate the area of ​​each land use type in a zone(see below).

The concept of tabulate are function

Zonal Histogram function

There are similar functions in QGIS such as Cross-Classification and Tabulation in SAGA toolbox. The most stable and convenient function is Zonal Histogram. A result of the function is not areas but counts of pixels.

Zonal histogram

Here, we are going to introduce the function.

Input data of Zonal histogram

  • A zone layer: polygons(vector type) to identify zones such as watershed, administrative boundary, management unit etc.. In this tutorial, the watershed polygon will be used. See below.
Zone layer. this example is watersheds from survey points of water quality. The watershed has its attributes. At least one integer value field which identifies zones is necessary. ID or GRIDCODE above will be used in the case.

  • A raster layer: A categorical raster such as landuse, slope category, geology, etc. The raster data must have integer value to identify the categories such as landuse type.
A categorical raster. This example is landuse map. You can see the landuse type in Layers(Right). But this raster data exactly consists of integer value which represents landuse type(1,2,5,6 in left image).

Overlay and check your input

You had better use the same CRS for both input zone and raster layer to avoid errors in QGIS. As you know, many errors may happen caused by CRS conflicts in QGIS.

The watershed and the Landuse map are overlayed.
Those layers have the same CRS( EPSG:3100 – JGD2000 / UTM zone 54N)

Run Zonal histogram function

Open Zonal histogram function from Processing Toolbox.
Raster Analysis > Zonal histogram.

Location of Zonal histogram

Settings of Zonal histogram function like below > Run

In this example, A raster is the landuse map consists of category value. The zone layer is the watershed layer. Again, you can check CRS of both(both EPSG:3100).

Check the result

The result is the same polygon. Please check the attribute. So you can see the result of cross tabulation. HIST_2, HISTO_3, etc. are the category value of landcover map(e.g. 2: Other agricultural lands, 3: Forest). The values in the table are the number of pixels of each land cover type in zones.

The result is the same polygon that you used in the input. But it has the attribute of cross tabulation(number of pixels).

Calculate area

Please check the pixel size of your input raster.
Right click on input raster > Properties > Information tab.
In the example, the resolution of the landuse map is 100m*100m(1ha). I don’t know why it is slightly different. Anyway, 1 pixel is 1ha. So, you can know the area of each landuse type by multiplying the number of pixels in the result table and area of 1 pixel.

Check the resolution of the input raster.
Number of pixel * area of 1 pixel is the area of each category in zones