Created
December 22, 2022 14:36
-
-
Save fernandobarbalho/cbd062fd1c15b9c7f7f1368305fbee7e to your computer and use it in GitHub Desktop.
Script para gerar gráfico good vibex x bad vibes
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
library(tidyverse) | |
library(colorspace) | |
library(ggrepel) | |
set.seed(13) | |
good_vibes <- rnorm(n=100, mean=90, sd=2) | |
set.seed(22) | |
bad_vibes <- rnorm(n=100, mean=70, sd=2) | |
vibe_evolution<- tibble(tempo = c(1:100,1:100), | |
vibe= c(good_vibes,bad_vibes), | |
tipo_vibe= c(rep("good vibe",100), rep("bad vibe",100)) ) | |
vibe_evolution %>% | |
ggplot(label = tipo_vibe)+ | |
geom_line(aes(x=tempo, y=vibe, color = tipo_vibe), size=.8) + | |
theme_light() + | |
scale_color_discrete_qualitative(palette = "Pastel 1")+ | |
theme( | |
text = element_text(size =10), | |
panel.background = element_rect(fill = "#000080"), | |
panel.grid = element_blank(), | |
axis.text = element_blank(), | |
axis.title = element_blank(), | |
legend.position = "none" | |
) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment