Skip to content

Commit

Permalink
Update doc
Browse files Browse the repository at this point in the history
  • Loading branch information
boxuancui committed Jan 22, 2024
1 parent 81d3235 commit 1c2f3f9
Show file tree
Hide file tree
Showing 9 changed files with 375 additions and 14 deletions.
3 changes: 2 additions & 1 deletion R/plot_boxplot.r
Expand Up @@ -30,7 +30,8 @@
#' plot_boxplot(skew, by = "y", scale_y = "log10", ncol = 2L)
#'
#' # Plot with `geom_jitter`
#' plot_boxplot(iris, by = "Species", ncol = 2L, geom_jitter_args = list(width = NULL)) # Turn on with default settings
#' plot_boxplot(iris, by = "Species", ncol = 2L,
#' geom_jitter_args = list(width = NULL)) # Turn on with default settings

plot_boxplot <- function(data, by,
binary_as_factor = TRUE,
Expand Down
6 changes: 4 additions & 2 deletions R/plot_missing.r
Expand Up @@ -20,11 +20,13 @@
#'
#' ## Customize band
#' plot_missing(airquality, group = list("B1" = 0, "B2" = 0.06, "B3" = 1))
#' plot_missing(airquality, group = list("Awesome!" = 0.2, "Oh no!" = 1), group_color = list("Awesome!" = "green", "Oh no!" = "red"))
#' plot_missing(airquality, group = list("Awesome!" = 0.2, "Oh no!" = 1),
#' group_color = list("Awesome!" = "green", "Oh no!" = "red"))
#'
#' ## Shrink geom_label size
#' library(ggplot2)
#' plot_missing(airquality, geom_label_args = list("size" = 2, "label.padding" = unit(0.1, "lines")))
#' plot_missing(airquality, geom_label_args = list("size" = 2,
#' "label.padding" = unit(0.1, "lines")))

plot_missing <- function(data,
group = list("Good" = 0.05, "OK" = 0.4, "Bad" = 0.8, "Remove" = 1),
Expand Down
9 changes: 6 additions & 3 deletions R/plot_scatterplot.r
Expand Up @@ -27,11 +27,14 @@
#' set.seed(1)
#' skew <- data.frame(replicate(5L, rbeta(1000, 1, 5000)))
#' plot_scatterplot(skew, by = "X5", ncol = 2L)
#' plot_scatterplot(skew, by = "X5", scale_x = "log10", scale_y = "log10", ncol = 2L)
#' plot_scatterplot(skew, by = "X5", scale_x = "log10",
#' scale_y = "log10", ncol = 2L)
#'
#' # Plot with `geom_jitter`
#' plot_scatterplot(iris, by = "Species", geom_jitter_args = list(width = NULL)) # Turn on with default settings
#' plot_scatterplot(iris, by = "Species", geom_jitter_args = list(width = 0.1, height = 0.1))
#' plot_scatterplot(iris, by = "Species",
#' geom_jitter_args = list(width = NULL)) # Turn on with default settings
#' plot_scatterplot(iris, by = "Species",
#' geom_jitter_args = list(width = 0.1, height = 0.1))
#'
#' \dontrun{
#' # Customize themes
Expand Down
2 changes: 1 addition & 1 deletion README.Rmd
Expand Up @@ -23,7 +23,7 @@ knitr::opts_chunk$set(
[![Downloads](http://cranlogs.r-pkg.org/badges/DataExplorer)](https://cran.r-project.org/package=DataExplorer)
[![Total Downloads](http://cranlogs.r-pkg.org/badges/grand-total/DataExplorer)](https://cran.r-project.org/package=DataExplorer)
[![R-CMD-check](https://github.com/boxuancui/DataExplorer/actions/workflows/check-standard.yaml/badge.svg)](https://github.com/boxuancui/DataExplorer/actions/workflows/check-standard.yaml)
[![codecov](https://codecov.io/gh/boxuancui/DataExplorer/branch/master/graph/badge.svg)](https://codecov.io/gh/boxuancui/DataExplorer/branch/master)
[![codecov](https://codecov.io/gh/boxuancui/DataExplorer/graph/badge.svg?token=w8eMGjF8Jw)](https://codecov.io/gh/boxuancui/DataExplorer)
[![CII Best Practices](https://bestpractices.coreinfrastructure.org/projects/2053/badge)](https://bestpractices.coreinfrastructure.org/projects/2053)
[![GitHub Stars](https://img.shields.io/github/stars/boxuancui/DataExplorer.svg?style=social)](https://github.com/boxuancui/DataExplorer)

Expand Down
2 changes: 1 addition & 1 deletion README.md
Expand Up @@ -7,7 +7,7 @@ Version](http://www.r-pkg.org/badges/version/DataExplorer)](https://cran.r-proje
[![Total
Downloads](http://cranlogs.r-pkg.org/badges/grand-total/DataExplorer)](https://cran.r-project.org/package=DataExplorer)
[![R-CMD-check](https://github.com/boxuancui/DataExplorer/actions/workflows/check-standard.yaml/badge.svg)](https://github.com/boxuancui/DataExplorer/actions/workflows/check-standard.yaml)
[![codecov](https://codecov.io/gh/boxuancui/DataExplorer/branch/master/graph/badge.svg)](https://codecov.io/gh/boxuancui/DataExplorer/branch/master)
[![codecov](https://codecov.io/gh/boxuancui/DataExplorer/graph/badge.svg?token=w8eMGjF8Jw)](https://codecov.io/gh/boxuancui/DataExplorer)
[![CII Best
Practices](https://bestpractices.coreinfrastructure.org/projects/2053/badge)](https://bestpractices.coreinfrastructure.org/projects/2053)
[![GitHub
Expand Down
3 changes: 2 additions & 1 deletion man/plot_boxplot.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 4 additions & 2 deletions man/plot_missing.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 6 additions & 3 deletions man/plot_scatterplot.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 1c2f3f9

Please sign in to comment.