-
Notifications
You must be signed in to change notification settings - Fork 8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Second draft for NO_GJEN_001 #67
base: main
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I did a rapid reviw of this updated version of NO_GJEN_001 and would requests some minor edits before merging. Theu are mainly formatting issues tha I can fix myself. Will pick this up again next year.
See PR review checklist #84
@@ -59,29 +59,29 @@ source(here::here("_common.R")) | |||
```{r} | |||
#| echo: false | |||
meta <- readxl::read_xlsx("../metadata.xlsx") | |||
st <- meta |> | |||
filter(Variable == "status") |> | |||
st <- meta %>% |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why did you change the pipe operator? Best to use the native R pipe, no?
|
||
- **Quantification of uncertainty around indicator scores.** Here we used the standard deviation in the vegetation heights for reference (NiN) polygons within each region to quantify the uncertainty around scaled indicator scores. We did this because the method used in `eaTools::ea_spread()` function is a bootstrapping approach which resulted in extremely small uncertainty estimates due to the large number of polygons included in our analysis. [In the future, a better method for quantifying uncertainty is needed.](https://github.com/NINAnor/eaTools/issues/17) Perhaps by running sensitivity analyses that test several variations of the points mentioned above can form the basis for quantifying an error margin around indicator values. | ||
- **Selection of scaling function and define threshold value for good ecological condition.** In the investigation part of how to calculate the encroachment index (not presented here), we tested three different scaling functions (Sigmoid (as presented in an earlier version), Exponential and Linear) where we ended up using the Linear scaling function. However, further testing of scaling functions should be done in the future, especially in regards to defining a threshold value for good ecological condition. Here we only define the upper and lower limits of ecological condition. However the results presented in section 10.4 suggests that it would be beneficial for the encroachment index to also have a threshold value for good ecological condition (X~60~). One way could be to calculate the 90th percentile for vegetation height in the reference polygons and set this as X~60~, but a proper threshold value should be investigated. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good!
ifelse(region_id == 2, 'Midt-Norge', | ||
ifelse(region_id == 3, 'Østlandet', | ||
ifelse(region_id == 4, 'Vestlandet', 'Sørlandet'))))) %>% | ||
mutate(region = case_when( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice!
for(i in 1:length(ecosysttypes)){ | ||
|
||
ecosysttype <- ecosysttypes[i] | ||
|
||
# Import median LiDAR heights for NiN polygons (references) | ||
# Import median LiDAR heights for NiN MI polygons (references) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good to specify that it is from MI
@@ -730,41 +786,50 @@ Import the reference vegetation heights generated in GEE and define the upper li | |||
|
|||
ecosysttypes <- c("vaatmark", "aapne", "semi") | |||
|
|||
# Need to filter out the ones where data is also on semi-natural types that are not in a good condition | |||
nin_good_condition <- st_read("/data/P-Prosjekter2/412421_okologisk_tilstand_2024/Data/NiN/nin_cleaned_condition.shp") %>% |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
adding quiet = T
wil supress messages from st_read()
|
||
The gjengroing condition indicator scores are on average above 0.8 and therefore indicate a good overall condition in Norway (@fig-regional-level-enc-forest). Østlandet comes out best for våtmark and semi-naturlig åpne ecosystems. Nord-Norge has poorest condition for semi-naturlig åpne ecosystems, while vestlandet has the poorest scores for våtmark." | ||
The encroachment condition indicator scores are on average above 0.8 and therefore indicate a good overall condition in Norway (@fig-regional-level-enc-forest). Østlandet comes out best for wetland and semi-natural ecosystems. Nord-Norge has poorest condition for semi-natural ecosystems, while Vestlandet has the poorest scores for wetland. | ||
|
||
### 10.1 Scaled indicator values at the level of homogeneous ecosystem areas {#sec-HEA} | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
set warning: false
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
use use legend.position.inside
instead of legend.position
plot.title = element_text(size=10)) + | ||
ggtitle('C) Semi-naturlig condition') | ||
theme(legend.position = c(0.8, 0.4)) + | ||
ggtitle('C) Semi-naturlig') | ||
|
||
|
||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
IN fig-regional-level-enc-forest caption, add note that indicator values are not final, and serve only as prrof of concept for the indicator workflow
|
||
These results suggest that, at least for semi-natural ecosystems, using polygons with an overall good condition score will still give reference heights that are suitable for calculating the gjengroing index. | ||
str(rasksuksIndexPoly) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hash out
|
||
```{r validation-enc-index, fig.cap="Scatter plot displaying reference heights for good condition according to NiN field-mapping ecological condition overall score and sub-score for Rask suksesjon in semi-natural ecosystems"} | ||
rasksuksIndexPoly %>% |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
set warning: false
``` | ||
|
||
## 12. Export file | ||
fig-validation-enc shows that encroachment indicator has higher values (good condition) with the better condition scores for Rask suksesjon (1=good) and that the condition does indeed get poorer when Rask suksesjon has a poorer condition score (3 and 4). However, all Rask suksesjon values have relatively high encroachment indicator scores (mean \> 0.8), suggesting that the encroachment indicator is giving better condition scores than what is actually measured in the field. A reason for this can be that the scaling function does not fit well with the data or that the indicator also needs a threshold value for when the condition is good or not (X~60~). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add @ at the start to fix cross ref
No description provided.