eechidna (version 1.3.0)

complete_color: Auto complete (or cut) a vector to a fixed length

Description

From https://github.com/chxy/cartogram/blob/master/R/dorling.R Not exported here, but needed for aec_carto_f

Usage

complete_color(cl, targetlen)

Arguments

cl

a vector of colors

targetlen

the target length

Value

a vector of completed cl with length n

Examples

Run this code
# NOT RUN {
complete_color('red',5)
complete_color(c('red','blue'),5)
complete_color(c('red','blue','green','yellow','pink','grey'),5)
# }

Run the code above in your browser using DataCamp Workspace