diff --git a/analysis.Rmd b/analysis.Rmd index 1fa2d11..3f0d04b 100644 --- a/analysis.Rmd +++ b/analysis.Rmd @@ -287,11 +287,15 @@ point_sizes <- oa_shares_inst_sector %>% filter(n_total >= 100) %>% mutate(point_shape = ifelse(inst_label =="", 1.5, 2)) %>% .$point_shape +point_color <- oa_shares_inst_sector %>% + filter(n_total >= 100) %>% + mutate(point_color = ifelse(inst_label =="", "#56b4e9", "#490206")) %>% + .$point_color oa_shares_inst_sector %>% filter(n_total >= 100) %>% left_join(oa_shares_inst_sector_stats, by = "sector") %>% ggplot(aes(x = n_total, y = oa_share, label = INST_NAME)) + - geom_point(color = "#56b4e9", alpha = .7, shape = point_shapes, size = point_sizes) + + geom_point(color = point_color, alpha = .7, shape = point_shapes, size = point_sizes) + scale_x_log10(labels = scales::number_format(big.mark = ","), expand = expansion(mult = c(0.05, 0.1))) + scale_y_continuous(labels = scales::percent_format(accuracy = 5L), @@ -676,13 +680,14 @@ oa_shares_sector <-pubs_cat %>% values_from = fig_val) %>% mutate(share_sec_cat = ifelse(oa_category == "not_oa", 1-share_sec_cat, share_sec_cat), oa_category = fct_recode(oa_category, all_oa = "not_oa")) %>% - rename(share = share_sec_cat) + rename(share = share_sec_cat) %>% + mutate(text_color = ifelse(share > .3, "black", "#cccccc")) ggplot(oa_shares_sector, aes(x = fct_rev(fct_recode(fct_relevel(fct_reorder(sec_abbr, n_sec), "all_sec"), all = "all_sec")), y = fct_rev(oa_category), size = share, fill = share))+ geom_point(shape = 21, color = "#666666") + - geom_text(aes(label = round(share*100)), color = "#cccccc", size = 4) + + geom_text(aes(label = round(share*100), colour = text_color), size = 4, show_guide = FALSE) + geom_vline(xintercept = 6.5, color = "black") + geom_hline(yintercept = 1.5, color = "black") + scale_size(name = "OA percentage", @@ -695,6 +700,7 @@ ggplot(oa_shares_sector, aes(x = fct_rev(fct_recode(fct_relevel(fct_reorder(sec_ guide = guide_colorbar(frame.colour = "#666666", barwidth = 17)) + labs(x = "Sector", y = "OA Category") + # coord_flip() + + scale_color_manual(values = c("black" = "black", "#cccccc" = "white")) + theme_minimal_grid() + theme(legend.position = "top", legend.justification = "right") + theme(legend.direction = "horizontal", legend.box = "vertical") + diff --git a/analysis.md b/analysis.md index eca2933..bc14fc7 100644 --- a/analysis.md +++ b/analysis.md @@ -30,7 +30,7 @@ following figure displays the number of publications associated with one of the German research institutions we considered and highlights they part that is freely accessible online according to Unpaywall over the considered time period from 2010 until 2018. The total number of -articles over the whole period is 871922 with an overall OA share of 44 +articles over the whole period is 871922 with an overall OA share of 45 %.