Skip to content

Commit

Permalink
Move global option note into FAQ vignette
Browse files Browse the repository at this point in the history
  • Loading branch information
nanxstats committed Mar 8, 2023
1 parent 65a5aad commit 5e3d637
Showing 1 changed file with 0 additions and 21 deletions.
21 changes: 0 additions & 21 deletions README.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -53,27 +53,6 @@ remotes::install_github("nanxstats/ggsci")
[Browse the vignette](https://nanx.me/ggsci/articles/ggsci.html) (or open with
`vignette("ggsci")` in R) for a quick-start guide.

## Usage

```{r, eval=FALSE}
library(ggsci)
#in base plots
x = factor(mtcars$cyl, labels=pal_jama()(3))
plot(x = mtcars$mpg, y = mtcars$hp, col = x, pch = 16)
#in ggplot2
library(ggplot2)
ggplot(mtcars, aes(x = mpg, y = hp, color = factor(cyl))) +
geom_point() +
scale_color_nejm()
#in ggplot2, using options
options(ggplot2.discrete.colour=ggsci::scale_colour_lancet)
ggplot(mtcars, aes(x = mpg, y = hp, color = factor(cyl))) +
geom_point()
```

## Gallery

```{r}
Expand Down

0 comments on commit 5e3d637

Please sign in to comment.