Skip to content

Commit

Permalink
update documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
jbengler committed Jan 22, 2024
1 parent 07d80ac commit 476daca
Show file tree
Hide file tree
Showing 11 changed files with 81 additions and 11 deletions.
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
YEAR: 2023
YEAR: 2024
COPYRIGHT HOLDER: Jan Broder Engler
2 changes: 1 addition & 1 deletion LICENSE.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# MIT License

Copyright (c) 2023 Jan Broder Engler
Copyright (c) 2024 Jan Broder Engler

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
45 changes: 42 additions & 3 deletions README.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ pak::pak("jbengler/tidyplots")

## Usage

Here are some examples of what you can do with 3--5 lines of code.
Here are some examples of what you can do with just a few key strokes. The full documentation can be found [here](https://jbengler.github.io/tidyplots/).

```{r}
library(tidyplots)
Expand Down Expand Up @@ -71,6 +71,13 @@ energy_week %>%
```

```{r}
energy_week %>%
tidyplot(date, power, color = energy_source) %>%
add_areastack_relative()
```

```{r}
study %>%
tidyplot(x = group, y = score, color = dose) %>%
Expand All @@ -97,6 +104,38 @@ study %>%
```

## Documentation
```{r, fig.height=3.2}
gene_expression %>%
dplyr::filter(external_gene_name %in% c("Apol6", "Col5a3", "Vgf", "Bsn")) %>%
tidyplot(x = condition, y = expression, color = sample_type) %>%
add_mean_dash() %>%
add_error() %>%
add_jitter() %>%
add_stats_pvalue(include_info = FALSE) %>%
adjust_x_axis(title = "") %>%
split_plot(by = external_gene_name)
```


## Acknowledgements

tidyplots relies on a number of fantastic packages that do all the heavy lifting behind the scenes. These include
cli,
dplyr,
forcats,
ggplot2,
ggpubr,
ggrastr,
ggrepel,
glue,
Hmisc,
patchwork,
purrr,
ragg,
rlang,
scales,
stringr,
svglite and
tidyr.

https://jbengler.github.io/tidyplots/
39 changes: 33 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,9 @@ pak::pak("jbengler/tidyplots")

## Usage

Here are some examples of what you can do with 3–5 lines of code.
Here are some examples of what you can do with just a few key strokes.
The full documentation can be found
[here](https://jbengler.github.io/tidyplots/).

``` r
library(tidyplots)
Expand Down Expand Up @@ -61,6 +63,14 @@ energy_week %>%

<img src="man/figures/README-unnamed-chunk-5-1.png" style="display: block; margin: auto;" />

``` r
energy_week %>%
tidyplot(date, power, color = energy_source) %>%
add_areastack_relative()
```

<img src="man/figures/README-unnamed-chunk-6-1.png" style="display: block; margin: auto;" />

``` r
study %>%
tidyplot(x = group, y = score, color = dose) %>%
Expand All @@ -69,7 +79,7 @@ study %>%
add_mean_value()
```

<img src="man/figures/README-unnamed-chunk-6-1.png" style="display: block; margin: auto;" />
<img src="man/figures/README-unnamed-chunk-7-1.png" style="display: block; margin: auto;" />

``` r
time_course %>%
Expand All @@ -79,7 +89,7 @@ time_course %>%
add_error_ribbon()
```

<img src="man/figures/README-unnamed-chunk-7-1.png" style="display: block; margin: auto;" />
<img src="man/figures/README-unnamed-chunk-8-1.png" style="display: block; margin: auto;" />

``` r
study %>%
Expand All @@ -88,8 +98,25 @@ study %>%
add_stats_pvalue(ref.group = 1)
```

<img src="man/figures/README-unnamed-chunk-8-1.png" style="display: block; margin: auto;" />
<img src="man/figures/README-unnamed-chunk-9-1.png" style="display: block; margin: auto;" />

``` r
gene_expression %>%
dplyr::filter(external_gene_name %in% c("Apol6", "Col5a3", "Vgf", "Bsn")) %>%
tidyplot(x = condition, y = expression, color = sample_type) %>%
add_mean_dash() %>%
add_error() %>%
add_jitter() %>%
add_stats_pvalue(include_info = FALSE) %>%
adjust_x_axis(title = "") %>%
split_plot(by = external_gene_name)
```

<img src="man/figures/README-unnamed-chunk-10-1.png" style="display: block; margin: auto;" />

## Documentation
## Acknowledgements

<https://jbengler.github.io/tidyplots/>
tidyplots relies on a number of fantastic packages that do all the heavy
lifting behind the scenes. These include cli, dplyr, forcats, ggplot2,
ggpubr, ggrastr, ggrepel, glue, Hmisc, patchwork, purrr, ragg, rlang,
scales, stringr, svglite and tidyr.
4 changes: 4 additions & 0 deletions _pkgdown.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@ url: https://jbengler.github.io/tidyplots/
template:
bootstrap: 5

authors:
Jan Broder Engler:
href: https://github.com/jbengler

reference:
- title:
desc: >
Expand Down
Binary file added man/figures/README-unnamed-chunk-10-1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified man/figures/README-unnamed-chunk-2-1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified man/figures/README-unnamed-chunk-6-1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified man/figures/README-unnamed-chunk-7-1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified man/figures/README-unnamed-chunk-8-1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified man/figures/README-unnamed-chunk-9-1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 476daca

Please sign in to comment.