Skip to content

Commit

Permalink
Fix call to tidyverse functions.
Browse files Browse the repository at this point in the history
  • Loading branch information
ddiez committed Feb 7, 2024
1 parent 4a70392 commit 7a29eb1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions R/plot.R
Original file line number Diff line number Diff line change
Expand Up @@ -494,9 +494,9 @@ plot_gene_modules.Seurat <- function(x, gene_modules, reduction=NULL, assay=NULL
else
modules <- unique(gene_modules$module)
p <- lapply(modules, function(module) {
genes <- gene_modules |> filter(.data[["module"]] == !!module) |> pull(gene)
genes <- gene_modules |> filter(.data[["module"]] == !!module) |> pull("gene")
means <- colMeans(exprs[genes, ])
d <- cbind(coord, data.frame(score=means, module=module)) |> arrange(abs(score))
d <- cbind(coord, data.frame(score=means, module=module)) |> arrange(abs(.data[["score"]]))
ggplot(d, aes(.data[[coord.cols[1]]], .data[[coord.cols[2]]], color=.data[["score"]])) +
geom_point(size=size) +
scale_color_gradient2(low="blue", mid="lightgrey", high="red") +
Expand Down

0 comments on commit 7a29eb1

Please sign in to comment.