Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions .github/workflows/R-CMD-check.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,11 @@ jobs:
R_KEEP_PKG_SOURCE: yes

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4

- uses: r-lib/actions/setup-pandoc@v1
- uses: r-lib/actions/setup-pandoc@v2

- uses: r-lib/actions/setup-r@v1
- uses: r-lib/actions/setup-r@v2
with:
r-version: ${{ matrix.config.r }}
http-user-agent: ${{ matrix.config.http-user-agent }}
Expand All @@ -44,11 +44,11 @@ jobs:
sudo apt-get install --yes libcurl4-openssl-dev
Rscript -e "install.packages('curl', repos='https://cloud.r-project.org')"

- uses: r-lib/actions/setup-r-dependencies@v1
- uses: r-lib/actions/setup-r-dependencies@v2
with:
extra-packages: rcmdcheck

- uses: r-lib/actions/check-r-package@v1
- uses: r-lib/actions/check-r-package@v2

- name: Show testthat output
if: always()
Expand Down
7 changes: 4 additions & 3 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Package: scruff
Title: Single Cell RNA-Seq UMI Filtering Facilitator (scruff)
Version: 1.21.1
Version: 1.27.1
Date: 2024-03-27
Authors@R: c(person("Zhe", "Wang",
email = "zhe@bu.edu",
Expand All @@ -20,7 +20,7 @@ Depends: R (>= 4.0)
License: MIT + file LICENSE
Encoding: UTF-8
LazyData: TRUE
RoxygenNote: 7.3.1
RoxygenNote: 7.3.3
VignetteBuilder: knitr
Imports: data.table,
GenomicAlignments,
Expand All @@ -47,7 +47,8 @@ Imports: data.table,
SingleCellExperiment,
SummarizedExperiment,
Rsubread,
parallelly
parallelly,
patchwork
Suggests:
BiocStyle,
knitr,
Expand Down
4 changes: 2 additions & 2 deletions R/rview.R
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@ rview <- function(bamGA,
S4Vectors::mcols(readsGr)$umi <- data.table::last(
data.table::tstrsplit(names(readsGr), ":"))

g <- ggplot2::ggplot(readsGr) +
ggbio::geom_arrow(ggplot2::aes(color = umi)) +
g <- ggplot2::ggplot() +
ggbio::geom_arrow(data = readsGr, ggplot2::aes(color = umi)) +
.themePublication() +
ggplot2::theme(axis.title.y = ggplot2::element_blank())

Expand Down
8 changes: 5 additions & 3 deletions R/scruffFunctions.R
Original file line number Diff line number Diff line change
Expand Up @@ -386,9 +386,11 @@
size = ggplot2::rel(1),
hjust = 0.5),
text = ggplot2::element_text(),
panel.background = ggplot2::element_rect(color = NA),
plot.background = ggplot2::element_rect(color = NA),
panel.border = ggplot2::element_rect(color = NA),
panel.background = ggplot2::element_rect(fill = NA,
color = NA),
plot.background = ggplot2::element_rect(fill = NA,
color = NA),
panel.border = ggplot2::element_blank(),
axis.title = ggplot2::element_text(
face = "bold",
size = ggplot2::rel(1)),
Expand Down
14 changes: 11 additions & 3 deletions vignettes/scruff.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ suppressPackageStartupMessages(library(BiocStyle))
# For generation of these files, please refer to the Stepwise Tutorial.

library(scruff)
library(patchwork)

# Get the paths to example FASTQ, FASTA, and GTF files.
# Please note that because the following files are included in
Expand Down Expand Up @@ -220,9 +221,16 @@ data(bamExample, package = "scruff")
start <- 1094
end <- 2675

g1 <- rview(bamExample, chr = "MT", start = start, end = end)
g2 <- gview(gtf, chr = "MT", start = start, end = end)
g <- ggbio::tracks(g1, g2, heights = c(4, 1), xlab = "chr MT")
g1 <- rview(bamExample, chr = "MT", start = start, end = end) +
ggplot2::scale_x_continuous(limits = c(start, end))
g2 <- gview(gtf, chr = "MT", start = start, end = end) +
ggplot2::scale_x_continuous(limits = c(start, end))
g <- (g1 + ggplot2::theme(axis.title.x = ggplot2::element_blank(),
axis.text.x = ggplot2::element_blank(),
plot.margin = ggplot2::margin(t = 0, b = 0))) /
(g2 + ggplot2::theme(plot.margin = ggplot2::margin(t = 0, b = 0))) /
patchwork::plot_layout(ncol = 1,
heights = c(4, 1))
g
```

Expand Down
Loading