{"id":318362,"name":"nmfspalette","description":"R color palette for NOAA Fisheries official colors.","url":"https://github.com/nmfs-ost/nmfspalette","last_synced_at":"2026-05-19T23:30:44.517Z","repository":{"id":44883928,"uuid":"313710547","full_name":"nmfs-ost/nmfspalette","owner":"nmfs-ost","description":":art: R color palettes for NOAA Fisheries official colors","archived":false,"fork":false,"pushed_at":"2025-11-25T19:03:33.000Z","size":3158,"stargazers_count":36,"open_issues_count":3,"forks_count":10,"subscribers_count":5,"default_branch":"main","last_synced_at":"2026-04-30T16:34:20.590Z","etag":null,"topics":["color-palette","noaa","noaa-nsap","r"],"latest_commit_sha":null,"homepage":"https://nmfs-ost.github.io/nmfspalette/","language":"R","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/nmfs-ost.png","metadata":{"files":{"readme":"README.Rmd","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2020-11-17T18:40:41.000Z","updated_at":"2025-11-25T17:49:18.000Z","dependencies_parsed_at":"2022-07-21T15:36:12.030Z","dependency_job_id":"dc45b18f-6737-4825-a274-47f2130dfa0a","html_url":"https://github.com/nmfs-ost/nmfspalette","commit_stats":{"total_commits":118,"total_committers":6,"mean_commits":"19.666666666666668","dds":0.2796610169491526,"last_synced_commit":"26efb448e4cb1539ad70bbbba99a5ef35ceb7500"},"previous_names":["nmfs-ost/nmfspalette","nmfs-fish-tools/nmfspalette"],"tags_count":7,"template":false,"template_full_name":null,"purl":"pkg:github/nmfs-ost/nmfspalette","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nmfs-ost%2Fnmfspalette","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nmfs-ost%2Fnmfspalette/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nmfs-ost%2Fnmfspalette/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nmfs-ost%2Fnmfspalette/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nmfs-ost","download_url":"https://codeload.github.com/nmfs-ost/nmfspalette/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nmfs-ost%2Fnmfspalette/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32741027,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-07T02:14:30.463Z","status":"ssl_error","status_checked_at":"2026-05-07T02:14:29.405Z","response_time":62,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"owner":{"login":"nmfs-ost","name":"Office of Science \u0026 Technology at NOAA Fisheries","uuid":"72827324","kind":"organization","description":"Providing the science behind how we manage sustainable fisheries, protected species, and healthy ecosystems.","email":null,"website":"https://www.fisheries.noaa.gov/about/office-science-and-technology","location":null,"twitter":null,"company":null,"icon_url":"https://avatars.githubusercontent.com/u/72827324?v=4","repositories_count":2,"last_synced_at":"2023-12-04T16:54:14.239Z","metadata":{"has_sponsors_listing":false},"html_url":"https://github.com/nmfs-ost","funding_links":[],"total_stars":null,"followers":null,"following":null,"created_at":"2022-11-14T06:42:30.845Z","updated_at":"2023-12-04T16:54:14.841Z","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nmfs-ost","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nmfs-ost/repositories"},"packages":[],"commits":{"id":9583667,"full_name":"nmfs-ost/nmfspalette","default_branch":"main","total_commits":169,"total_committers":9,"total_bot_commits":13,"total_bot_committers":1,"mean_commits":18.77777777777778,"dds":0.4497041420118343,"past_year_total_commits":21,"past_year_total_committers":4,"past_year_total_bot_commits":7,"past_year_total_bot_committers":1,"past_year_mean_commits":5.25,"past_year_dds":0.4285714285714286,"last_synced_at":"2026-04-13T06:01:26.503Z","last_synced_commit":"99293b96c2b58fc534e608bbf147cd6cf210a995","created_at":"2025-04-09T20:54:48.475Z","updated_at":"2026-04-13T06:01:23.269Z","committers":[{"name":"ChristineStawitz-NOAA","email":"christine.stawitz@noaa.gov","login":"ChristineStawitz-NOAA","count":93},{"name":"sbreitbart-NOAA","email":"sophie.breitbart@noaa.gov","login":"sbreitbart-NOAA","count":22},{"name":"Bai Li","email":"bai.li@noaa.gov","login":"Bai-Li-NOAA","count":21},{"name":"Kathryn Doering","email":"kathryn.doering@noaa.gov","login":"k-doering-NOAA","count":16},{"name":"github-actions[bot]","email":"41898282+github-actions[bot]","login":"github-actions[bot]","count":13},{"name":"corinne.bassin","email":"corinne.bassin@noaa.gov","login":"CorinneBassin-NOAA","count":1},{"name":"Nicholas Tierney","email":"njtierney","login":"njtierney","count":1},{"name":"Julie Rose","email":"161734285+julierose-NOAA","login":"julierose-NOAA","count":1},{"name":"Haley Oleynik","email":"78555815+HaleyOleynik-NOAA","login":"HaleyOleynik-NOAA","count":1}],"past_year_committers":[{"name":"sbreitbart-NOAA","email":"sophie.breitbart@noaa.gov","login":"sbreitbart-NOAA","count":12},{"name":"github-actions[bot]","email":"41898282+github-actions[bot]","login":"github-actions[bot]","count":7},{"name":"Nicholas Tierney","email":"njtierney","login":"njtierney","count":1},{"name":"Kathryn Doering","email":"kathryn.doering@noaa.gov","login":"k-doering-NOAA","count":1}],"commits_url":"https://commits.ecosyste.ms/api/v1/hosts/GitHub/repositories/nmfs-ost%2Fnmfspalette/commits","host":{"name":"GitHub","url":"https://github.com","kind":"github","last_synced_at":"2026-04-15T00:00:09.512Z","repositories_count":6213593,"commits_count":903370865,"contributors_count":34924174,"owners_count":1144562,"icon_url":"https://github.com/github.png","host_url":"https://commits.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://commits.ecosyste.ms/api/v1/hosts/GitHub/repositories"}},"issues_stats":{"full_name":"nmfs-ost/nmfspalette","html_url":"https://github.com/nmfs-ost/nmfspalette","last_synced_at":"2026-04-01T00:00:46.271Z","status":"error","issues_count":13,"pull_requests_count":69,"avg_time_to_close_issue":12079807.3,"avg_time_to_close_pull_request":390346.21875,"issues_closed_count":10,"pull_requests_closed_count":64,"pull_request_authors_count":7,"issue_authors_count":9,"avg_comments_per_issue":1.0,"avg_comments_per_pull_request":0.6376811594202898,"merged_pull_requests_count":56,"bot_issues_count":0,"bot_pull_requests_count":43,"past_year_issues_count":4,"past_year_pull_requests_count":46,"past_year_avg_time_to_close_issue":5178277.0,"past_year_avg_time_to_close_pull_request":184101.73170731709,"past_year_issues_closed_count":1,"past_year_pull_requests_closed_count":41,"past_year_pull_request_authors_count":5,"past_year_issue_authors_count":4,"past_year_avg_comments_per_issue":0.5,"past_year_avg_comments_per_pull_request":0.9130434782608695,"past_year_bot_issues_count":0,"past_year_bot_pull_requests_count":29,"past_year_merged_pull_requests_count":36,"created_at":"2025-04-09T20:54:48.567Z","updated_at":"2026-04-01T00:00:46.271Z","repository_url":"https://issues.ecosyste.ms/api/v1/hosts/GitHub/repositories/nmfs-ost%2Fnmfspalette","issues_url":"https://issues.ecosyste.ms/api/v1/hosts/GitHub/repositories/nmfs-ost%2Fnmfspalette/issues","issue_labels_count":{"enhancement":3,"question":1},"pull_request_labels_count":{"enhancement":1},"issue_author_associations_count":{"CONTRIBUTOR":7,"NONE":5,"COLLABORATOR":1},"pull_request_author_associations_count":{"CONTRIBUTOR":57,"COLLABORATOR":11,"NONE":1},"issue_authors":{"ChristineStawitz-NOAA":3,"k-doering-NOAA":3,"iantaylor-NOAA":1,"kellijohnson-NOAA":1,"ericward-noaa":1,"sbreitbart-NOAA":1,"okenk":1,"jonpeake":1,"haleyoleynik":1},"pull_request_authors":{"github-actions[bot]":43,"sbreitbart-NOAA":11,"k-doering-NOAA":7,"Bai-Li-NOAA":4,"njtierney":2,"ChristineStawitz-NOAA":1,"julierose-NOAA":1},"host":{"name":"GitHub","url":"https://github.com","kind":"github","last_synced_at":"2026-04-15T00:00:09.535Z","repositories_count":14269060,"issues_count":34630327,"pull_requests_count":113269358,"authors_count":11234946,"icon_url":"https://github.com/github.png","host_url":"https://issues.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://issues.ecosyste.ms/api/v1/hosts/GitHub/repositories","owners_url":"https://issues.ecosyste.ms/api/v1/hosts/GitHub/owners","authors_url":"https://issues.ecosyste.ms/api/v1/hosts/GitHub/authors"},"past_year_issue_labels_count":{"enhancement":1,"question":1},"past_year_pull_request_labels_count":{"enhancement":1},"past_year_issue_author_associations_count":{"NONE":2,"COLLABORATOR":1},"past_year_pull_request_author_associations_count":{"CONTRIBUTOR":22,"COLLABORATOR":8,"NONE":1},"past_year_issue_authors":{"jonpeake":1,"kellijohnson-NOAA":1,"sbreitbart-NOAA":1},"past_year_pull_request_authors":{"github-actions[bot]":19,"sbreitbart-NOAA":8,"k-doering-NOAA":2,"njtierney":2},"maintainers":[{"login":"sbreitbart-NOAA","count":12,"url":"https://issues.ecosyste.ms/api/v1/hosts/GitHub/authors/sbreitbart-NOAA"}],"active_maintainers":[{"login":"sbreitbart-NOAA","count":9,"url":"https://issues.ecosyste.ms/api/v1/hosts/GitHub/authors/sbreitbart-NOAA"}]},"events":{"total":{"ReleaseEvent":1,"DeleteEvent":10,"PullRequestEvent":25,"ForkEvent":2,"IssuesEvent":2,"WatchEvent":6,"IssueCommentEvent":22,"PushEvent":48,"PullRequestReviewEvent":30,"PullRequestReviewCommentEvent":38,"CreateEvent":13},"last_year":{"ReleaseEvent":1,"DeleteEvent":9,"PullRequestEvent":23,"ForkEvent":2,"IssuesEvent":1,"WatchEvent":6,"IssueCommentEvent":19,"PushEvent":45,"PullRequestReviewEvent":30,"PullRequestReviewCommentEvent":38,"CreateEvent":12}},"keywords":["color-palette","noaa","noaa-nsap","r"],"dependencies":[{"ecosystem":"cran","filepath":"DESCRIPTION","sha":null,"kind":"manifest","created_at":"2022-07-21T15:36:05.302Z","updated_at":"2022-07-21T15:36:05.302Z","repository_link":"https://github.com/nmfs-ost/nmfspalette/blob/main/DESCRIPTION","dependencies":[{"id":350391185,"package_name":"ggplot2","ecosystem":"cran","requirements":"*","direct":true,"kind":"imports","optional":false},{"id":350391187,"package_name":"testthat","ecosystem":"cran","requirements":"*","direct":true,"kind":"suggests","optional":false},{"id":350391189,"package_name":"dplyr","ecosystem":"cran","requirements":"*","direct":true,"kind":"suggests","optional":false}]}],"score":5.860786223465865,"created_at":"2025-06-11T00:13:40.359Z","updated_at":"2026-05-19T23:30:44.519Z","avatar_url":"https://github.com/nmfs-ost.png","language":"R","category":"Biosphere","sub_category":"Marine Life and Fishery","monthly_downloads":0,"total_dependent_repos":0,"total_dependent_packages":0,"readme":"---\noutput: github_document\n---\n\n\u003c!-- README.md is generated from README.Rmd. Please edit that file --\u003e\n\n```{r}\n#| include: false\nknitr::opts_chunk$set(\n  collapse = TRUE,\n  comment = \"#\u003e\",\n  fig.path = \"man/figures/README-\",\n  out.width = \"100%\"\n)\n```\n\n# nmfspalette \u003ca href={https:://nmfs-ost.github.io/nmfspalette}\u003e\u003cimg src=\"man/figures/logo.png\" alt=\"logo with an image of a fish in multiple palette colors\" align=\"right\" width=\"139\" height=\"139\"/\u003e\n\n\u003c!-- badges: start --\u003e\n\n[![call-r-cmd-check](https://github.com/nmfs-ost/nmfspalette/actions/workflows/call-r-cmd-check.yml/badge.svg)](https://github.com/nmfs-ost/nmfspalette/actions/workflows/call-r-cmd-check.yml)\n\n[![coverage](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/nmfs-ost/nmfspalette/refs/heads/badges/coverage-badge.json)](https://github.com/nmfs-ost/nmfspalette/tree/badges)\n\n\u003c!-- badges: end --\u003e\n\nAn R color palette for `{ggplot2}` using NOAA Fisheries branding colors.\n\n`{nmfspalette}` implements these [steps](https://drsimonj.svbtle.com/creating-corporate-colour-palettes-for-ggplot2) to create a `{ggplot2}` compatible palette according to [NOAA Fisheries branding](https://drive.google.com/file/d/1lXHmfGWCj6pI_Dr3C-Dwcnf1pXOIOztp/view?usp=sharing) (NOAA internal only).\n\n## Installation\n\nYou can install the development version of nmfspalette from [GitHub](https://github.com/) with:\n\n```r\n# install.packages(\"pak\")\npak::pak(\"nmfs-ost/nmfspalette\")\n```\n\nTo load the package, use:\n\n```{r}\n#| message: false\nlibrary(nmfspalette)\n```\n\n## Contributing\n\nWe welcome contributions to `{nmfspalette}`. You are welcome to make any changes you would like on a fork and submit a pull request. For more substantial changes or to create a branch, please contact sophie.breitbart@noaa.gov (NOAA Affiliates only). We ask that all contributors adhere to The NOAA Fisheries Integrated Toolbox [code of conduct](https://github.com/nmfs-ost/Resources/blob/main/CONTRIBUTING.md).\n\n## Usage\n\nTo learn how to use `nmfspalette`, please check out the [interactive `learnr` tutorial](https://connect.fisheries.noaa.gov/colors/).\n\nExtract an interpolated color palette from the default \"oceans\" palette.\n\nYou can change the number of colors (10 shown below).\n\n```{r}\n#| label: default_pal\nnmfs_palette(\"oceans\")(10)\n```\n\n## Theme for `ggplot` objects\n\n**New feature**: With the new `theme_nmfs()` function, you can add a NMFS-colored theme to your `ggplot` objects!\nThis new theme that applies NMFS color palettes and theme-related elements (such as label sizes, borders, axis lines, and more) to a plot.\n\n```{r}\n#| label: theme_example\n\nlibrary(ggplot2)\nggplot(mtcars, aes(x = mpg, y = disp, color = as.factor(cyl))) +\n  geom_point(size = 3) +\n  nmfspalette::theme_nmfs(discrete = TRUE, interpolate = TRUE, palette = \"crustacean\")\n```\n\n## Palettes\n\nUse the `all_nmfs_palettes()` function to see all available palettes.\n\n```{r}\n#| label: all_pals\n#| fig-height: 4\nall_nmfs_palettes()\n```\n\nUse the `display_nmfs_palette()` function to see a specific palette.\n\n### Main NOAA Fisheries palettes\n\nThese palettes contain 4 or 6 colors.\n\n#### oceans\n\n```{r}\n#| label: displ_oceans\n#| fig-height: 2\ndisplay_nmfs_palette(\"oceans\", 6)\n```\n\n\n#### waves\n\n```{r}\n#| label: displ_waves\n#| fig-height: 2\ndisplay_nmfs_palette(\"waves\", 4)\n```\n\n#### seagrass\n\n```{r}\n#| label: displ_seagrass\n#| fig-height: 2\ndisplay_nmfs_palette(\"seagrass\", 4)\n```\n\n#### urchin\n\n```{r}\n#| label: displ_urchin\n#| fig-height: 2\ndisplay_nmfs_palette(\"urchin\", 4)\n```\n\n#### crustacean\n\n```{r}\n#| label: displ_crustacean\n#| fig-height: 2\ndisplay_nmfs_palette(\"crustacean\", 4)\n```\n\n#### coral\n\n```{r}\n#| label: displ_coral\n#| fig-height: 2\ndisplay_nmfs_palette(\"coral\", 4)\n```\n\n#### regional (discrete)\n\n```{r}\n#| label: displ_regional_web\n#| fig-height: 2\ndisplay_nmfs_palette(\"regional\", 6)\n```\n\n##### Alternative regional palettes\n\nFor some with color vision deficiency (C.V.D.), it may be difficult to discern the colors in the regional palette. We have provided two alternative regional palettes, below.\n*Note*: The alternative palette 1 contains colors that are entirely within the NMFS brand color set; alternative palette 2 does not. However, the colors in alternative palette 1 may be less distinguishable for all types of color perception as opposed to alternative palette 2.\n\n```{r, fig.height = 2, displ_regional_web2}\nnmfspalette::display_nmfs_palette(\"regional_alt1\", 6)\n```\n\n```{r, fig.height = 2, displ_regional_web3}\nnmfspalette::display_nmfs_palette(\"regional_alt2\", 6)\n```\n\n\n### NOAA Fisheries complementary colors\n\nThese 5 palettes contain 4 complementary colors each and are identical to the main NOAA Fisheries palettes, but some colors have different names. Check out the [nmfs_cols.R file](https://github.com/nmfs-ost/nmfspalette/blob/main/R/nmfs_cols.R) for more information.\n\n### NOAA Fisheries background \u0026 tint colors\n\nThese palettes contain 4 colors.\n\n#### background sky\n\n```{r}\n#| label: displ_background_sky\n#| fig-height: 2\ndisplay_nmfs_palette(\"background_sky\", 4)\n```\n\n#### background green\n\n```{r}\n#| label: displ_background_green\n#| fig-height: 2\ndisplay_nmfs_palette(\"background_green\", 4)\n```\n\n#### background gray\n\n```{r}\n#| label: displ_background_gray\n#| fig-height: 2\ndisplay_nmfs_palette(\"background_gray\", 4)\n```\n\n### NOAA core colors (Fisheries version)\n\nThis palette contains 11 colors.\n\n```{r}\n#| label: displ_core\n#| fig-height: 2\ndisplay_nmfs_palette(\"core\", 11)\n```\n\n### NOAA alert colors\n\nThese palettes contain 4 colors.\n\n#### alert red\n\n```{r}\n#| label: displ_alert_red\n#| fig-height: 2\ndisplay_nmfs_palette(\"alert_red\", 4)\n```\n\n#### alert orange\n\n```{r}\n#| label: displ_alert_orange\n#| fig-height: 2\ndisplay_nmfs_palette(\"alert_orange\", 4)\n```\n\n#### alert yellow\n\n```{r}\n#| label: displ_alert_yellow\n#| fig-height: 2\ndisplay_nmfs_palette(\"alert_yellow\", 4)\n```\n\n#### alert green\n\n```{r}\n#| label: displ_alert_green\n#| fig-height: 2\ndisplay_nmfs_palette(\"alert_green\", 4)\n```\n\n## Examples\n\nIn addition to `nmfs_palette` and `display_nmfs_palette` to get palettes, you can extract colors by name. Please see the [NOAA Fisheries Branding guide](https://drive.google.com/file/d/1lXHmfGWCj6pI_Dr3C-Dwcnf1pXOIOztp/view?usp=sharing) (NOAA internal only) for color names. Here, for most color names, underscores are used in place of spaces. Colors defined before 2023 have no spaces in the color names.\n\n```{r}\n#| label: nmfs_cols\nnmfs_cols(\"vivid_crustacean\")\nnmfs_cols(\"processblue\")\n```\n\nTo use the palettes with `{ggplot2}`, the `scale_color_nmfs()` and `scale_fill_nmfs()` functions are provided. If no argument is given to `scale_color_nmfs()`, a default (\"oceans\") is used:\n\n```{r}\n#| label: default_plot\n#| fig-height: 3\nlibrary(ggplot2)\np \u003c- ggplot(iris, aes(Sepal.Width, Sepal.Length, color = Species)) +\n  geom_point(size = 4) +\n  scale_color_nmfs()\np\n```\n\n`scale_fill_nmfs()` does not have a default and therefore requires a named argument, this is an example using the \"crustacean\" palette:\n\n```{r}\n#| label: scale_fill_example\n#| fig-height: 3\nggplot(faithfuld, aes(waiting, eruptions)) +\n  geom_raster(aes(fill = density)) +\n  scale_fill_nmfs(palette = \"crustacean\", discrete = FALSE, reverse = TRUE)\n```\n\n------------------------------------------------------------------------\n\n## Disclaimer\n\n“The United States Department of Commerce (DOC) GitHub project code is provided on an ‘as is’ basis and the user assumes responsibility for its use. DOC has relinquished control of the information and no longer has responsibility to protect the integrity, confidentiality, or availability of the information. Any claims against the Department of Commerce stemming from the use of its GitHub project will be governed by all applicable Federal law. Any reference to specific commercial products, processes, or services by service mark, trademark, manufacturer, or otherwise, does not constitute or imply their endorsement, recommendation or favoring by the Department of Commerce. The Department of Commerce seal and logo, or the seal and logo of a DOC bureau, shall not be used in any manner to imply endorsement of any commercial product or activity by DOC or the United States Government.”\n\n------------------------------------------------------------------------\n\n\u003ca href=\"https://www.fisheries.noaa.gov/\"\u003e\u003cimg src=\"man/figures/noaa-fisheries-rgb-2line-horizontal-small.png\" alt=\"NOAA Fisheries\" height=\"75\"/\u003e\n\n[U.S. Department of Commerce](https://www.commerce.gov/) \\| [National Oceanographic and Atmospheric Administration](https://www.noaa.gov) \\| [NOAA Fisheries](https://www.fisheries.noaa.gov/)\n","funding_links":[],"readme_doi_urls":[],"works":{},"citation_counts":{},"total_citations":0,"keywords_from_contributors":["fisheries","stock-assessment","fisheries-stock-assessment","stock-synthesis"],"project_url":"https://ost.ecosyste.ms/api/v1/projects/318362","html_url":"https://ost.ecosyste.ms/projects/318362"}