JamesSample / critical_loads_2

New workflow for the Critical Loads project
MIT License
0 stars 0 forks source link

Deposition data for N budget #5

Open kariaust opened 4 years ago

kariaust commented 4 years ago

Overlay of AR50 with 2012-2016 deposition (new method, 0.1 grid) to calculate N deposition per land cover type. Output: Area (ha) and either average deposition (kg N) per ha or total deposition for the land cover type (whatever is easiest - I can always calculate one from the other with the area - you can of course also do both if that is just as easy)

The results should be given per ARTYPE, but also per ARTRESLAG and ARVEGET. For the latter two I suppose I do not need the class 99 output (but keep it in if that is easier). It would also be useful to get separate results for the wetland types class 11 and 12 in AR50: Bonitet. But I am not sure if they actually add up to class 60 in ARTYPE. If not, then skip this In all cases I need results for total N. For ARTRESLAG I also need separate results for oxidised and reduced N. If the results are provided for the two wetland types I need separate ox and red here as well. I refer to https://www.nibio.no/tjenester/nedlasting-av-kartdata/dokumentasjon/ar50

Deadline: Not urgent, but if the alternatives are February or May I would say February

kariaust commented 4 years ago

And - hours can be put on 200055

JamesSample commented 4 years ago

@kariaust

This is mostly fixed by 43e9b6398ad11983c8a968376487eed571f6165b.

See the notebook here and the output files here for details. Please note the following:

kariaust commented 4 years ago

1) Separate results for the two wetland types is not crucial, so if this proves difficult, just skip it

2) As the sum of area for all three outputs is the same, I would think klasse 98 represents "the rest", i.e. all the other types in artype. But - what puzzles me is how the other classes within arveg and artreslag add up to classes 50 and 30, respectively, in artype.

3) OK

JamesSample commented 4 years ago

Hi @kariaust

Regarding class 99 in ARVEG, I think you're correct that it's some kind of generic "snaumark". According to the documentation here:

AR50: Snaumark (ARVEGET) Temaet ’Snaumark’ dekker samme geografiske område som klasse 50 (Snaumark) i temaet ’Arealtype’. Temaet er basert på AR-fjell.

And, within this, class 99 is Snaumark, but outside of the area covered by AR-Fjell.

For ARTRESLAG, I agree that the results are confusing. In fact, I think it might be an error in the AR50 dataset (?). If I run the following query:

SELECT DISTINCT(artreslag) FROM physical.norway_nibio_ar50_poly
WHERE artype = '30';

I get the following result, as expected:

['31', '32', '33', '99']

So, ARTYPE 30 corresponds to ARTRESLAG classes 31 - 33 and 99, as you suggest. However, if I run the query the other way around:

SELECT DISTINCT(artype) FROM physical.norway_nibio_ar50_poly
WHERE artreslag in ('31', '32', '33', '99');

I get the following:

['30', '60']

In other words, all polygons in ARTYPE class 30 correspond to classes 31 - 33 and 99 in ARTRESLAG, as expected. However, there are some polygons classed in ['31', '32', '33', '99'] in ARTRESLAG which actually correspond to class 60 ("Myr") in ARTYPE. This is why the summed area of (31 + 32 + 33 + 99) in ARTRESLAG is bigger than the area of class 30 in ARTYPE (because ARTRESLAG also includes some myr).

kariaust commented 4 years ago

Aha. That probably means that they have included wetland with trees in ARTRESLAG. The question is where they have put it - in all categories or just in 99? And if it is the latter - is 99 just 60 or is it something else as well (some undefined forest area). Can you check this?

JamesSample commented 4 years ago

@kariaust

SELECT DISTINCT(artype, artreslag) FROM physical.norway_nibio_ar50_poly

returns the following:

(10,98)
(20,98)
(30,31)
(30,32)
(30,33)
(30,99)
(50,39)
(60,31)
(60,32)
(60,33)
(60,39)
(70,98)
(81,98)
(82,98)
(99,98)

So it looks as though ARTYPE 60 is variously assigned to ARTRESLAG classes 31, 32, 33 and 39. There are also cases of ARTYPE 50 being linked to ARTRESLAG 39.

kariaust commented 4 years ago

Right. So, the "problematic" ones are (50,39): As sum of ARVEGET fits with ARTYPE 50, these polygons must have been assigned both to ARVEGET and ARTRESLAG. So it confirms that we can overlook 39 in ARTRESLAG - that this represents area that is not really forest (as suggested by the name) (60,31): This and the next two must be wetland with sufficient tree cover to count as forest. The best may be to separate these as three distinct land cover classes. Then we can select, depending on the project, whether we will keep them completely separate, combine them to one forested wetland class, or assign them to the wetland or forest classes, respectively. Is this doable? (60,32) (60,33) (60,39): This is probably parallel to (50,39) - area that is defined as wetland, but is for some reason also assigned to ARTRESLAG - maybe deforested area?

Am I right that 31+32+33+99 (ARTRESLAG) - (60,31) - (60,32) - (60,33) = 60 (ARTYPE)?

kariaust commented 4 years ago

The last part should of course be Am I right that 31+32+33+99 (ARTRESLAG) - (60,31) - (60,32) - (60,33) = 30 (ARTYPE)?