Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Try ragg png device #830

Merged
merged 3 commits into from
Jan 14, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
41 changes: 14 additions & 27 deletions CITATION.cff
Original file line number Diff line number Diff line change
Expand Up @@ -617,6 +617,20 @@ references:
email: [email protected]
orcid: https://orcid.org/0000-0003-4880-9610
year: '2023'
- type: software
title: ragg
abstract: 'ragg: Graphic Devices Based on AGG'
notes: Suggests
url: https://ragg.r-lib.org
repository: https://CRAN.R-project.org/package=ragg
authors:
- family-names: Pedersen
given-names: Thomas Lin
email: [email protected]
orcid: https://orcid.org/0000-0002-5147-4711
- family-names: Shemanarev
given-names: Maxim
year: '2023'
- type: software
title: rmarkdown
abstract: 'rmarkdown: Dynamic Documents for R'
Expand Down Expand Up @@ -668,33 +682,6 @@ references:
given-names: Terry M
email: [email protected]
year: '2023'
- type: software
title: svglite
abstract: 'svglite: An ''SVG'' Graphics Device'
notes: Suggests
url: https://svglite.r-lib.org
repository: https://CRAN.R-project.org/package=svglite
authors:
- family-names: Wickham
given-names: Hadley
email: [email protected]
- family-names: Henry
given-names: Lionel
email: [email protected]
- family-names: Pedersen
given-names: Thomas Lin
email: [email protected]
orcid: https://orcid.org/0000-0002-5147-4711
- family-names: Luciani
given-names: T Jake
email: [email protected]
- family-names: Decorde
given-names: Matthieu
email: [email protected]
- family-names: Lise
given-names: Vaudor
email: [email protected]
year: '2023'
- type: software
title: testthat
abstract: 'testthat: Unit Testing for R'
Expand Down
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -63,9 +63,9 @@ Suggests:
metaplus,
PMCMRplus,
psych,
ragg,
rmarkdown,
survival,
svglite,
testthat (>= 3.1.6),
tibble,
vdiffr,
Expand Down
20 changes: 10 additions & 10 deletions codemeta.json
Original file line number Diff line number Diff line change
Expand Up @@ -219,39 +219,39 @@
},
{
"@type": "SoftwareApplication",
"identifier": "rmarkdown",
"name": "rmarkdown",
"identifier": "ragg",
"name": "ragg",
"provider": {
"@id": "https://cran.r-project.org",
"@type": "Organization",
"name": "Comprehensive R Archive Network (CRAN)",
"url": "https://cran.r-project.org"
},
"sameAs": "https://CRAN.R-project.org/package=rmarkdown"
"sameAs": "https://CRAN.R-project.org/package=ragg"
},
{
"@type": "SoftwareApplication",
"identifier": "survival",
"name": "survival",
"identifier": "rmarkdown",
"name": "rmarkdown",
"provider": {
"@id": "https://cran.r-project.org",
"@type": "Organization",
"name": "Comprehensive R Archive Network (CRAN)",
"url": "https://cran.r-project.org"
},
"sameAs": "https://CRAN.R-project.org/package=survival"
"sameAs": "https://CRAN.R-project.org/package=rmarkdown"
},
{
"@type": "SoftwareApplication",
"identifier": "svglite",
"name": "svglite",
"identifier": "survival",
"name": "survival",
"provider": {
"@id": "https://cran.r-project.org",
"@type": "Organization",
"name": "Comprehensive R Archive Network (CRAN)",
"url": "https://cran.r-project.org"
},
"sameAs": "https://CRAN.R-project.org/package=svglite"
"sameAs": "https://CRAN.R-project.org/package=survival"
},
{
"@type": "SoftwareApplication",
Expand Down Expand Up @@ -522,7 +522,7 @@
},
"SystemRequirements": null
},
"fileSize": "9519.653KB",
"fileSize": "9518.993KB",
"citation": [
{
"@type": "ScholarlyArticle",
Expand Down
20 changes: 11 additions & 9 deletions vignettes/setup.R
Original file line number Diff line number Diff line change
@@ -1,12 +1,3 @@
knitr::opts_chunk$set(
collapse = TRUE,
comment = "#>",
warning = FALSE,
message = FALSE,
out.width = "100%",
dpi = 300
)

# to pretty-print all columns in the output tibble
options(
tibble.width = Inf,
Expand All @@ -16,6 +7,17 @@ options(
pillar.min_chars = Inf
)

device <- ifelse(requireNamespace("ragg", quietly = TRUE), "ragg_png", "svg")
knitr::opts_chunk$set(
collapse = TRUE,
comment = "#>",
warning = FALSE,
message = FALSE,
out.width = "100%",
dpi = 300,
dev = device
)

# local library
library(ggstatsplot)

Expand Down
4 changes: 1 addition & 3 deletions vignettes/web_only/faq.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -23,16 +23,14 @@ source("../setup.R")
#| include = FALSE

pkgs <- c(
"PMCMRplus",
"svglite"
"PMCMRplus"
)

successfully_loaded <- purrr::map_lgl(pkgs, requireNamespace, quietly = TRUE)
can_evaluate <- all(successfully_loaded)

if (can_evaluate) {
purrr::walk(pkgs, library, character.only = TRUE)
# knitr::opts_chunk$set(eval = TRUE)
} else {
knitr::opts_chunk$set(eval = FALSE)
}
Expand Down
4 changes: 1 addition & 3 deletions vignettes/web_only/ggbetweenstats.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -23,16 +23,14 @@ source("../setup.R")

pkgs <- c(
"gapminder",
"PMCMRplus",
"svglite"
"PMCMRplus"
)

successfully_loaded <- purrr::map_lgl(pkgs, requireNamespace, quietly = TRUE)
can_evaluate <- all(successfully_loaded)

if (can_evaluate) {
purrr::walk(pkgs, library, character.only = TRUE)
# knitr::opts_chunk$set(eval = TRUE)
} else {
knitr::opts_chunk$set(eval = FALSE)
}
Expand Down
4 changes: 1 addition & 3 deletions vignettes/web_only/ggcoefstats.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -26,16 +26,14 @@ pkgs <- c(
"BayesFactor",
"lme4",
"metaplus",
"survival",
"svglite"
"survival"
)

successfully_loaded <- purrr::map_lgl(pkgs, requireNamespace, quietly = TRUE)
can_evaluate <- all(successfully_loaded)

if (can_evaluate) {
purrr::walk(pkgs, library, character.only = TRUE)
knitr::opts_chunk$set(eval = TRUE)
} else {
knitr::opts_chunk$set(eval = FALSE)
}
Expand Down
4 changes: 1 addition & 3 deletions vignettes/web_only/ggcorrmat.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -23,16 +23,14 @@ source("../setup.R")
#| include = FALSE

pkgs <- c(
"gapminder",
"svglite"
"gapminder"
)

successfully_loaded <- purrr::map_lgl(pkgs, requireNamespace, quietly = TRUE)
can_evaluate <- all(successfully_loaded)

if (can_evaluate) {
purrr::walk(pkgs, library, character.only = TRUE)
knitr::opts_chunk$set(eval = TRUE)
} else {
knitr::opts_chunk$set(eval = FALSE)
}
Expand Down
4 changes: 1 addition & 3 deletions vignettes/web_only/gghistostats.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -29,16 +29,14 @@ source("../setup.R")
#| include = FALSE

pkgs <- c(
"psych",
"svglite"
"psych"
)

successfully_loaded <- purrr::map_lgl(pkgs, requireNamespace, quietly = TRUE)
can_evaluate <- all(successfully_loaded)

if (can_evaluate) {
purrr::walk(pkgs, library, character.only = TRUE)
knitr::opts_chunk$set(eval = TRUE)
} else {
knitr::opts_chunk$set(eval = FALSE)
}
Expand Down
4 changes: 1 addition & 3 deletions vignettes/web_only/ggscatterstats.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -21,16 +21,14 @@ source("../setup.R")
#| label = "suggested_pkgs",
#| include = FALSE
pkgs <- c(
"ggside",
"svglite"
"ggside"
)

successfully_loaded <- purrr::map_lgl(pkgs, requireNamespace, quietly = TRUE)
can_evaluate <- all(successfully_loaded)

if (can_evaluate) {
purrr::walk(pkgs, library, character.only = TRUE)
knitr::opts_chunk$set(eval = TRUE)
} else {
knitr::opts_chunk$set(eval = FALSE)
}
Expand Down
2 changes: 0 additions & 2 deletions vignettes/web_only/ggwithinstats.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ source("../setup.R")
pkgs <- c(
"afex",
"PMCMRplus",
"svglite",
"WRS2"
)

Expand All @@ -34,7 +33,6 @@ can_evaluate <- all(successfully_loaded)

if (can_evaluate) {
purrr::walk(pkgs, library, character.only = TRUE)
knitr::opts_chunk$set(eval = TRUE)
} else {
knitr::opts_chunk$set(eval = FALSE)
}
Expand Down
4 changes: 1 addition & 3 deletions vignettes/web_only/pairwise.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -23,16 +23,14 @@ source("../setup.R")
#| include = FALSE

pkgs <- c(
"PMCMRplus",
"svglite"
"PMCMRplus"
)

successfully_loaded <- purrr::map_lgl(pkgs, requireNamespace, quietly = TRUE)
can_evaluate <- all(successfully_loaded)

if (can_evaluate) {
purrr::walk(pkgs, library, character.only = TRUE)
knitr::opts_chunk$set(eval = TRUE)
} else {
knitr::opts_chunk$set(eval = FALSE)
}
Expand Down
4 changes: 1 addition & 3 deletions vignettes/web_only/principles.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -25,16 +25,14 @@ source("../setup.R")
#| include = FALSE

pkgs <- c(
"PMCMRplus",
"svglite"
"PMCMRplus"
)

successfully_loaded <- purrr::map_lgl(pkgs, requireNamespace, quietly = TRUE)
can_evaluate <- all(successfully_loaded)

if (can_evaluate) {
purrr::walk(pkgs, library, character.only = TRUE)
knitr::opts_chunk$set(eval = TRUE)
} else {
knitr::opts_chunk$set(eval = FALSE)
}
Expand Down