GetBrandColors: Identify colors to be used with brands in the data

View source: R/usetemplate.R

GetBrandColorsR Documentation

Identify colors to be used with brands in the data

Description

This function should not called directly, but instead be called via GetVectorOfColors instead. It remains an exported function because it is used in older versions of the Standard R pages

Usage

GetBrandColors(
  template,
  input.data = NULL,
  filter = NULL,
  chart.type = "",
  scatter.colors.column = 4,
  multi.color.series = FALSE,
  brand.names = NULL
)

Arguments

template

A list specifying color palettes and other visualization options.

input.data

Input data for the visualization. The is usually a vector or table. It should be normalized from flipChart::PrepareData.

filter

Optional filter which can be used with the input data. The label of the filter is used when appropriate.

chart.type

Type of chart to plot

scatter.colors.column

For scatterplot data, the column of data which is used to determine the colors of each point.

multi.color.series

For bar and column charts, a logical indicating how colors are used. By default, this value is set to FALSE, in which case the number of colors returned is equal to the number of data series (or columns) in data. When multi.color.series == TRUE, multiple colors are assigned to the categories within a single data series, so the number of colors returned is equal to NROW(data).

brand.names

If a vector of names is provided then only template is used.

Value

An integer specifying the number of colors used by the chart.


NumbersInternational/flipChartBasics documentation built on Feb. 26, 2024, 5:34 a.m.