val2col: val2col

Description Usage Arguments Examples

Description

This function converts a vector of values("yourdata") to a vector of color levels. One must define the number of colors. The limits of the color scale("zlim") or the break points for the color changes("breaks") can also be defined. when breaks and zlim are defined, breaks overrides zlim. Source: http://menugget.blogspot.nl/2011/09/converting-values-to-color-levels.html

Usage

1
2
val2col(yourdata, zlim, col = rev(heat.colors(max(12, 3 *
  length(unique(yourdata))))), breaks, rename = F)

Arguments

yourdata

The data, to what the colors will be scaled to.

zlim

Limits.

col

Color of the plot.

breaks

Number of bins.

rename

The returned color vector will be named with its previous values

Examples

1
val2col (yourdata =  , zlim =  , col = rev(heat.colors(12)), breaks =  )

vertesy/MarkdownReports.v2.9.5 documentation built on May 22, 2019, 4 p.m.