A15 collections
@slgora in script4 in the 2 piece of code below replace "International" with "A15" , be aware that I uploaded a corrected version of the FAO_WIEWS_organizations_PG.xlsx and FAO_WIEWS_organizations_PG.xlsx files in she shared folder.
The 2 metrics on international collections in Table 4 need to be updated in the 15 docs after re-running with these changes.
# 7. accessions by org type, and MLS accessions for organization type (A15 collection versus non-A15)
combined_allcrops <- combined_allcrops %>%
mutate( A15_collection = ifelse(ORGANIZATIONTYPE %in% c("CGIAR", "International"), TRUE, FALSE) )
mls_by_orgtype <- combined_allcrops %>%
mutate(A15_collection = ORGANIZATIONTYPE %in% c("CGIAR", "International")) %>%
group_by(Crop_strategy) %>%
mutate(total_crop_records = n()) %>%
group_by(Crop_strategy, A15_collection, total_crop_records) %>%
summarise(
count_includedmls = sum(MLSSTAT == TRUE, na.rm = TRUE),
count_notincludedmls = sum(MLSSTAT == FALSE, na.rm = TRUE),
count_noMLSinformation = sum(is.na(MLSSTAT)),
.groups = "drop"
) %>%
mutate(
percent_includedmls = round(100 * count_includedmls / total_crop_records, 2),
percent_notincludedmls = round(100 * count_notincludedmls / total_crop_records, 2),
percent_noMLSinformation = round(100 * count_noMLSinformation / total_crop_records, 2)
)
``