Introduction

The color palette workflow created for MicrobiomeR are based on the get_color_palette(pal_func = ...) with a palette function that returns grDevices::colorRampPalette(...) (called), grDevices::colorRampPalette (not called), or a color palette function that returns a character vector. Several palette functions come built with MicrobiomeR and are used in the plotting functions.

Combining Color Palettes

Here is a useful functionality. Combining color palettes can help with situations where you need something more custom. This can be especially helpful if you are using more than 20 colors. The combination_palette function can take a dynamic number of arguments, must be named and the value must be a list. The list members can contain members with the following names:

You can use any name for your arguments, but the values must be a named list. palette: This is a palette function that returns a vector of colors. args: This is another named list used for the palette function parameters. range: This is a range (1:10) used to subset the color palette vector. rev: This is a logical (TRUE/FALSE)used to reverse the color palette.