From 1e766d33d6a0c409d14352d2ad07deee9e3acdc7 Mon Sep 17 00:00:00 2001 From: mtennekes Date: Wed, 6 Mar 2024 17:20:21 +0100 Subject: [PATCH] finetuning, testing images --- R/c4a_gui.R | 1 - R/onLoad.R | 4 ++-- README.Rmd | 29 +---------------------------- 3 files changed, 3 insertions(+), 31 deletions(-) diff --git a/R/c4a_gui.R b/R/c4a_gui.R index 12f7b1f..9f6ee58 100644 --- a/R/c4a_gui.R +++ b/R/c4a_gui.R @@ -56,7 +56,6 @@ c4a_gui = function(type = "cat", n = NA, series = "all") { shiny::addResourcePath(prefix = "imgResources", directoryPath = system.file("man/figures", package = "cols4all")) - shiny::addResourcePath(prefix = "imgResources", directoryPath = system.file("img", package = "cols4all")) ############################# ## Catelogue tab diff --git a/R/onLoad.R b/R/onLoad.R index 1a25476..d705e26 100644 --- a/R/onLoad.R +++ b/R/onLoad.R @@ -274,8 +274,8 @@ do_cellspec = function(lst) { tc = list(cbfriendly = list('NA' = "", '0' = "", - '2' = list("☺☺", extra_css="font-size: 80%;", tooltip = "Colorblind-friendly!", escape = FALSE), - '1' = list("☺", extra_css="font-size: 80%;", tooltip = "Colorblind-friendly!", escape = FALSE), + '2' = list("☺☺", extra_css="font-size: 80%;", tooltip = "Extra colorblind-friendly! Also for points and lines", escape = FALSE), + '1' = list("☺", extra_css="font-size: 80%;", tooltip = "Colorblind-friendly! Be careful with points and lines", escape = FALSE), '-1' = list("👀", extra_css ="font-size: 60%;", tooltip = "Be careful! Some colors are hard to distinguish by color blind people (see tab 'Color Blind Friendliness'", escape = FALSE)), chroma = list('NA' = "", 'H' = list("🕶", tooltip = "Vivid colors (high chroma): ideal for small important objects to stand out (e.g. markers on a map), but less suited for space filling visualizations (see tab 'HCL Analysis')", escape = FALSE), diff --git a/README.Rmd b/README.Rmd index fa68d8a..3241c0f 100644 --- a/README.Rmd +++ b/README.Rmd @@ -82,7 +82,7 @@ The main tool is a dashboard, which is started with: c4a_gui() ``` -[](figures/cols4all_table3.png) +[](vignettes/dash-3.png) What types and series are available? @@ -212,30 +212,3 @@ There are a few other pacakges with a large collection of color palettes, in par * Do you have ideas for improvement how to measure palette properties? Let us know! (via github issues) - - -## Bonus: 2568 palettes from **paletteer** - -The R package [**paletteer**](https://github.com/EmilHvitfeldt/paletteer) contains 2568 from 70 other R packages. These have been converted to data for **cols4all** [(script)](https://github.com/mtennekes/cols4all/blob/main/build/build_paletteer.R) - -These can be loaded and analysed as follows: - -```{r} -paletteer_data = readRDS(url("https://github.com/mtennekes/cols4all/releases/download/v0.6/paletteer.rds","rb")) -c4a_sysdata_import(paletteer_data) -``` - -Note that we use `c4a_sysdata_import` rather than `c4a_load` because we want to replace all the palette data to avoid overlap and conflicts with the palettes already included in **cols4all**. - - -```{r} -c4a_overview() -``` - -```{r, eval=FALSE} -c4a_gui() -``` - -![https://user-images.githubusercontent.com/2444081/216455415-de676d12-8e94-4917-8adc-8ca1e6ac4df7.png](https://user-images.githubusercontent.com/2444081/216455415-de676d12-8e94-4917-8adc-8ca1e6ac4df7.png) - -Note that this dashboard is not particularly fast (so grab a coffee:-))