Learn R Programming

ggiraphExtra (version 0.1.0)

ggCLE: Draw a cleveland dot plot

Description

Draw a cleveland dot plot

Usage

ggCLE(data, mapping, reorderByX = TRUE, no = NULL, start = 0.99,
  interactive = FALSE, decreasing = TRUE, ...)

Arguments

data

a data.frame

mapping

Set of aesthetic mappings created by aes or aes_.

reorderByX

If true, the data is reordered by x variable

no

Number of data be drawn in plot

start

start point of x axis as ratio to minimum x variable

interactive

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

decreasing

Should the sort order be increasing or decreasing?

...

other arguments passed on to geom_point_interactive

Examples

Run this code
# NOT RUN {
require(ggplot2)
require(ggiraph)
mtcars$name=rownames(mtcars)
ggCLE(data=mtcars,aes(x=mpg,y=name))
ggCLE(data=mtcars,aes(x=mpg,y=name,color=am,facet=am),interactive=TRUE)
if(requireNamespace("gcookbook",quietly=TRUE)){
   require(gcookbook)
   ggCLE(data=tophitters2001,aes(x=avg,y=name),no=20,interactive=TRUE)
   ggCLE(data=tophitters2001,aes(x=avg,y=name,color=lg,facet=lg),no=20)
}
# }

Run the code above in your browser using DataLab