val4symb {pgirmess}R Documentation

Centers and provides absolute values and colors for negative and positive values

Description

Centers a variable and provides absolute values and different colors for negative and positive values

Usage

val4symb(x, col = c("blue", "red"), ...)

Arguments

x a numeric vector
col a character vector of 2 values, default=c("blue","red"), blue for <0, red for >=0
... other parameters eg to pass to scale()

Value

A list with

size the absolute values
col a vector of colors

Author(s)

Patrick Giraudoux, pgiraudo@univ-fcomte.fr

See Also

symbols

Examples

x<-rnorm(30)
y<-rnorm(30)

z<-val4symb(rnorm(30))
symbols(x,y,circle=z$size,inches=0.2,bg=z$col)

z<-val4symb(rnorm(30),col=c("green","violet"))
symbols(x,y,circle=z$size,inches=0.2,bg=z$col)

[Package pgirmess version 1.2.7 Index]