项目作者: JuanmaMN

项目描述 :
Publish ggplot2 analysis
高级语言: HTML
项目地址: git://github.com/JuanmaMN/tidyverse-ggplot2.git
创建时间: 2019-08-15T18:57:31Z
项目社区:https://github.com/JuanmaMN/tidyverse-ggplot2

开源协议:

下载


tidyverse-ggplot2

Code for all the ggplot2 analyses done and published.

geom_segment & geom_rrect

FIFA World Cup 2022


Screenshot at Dec 18 18-14-07





geom_segment

Ggplot2 chart using geom_segment. Code is available here

Contribution to #TidyTuesday - 31st May 2021



TT




geom_text

Ggplot2 chart using geom_segment. Code is available here

Contribution to #TidyTuesday - 25th April 2023



London_marathon_25_April_2023




geom_point

Ggplot2 chart using geom_point. Code is available here

Contribution to #TidyTuesday - 29th March 2022



TT



Quasi-Random chart

Ggplot2 chart using geom_quasirandom. Code is available here



TT-23-2-2021




Bar chart

Ggplot chart using geom_bar. Code is available here




13 8 2019


geom_bar - facet_wrap

Ggplot2 chart using geom_bar and facet_wrap. Code is available here



14-1-2020


Dumbbell

Ggplot2 chart using geom_dumbbell. Code is available here



TT


Ggplot2 chart using geom_dumbbell. Code is available here



14 10 2019


Multi-point “dumbbell” plot with ggplot2. Code is available here



Exports - 15 8 2019


Multi-point “dumbbell” plot with ggplot2. Code is available here



TT-23-2-2021







Multi-point “dumbbell” plot with ggplot2 and point difference. Code is available here





Rugby (2)







## Ridgeline


Code is available here






LE


Area graph

Code is available here




Gender analysis


Multi-area graph

Code is available here




#TidyTuesday_17_3_2023


Waffle graph

Code is available here

  1. ggplot(waffle, aes(fill = Review_Rating, values = n)) +
  2. geom_waffle(color = "white", size = .25, n_rows = 10, flip = T) +
  3. facet_wrap(~Year, nrow = 1, strip.position = "bottom") + ...



waffle


Heatmap with geom_tile

Code is available here


data

TidyTuesday Week 23/2023 - Energy

Code is available here.






Energy_production_heatmap




Animated ggplot with gganimate

Code is available here



data

geom_bar_text

Code is available here



data

geom_bar_text + geom_flag

Code is available here


  1. ggplothp<-data_2019 %>% ggplot(aes(x=fct_reorder(Country,Happiness_Score), y=Happiness_Score,
  2. group = Country, fill= factor(Country))) +
  3. geom_col(width = 0.8) +
  4. geom_bar_text(place = "right", contrast = TRUE, size=10,
  5. aes(label=paste0(Country, " ",round(Happiness_Score,3)))) + ...



HP


geom_chicklet

Code is available here


  1. plot_hotel<-ggplot(hotels_data, aes(x = arrival_date_month, y = prop, fill = hotel)) +
  2. geom_chicklet() +
  3. coord_flip() +
  4. theme_minimal() +
  5. scale_fill_manual(values = c("#add8e6", "#20b2aa")) + ...



10-2-2020


geom_bump

Code is available here


  1. ggplot(data3, aes(Year, rank, color = Country)) +
  2. geom_point(size = 7) +
  3. geom_text(data = data3 %>% filter(Year == min(Year)),
  4. aes(x = Year - .1, label = Country), size = 4, hjust = 1) +
  5. geom_text(data = data3 %>% filter(Year == max(Year)),
  6. aes(x = Year + .1, label = Country), size = 4, hjust = 0) +
  7. geom_bump(aes(smooth = 6), size = 1.5) + ...



geom_bump


Line chart

Code is available here


  1. g2<-grosses2 %>%
  2. ggplot(aes(month,total_seats_sold, group=year, col=factor(year))) +
  3. geom_line(size=1.5,linetype = "solid") +
  4. geom_point(size=4, shape=21, fill="#f0f0f0") ...



line_chart





## Map

Code is available here




p<-plot_usmap(data = data2, values = “value”, labels = TRUE, lines = “white”,
label_color = “white”) …








map_c






Code is available here




europe2 <- europe + geom_polygon(data = map,
aes(fill = fine,x = long,
y = lat, group = group),
color = “grey70”) …




map_d


Code is available here


  1. pA <- ggplot() +
  2. geom_map(data = world, map = world,
  3. aes(long, lat, group = group, map_id = region),
  4. fill = "#282828", color = "#282828") +
  5. geom_map(data = databerup, map = world,
  6. aes(fill = total, map_id = country),
  7. color = "#282828", size = 0.15, alpha = .8) ...



map_d



geom_statebins

Code is available here



17-4-2021




Donut chart

Code is available here

23-6-2020 - 2



Code is available here.

Contribution to #TidyTuesday - 8th June 2020

23-6-2020 - 2