translate_color: Translate color

Description Usage Arguments Details Value Author(s) Examples

View source: R/translate_color.R

Description

Translate some colours from Spanish to English

Usage

1

Arguments

color

[character] Colour to be translated

Details

Only a few fundamental colours are implemented in the function: black (negro/a), grey (gris), white (blanco/a), red (rojo/a), pink (rosa), green (verde), blue (azul), purple (morado/a), brown (marrón), orange (naranja), yellow (amarillo/a).

Value

Character string with the color in English (see details).

If provided color is not implemented, it raises an error.

Author(s)

Víctor Moreno-González <vmorg@unileon.es

Examples

1
2
3
translate_color("rojo")
translate_color("Marrón")   # It deals with uppercases
translate_color("amarilla") # It deals with female and male names

vmoreg00/projects documentation built on April 14, 2020, 4:02 p.m.