ggRadar: Draw a radar chart

Description Usage Arguments Value Examples

Description

Draw a radar chart

Usage

1
2
3
4
ggRadar(data = iris, xvars = NULL, yvar = NULL, groupvar = NULL,
  rescale = FALSE, legend.position = "bottom", radar = TRUE,
  polar = FALSE, mean = TRUE, nrow = FALSE, colour = "red",
  ylim = NULL, interactive = FALSE)

Arguments

data

A data.frame

xvars

A character vector of column names be assigned to x-axis variable If NULL, all continuous variables in the data.rame are used

yvar

A character string of column name be assigned to the y variable. Maybe preprocessed nrow or mean. Be used only in the preprocessed data.frame

groupvar

A character string of column name be used as a grouping variable

rescale

A logical value. If TRUE, all continuous variables in the data.frame are rescaled.

legend.position

Legend position. One of c("top","bottom","left","right","none")

radar

A logical value. If TRUE, a radar chart will be made

polar

A logical value. If TRUE, a polar chart will be made

mean

A logical value. If TRUE, a radar chart rescaled by mean will be made.

nrow

A logical value. If TRUE, a radar chart rescaled by nrow will be made.

colour

A name of color to be assigned as a color variable

ylim

A numeric vector of length 2, giving the y coordinates ranges.

interactive

A logical value. If TRUE, an interactive plot will be returned

Value

An interactive Pie and Donut plot

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
#ggRadar(data=iris,rescale=TRUE,groupvar="Species",interactive=TRUE,ylim=c(0,1))
#ggRadar(data1)
#ggRadar(data1,rescale=TRUE)+ylim(0,1)
#ggRadar(data1,groupvar="Class")
#ggRadar(data1,groupvar="Class",rescale=TRUE,interactive=TRUE)
#ggRadar(mtcars,groupvar="cyl",rescale=TRUE,interactive=TRUE)
#ggRadar(mtcars,rescale=TRUE,group="am")+ylim(0,1)
#ggRadar(mtcars,groupvar=c("cyl"))
#p<-ggRadar(mtcars,rescale=TRUE,group="am")
# ggsave("radarplot2.png",p)
#require(moonBook)
#ggRadar(data=acs,xvars=c("TC","TG","HDLC","LDLC"),groupvar="smoking")

cardiomoon/moonBook2 documentation built on May 13, 2019, 12:40 p.m.