read_STAR | R Documentation |
Read STAR Log.final.out files and optionally reshape into wide format.
read_STAR(path = ".", pattern, reshape = FALSE)
path |
the path to STAR log files, the default corresponds to the working directory. |
pattern |
regular expression for file name matching, default .final.out |
reshape |
reshape percent mapping into wide format with samples in rows |
A tibble
Reading output files requires a unique sample identifier in either the file name or parent directory
Chris Stubben
## Not run:
x <- read_STAR( pattern=".star.out$")
reads <- c("Uniquely mapped", "Mapped to multiple loci",
"Mapped to too many loci", "Unmapped reads")
y <- filter(x, stat %in% reads) %>% mutate( stat= factor(stat, levels=reads ))
hchart(y, "bar", x=sample , y=value, group=stat ) %>%
hc_plotOptions(bar = list(stacking = "normal")) %>%
hc_colors( c('#437bb1', '#7cb5ec', '#f7a35c', '#b1084c') ) %>%
hc_yAxis(reversedStacks = FALSE)
read_STAR( pattern=".star.out$", reshape=TRUE)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.