|
1 |
| -# Generate internal color palettes data `R/sysdata.rda`: |
2 |
| -# - R Packages - Internal data. <https://r-pkgs.org/data.html#sec-data-sysdata> |
3 |
| -# - Name that Color. <http://chir.ag/projects/name-that-color/> |
| 1 | +# Construct color palettes data |
| 2 | +# |
| 3 | +# If not available, the color names are generated by "Name that Color" at |
| 4 | +# <http://chir.ag/projects/name-that-color/>. |
4 | 5 |
|
5 | 6 | ggsci_db <- vector("list")
|
6 | 7 |
|
@@ -487,60 +488,3 @@ ggsci_db$"material"$"blue-grey" <- c(
|
487 | 488 | "BlueGrey600" = "#546E7A", "BlueGrey700" = "#455A64",
|
488 | 489 | "BlueGrey800" = "#37474F", "BlueGrey900" = "#263238"
|
489 | 490 | )
|
490 |
| - |
491 |
| -save(ggsci_db, file = "R/sysdata.rda") |
492 |
| - |
493 |
| -test_barplot <- function(palette, type) { |
494 |
| - pal <- ggsci_db[[palette]][[type]] |
495 |
| - barplot(rep(1, length(pal)), col = pal) |
496 |
| -} |
497 |
| - |
498 |
| -test_barplot("npg", "nrc") |
499 |
| -test_barplot("aaas", "default") |
500 |
| -test_barplot("nejm", "default") |
501 |
| -test_barplot("lancet", "lanonc") |
502 |
| -test_barplot("jama", "default") |
503 |
| -test_barplot("bmj", "default") |
504 |
| -test_barplot("jco", "default") |
505 |
| -test_barplot("ucscgb", "default") |
506 |
| -test_barplot("d3", "category10") |
507 |
| -test_barplot("d3", "category20") |
508 |
| -test_barplot("d3", "category20b") |
509 |
| -test_barplot("d3", "category20c") |
510 |
| -test_barplot("locuszoom", "default") |
511 |
| -test_barplot("igv", "default") |
512 |
| -test_barplot("igv", "alternating") |
513 |
| -test_barplot("uchicago", "default") |
514 |
| -test_barplot("uchicago", "light") |
515 |
| -test_barplot("uchicago", "dark") |
516 |
| -test_barplot("cosmic", "hallmarks_dark") |
517 |
| -test_barplot("cosmic", "hallmarks_light") |
518 |
| -test_barplot("cosmic", "signature_substitutions") |
519 |
| -test_barplot("startrek", "uniform") |
520 |
| -test_barplot("tron", "legacy") |
521 |
| -test_barplot("futurama", "planetexpress") |
522 |
| -test_barplot("rickandmorty", "schwifty") |
523 |
| -test_barplot("simpsons", "springfield") |
524 |
| -test_barplot("gsea", "default") |
525 |
| -test_barplot("flatui", "default") |
526 |
| -test_barplot("flatui", "flattastic") |
527 |
| -test_barplot("flatui", "aussie") |
528 |
| -test_barplot("material", "red") |
529 |
| -test_barplot("material", "pink") |
530 |
| -test_barplot("material", "purple") |
531 |
| -test_barplot("material", "deep-purple") |
532 |
| -test_barplot("material", "indigo") |
533 |
| -test_barplot("material", "blue") |
534 |
| -test_barplot("material", "light-blue") |
535 |
| -test_barplot("material", "cyan") |
536 |
| -test_barplot("material", "teal") |
537 |
| -test_barplot("material", "green") |
538 |
| -test_barplot("material", "light-green") |
539 |
| -test_barplot("material", "lime") |
540 |
| -test_barplot("material", "yellow") |
541 |
| -test_barplot("material", "amber") |
542 |
| -test_barplot("material", "orange") |
543 |
| -test_barplot("material", "deep-orange") |
544 |
| -test_barplot("material", "brown") |
545 |
| -test_barplot("material", "grey") |
546 |
| -test_barplot("material", "blue-grey") |
0 commit comments