Skip to content

Commit

Permalink
Merge pull request #24 from weecology/indicators
Browse files Browse the repository at this point in the history
Indicator analysis RECOVER requests
  • Loading branch information
gmyenni authored Jul 30, 2024
2 parents 6c5c506 + 315da73 commit a0441ab
Showing 1 changed file with 13 additions and 5 deletions.
18 changes: 13 additions & 5 deletions R/indicator_analysis.R
Original file line number Diff line number Diff line change
Expand Up @@ -32,14 +32,16 @@ foraging_analysis <- function(path = get_default_data_path(),
geom_line(color="black", linewidth=1.1) +
geom_ribbon(alpha=0.2, fill="grey") +
geom_ribbon(alpha=0.5, aes(color=NULL, fill=period)) +
geom_hline(yintercept=32, linetype=2, color="darkgreen", linewidth=1) +
geom_hline(yintercept=32, linetype=2, color="black", linewidth=1) +
ylim(0,35) +
labs(x="Year", y = "tactile/visual") +
theme_classic() +
theme(legend.position="none") +
guides(fill = guide_legend(byrow = TRUE)) +
# geom_ysidedensity(aes(fill=period), alpha = .5) +
# geom_ysidehline(yintercept = 32, linetype=2, color="darkgreen", linewidth=1) +
scale_color_grey() +
scale_fill_grey() +
theme(
text = element_text(family = "AppleGothic", size = 18),
# ggside.panel.border = element_blank(),
Expand Down Expand Up @@ -86,15 +88,17 @@ initiation <- initiation_indicator(minyear = 2004) %>%
geom_line(color="black", linewidth=1.1) +
geom_ribbon(alpha=0.2, fill="grey") +
geom_ribbon(alpha=0.5, aes(color=NULL, fill=period)) +
geom_hline(yintercept=4.5, linetype=2, color="darkgreen", linewidth=1) +
geom_hline(yintercept=4.5, linetype=2, color="black", linewidth=1) +
scale_y_reverse(limits=c(5,-.2), breaks=c(4,3,2,1,0),labels=c("December","January","February","March","April")) +
labs(x="Year", y = "Date Score") +
theme_classic() +
theme(legend.position="none") +
guides(fill = guide_legend(byrow = TRUE)) +
# geom_ysidedensity(aes(fill=period), alpha = .5) +
# geom_ysidehline(yintercept = 4.5, linetype=2, color="darkgreen", linewidth=1) +
theme(
scale_color_grey() +
scale_fill_grey() +
theme(
text = element_text(family = "AppleGothic", size = 18),
# ggside.panel.border = element_blank(),
# ggside.panel.grid = element_blank(),
Expand Down Expand Up @@ -140,14 +144,16 @@ library(ggplot2)
geom_line(color="black", linewidth=1.1) +
geom_ribbon(alpha=0.2, fill="grey") +
geom_ribbon(alpha=0.5, aes(color=NULL, fill=period)) +
geom_hline(yintercept=.5, linetype=2, color="darkgreen", linewidth=1) +
geom_hline(yintercept=.5, linetype=2, color="black", linewidth=1) +
ylim(0,.6) +
labs(x="Year", y = "proportion coastal") +
theme_classic() +
theme(legend.position="none") +
guides(fill = guide_legend(byrow = TRUE)) +
# geom_ysidedensity(aes(fill=period), alpha = .5) +
# geom_ysidehline(yintercept = .5, linetype=2, color="darkgreen", linewidth=1) +
scale_color_grey() +
scale_fill_grey() +
theme(
text = element_text(family = "AppleGothic", size = 18),
# ggside.panel.border = element_blank(),
Expand Down Expand Up @@ -194,14 +200,16 @@ library(ggplot2)
geom_line(color="black", linewidth=1.1) +
geom_ribbon(alpha=0.2, fill="grey") +
geom_ribbon(alpha=0.5, aes(color=NULL, fill=period)) +
geom_hline(yintercept=1.6, linetype=2, color="darkgreen", linewidth=1) +
geom_hline(yintercept=1.6, linetype=2, color="black", linewidth=1) +
ylim(0,3) +
labs(x="Year", y = "mean interval") +
theme_classic() +
theme(legend.position="none") +
guides(fill = guide_legend(byrow = TRUE)) +
# geom_ysidedensity(aes(fill=period), alpha = .5) +
# geom_ysidehline(yintercept = 1.6, linetype=2, color="darkgreen", linewidth=1) +
scale_color_grey() +
scale_fill_grey() +
theme(
text = element_text(family = "AppleGothic", size = 18),
# ggside.panel.border = element_blank(),
Expand Down

0 comments on commit a0441ab

Please sign in to comment.