Skip to content
master
Go to file
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
R
 
 
 
 
man
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

README.md

ggstar: star layer for ggplot2

CRAN_Status_Badge

To create the regular polygon layer for easily discernible shapes, we developed the package, it can be easily used if you know the ‘ggplot2’.

✍️ Author

Shuangbin Xu

School of Basic Medical Sciences, Southern Medical University

Installation

Get the released version from CRAN:

install.packages("ggstar")

Or the development version from github:

if (!requireNamespace("devtools", quietly=TRUE))
    install.packages("devtools")
devtools::install_github("xiangpin/ggstar")

🔰 Usage

Total starshapes:

library(ggplot2)
library(ggstar)
p <- ggplot(data=mtcars, 
            mapping=aes(x=wt, 
                        y=mpg, 
                        fill=cyl)) + 
     geom_star()
p

p2 <- ggplot(data=iris, 
             mapping=aes(x=Sepal.Length, 
                         y=Sepal.Width, 
                         fill=Species)) +
     geom_star()
p2

p3 <- ggplot(data=iris,
             mapping=aes(x=Sepal.Length,
                         y=Sepal.Width,
                         fill=Species,
                         starshape=Species)) +
      geom_star() + scale_starshape_manual(values=c(1, 2, 9))
p3

📖 Vignette

For more details, please refer to the online vignette

If you have installed it, you can also view the vignette on local.

browseVignettes("ggstar")

💖 Contributing

We welcome any contributions! By participating in this project you agree to abide by the terms outlined in the Contributor Code of Conduct.

About

star layer for ggplot2

Resources

Releases

No releases published

Packages

No packages published
You can’t perform that action at this time.