I have a shapefile of all forest patches in Flanders (Belgium) but I want to transform this information to a 1x1 km grid in which each grid has the information of the total area of forest of the different polygons of the forest shapefile.
@Anneleen, I suppose you want each cell to hold the sum of that fraction of forest polygon area that is overlaying some cell. So the problem is to sum up on a cell by cell basis, not to assign a single value to a cell.
You can realize that as a vector overlay problem.
Generate a polygon grid (QGIS geoalgorithms - Vector creation tools - Create grid); find some reasonable center point for the grid, and specify as spacing your 1000x1000 meters. With field calculator add a field, say "fid", holding explicitely the unique feature $id
Next intersect this polygon grid with the forest layer (QGIS geoalgorithms - Vector analysis tools - Intersection): Input layer the forest, Intersect layer the grid
This results in smaller forest polygons, cutted at the edges of the grid. Now append a new field, say "area", with field calculator and fill it with "$area", the area of the polygons.
Unfortunately QGIS only supports the predicate intersects for spatial joins. This would give not only the objects within a grid cell, but also these touching a cell. So simply buffer the polygon grid with a minimal negative distance (QGIS geoalgorithms - Vector geometry tools - Fixed distance buffer)
Now join the buffer layer (4) as Target vector layer with the result of (3) as the Join vector layer, take summary of intersecting features, choose as Statistics for summary the sum, and keep all records for the output table ((QGIS geoalgorithms - Vector general tools - Join by location)
In the last step you will join the result of (5) back to the polygon grid (1), to get rid of the buffer geometry. You will join the attribute tables of both layers via the common Table field "fid" (QGIS geoalgorithms - Vector general tools - Join attributes table). Look for a field "SUMarea", it holds the sum of the area fraction of several forest polygons, overlaying a regular grid.
The workflow might look somehow complicated, but you can semi-automatize it as a processing model. You benefit from as much detail information as possible.
Dear @ Detlev Neumann , I am interesting to make disaggregation of emissions over a city. Here some steps that I want to develop, but I would like to get more information of this kind of works:
(a) Intersect the regular grid with the urbanized areas GIS file
(b) Join the intersected landuse map with the cells file, in order to have the urbanized surface statistic per cell.
(c) Compute the weight of urban covering for every cell
(d) Assign to every cell the emissions by multiplying the total CO emission to the weight calculated in (c)