Skip to content

Commit 9993ba3

Browse files
committed
尝试安装开发版 ggplot2 解决,但是只解决了图例方向问题,详见 tidyverse/ggplot2#4732
1 parent 0faf78e commit 9993ba3

File tree

2 files changed

+4
-5
lines changed

2 files changed

+4
-5
lines changed

content/post/2022-04-23-choropleth-map/index.Rmd

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -238,10 +238,9 @@ us_cancer_rates <- reshape(
238238
)
239239
alabama_us_cancer_rates = subset(x = us_cancer_rates, subset = state == "Alabama")
240240
library(ggplot2)
241-
ggplot(data = alabama_us_cancer_rates, aes(x = reorder(county, rate), y = rate, colour = sex)) +
242-
geom_pointrange(aes(ymin = LCL95, ymax = UCL95)) +
243-
coord_flip() +
244-
labs(x = "城镇", y = "癌症死亡率", colour = "性别") +
241+
ggplot(data = alabama_us_cancer_rates, aes(x = rate, xmin = LCL95, xmax = UCL95, y = reorder(county, rate), colour = sex)) +
242+
geom_pointrange() +
243+
labs(x = "癌症死亡率", y = "城镇", colour = "性别") +
245244
theme_minimal()
246245
```
247246

content/post/2022-04-23-choropleth-map/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1079,7 +1079,7 @@ <h1>环境信息</h1>
10791079
#
10801080
# Package version:
10811081
# biscale_0.2.0 blogdown_1.9 cowplot_1.1.1
1082-
# ggplot2_3.3.6 grid_4.2.0 knitr_1.39
1082+
# ggplot2_3.3.6.9000 grid_4.2.0 knitr_1.39
10831083
# lattice_0.20-45 latticeExtra_0.6-29 mapproj_1.2.8
10841084
# maps_3.4.0 mapsf_0.4.0 rmarkdown_2.14
10851085
# sf_1.0-7 tidycensus_1.2.1 tmap_3.3-3

0 commit comments

Comments
 (0)