R/ggplot2 save the Chinese font of the picture to PDF - showtext package removes all obstacles

Article summary 1. Solve the problem that the Chinese font of the picture saved by R/ggplot2 is lost to PDF. 2. Solve the problem of failed import of Times New Roman and simsun fonts. 3. Be familiar with and master showtext operation. 1. Problem description After drawing with ggplot2, use ggsave to save the picture. The Chinese font is l ...

Added by spasm37 on Fri, 04 Mar 2022 02:57:07 +0200

ggplot2 - data collation 2

1. separate and unite spread and gather functions can help solve the problem of misplaced variables in data, while separate and unite are used to solve the following problems: multiple variables are crowded in the same column, or a variable is scattered into different columns For example, the following data set records the response data of a ...

Added by lore_lanu on Thu, 30 Dec 2021 11:01:32 +0200

R language ggplot2 scientific research drawing subject parameter adjustment

This chapter is the twelfth chapter of ggplot2 scientific research drawing adjustment. Please skip the contents of the first ten chapters: ggplot nanny tutorial - details of scientific research drawing parameter adjustment data set This article uses the air pollution incidence rate and mortality study (NMMAPS). In order to make the chart eas ...

Added by rocksolidhq on Sun, 19 Dec 2021 18:53:56 +0200