Skip to content

Commit

Permalink
Merge branch 'master' into devel
Browse files Browse the repository at this point in the history
  • Loading branch information
csangara committed Sep 7, 2023
2 parents 68ce42b + 311ef43 commit 49bc4ee
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Package: nichenetr
Type: Package
Title: NicheNet: Modeling Intercellular Communication by Linking Ligands to Target Genes
Version: 2.0.1
Version: 2.0.2
Authors@R: c(person("Robin", "Browaeys", role = c("aut")),
person("Chananchida", "Sang-aram", role = c("aut", "cre"), email = "[email protected]"))
Description: This package allows you the investigate intercellular communication from a computational perspective. More specifically, it allows to investigate how interacting cells influence each other's gene expression. Functionalities of this package (e.g. including predicting extracellular upstream regulators and their affected target genes) build upon a probabilistic model of ligand-target links that was inferred by data-integration.
Expand Down
9 changes: 6 additions & 3 deletions R/prioritization.R
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,10 @@ calculate_de = function(seurat_obj, celltype_colname,
...){

# Default settings to return all genes with their p-val and LFC
FindAllMarkers_args = list(object = seurat_obj, assay = assay_oi,
features = NULL, min.pct = 0, logfc.threshold = 0, return.thresh = 1)
FindAllMarkers_args = list(assay = assay_oi,
features = NULL, min.pct = 0,
logfc.threshold = 0,
return.thresh = 1)

# Replace this with user arguments
FindAllMarkers_args[names(list(...))] = list(...)
Expand All @@ -63,7 +65,8 @@ calculate_de = function(seurat_obj, celltype_colname,
# Set celltype as identity class
Idents(seurat_obj) <- seurat_obj[[celltype_colname, drop=TRUE]]

DE_table = do.call(FindAllMarkers, FindAllMarkers_args) %>%
FindAllMarkers_args$object <- seurat_obj
DE_table <- do.call(FindAllMarkers, FindAllMarkers_args) %>%
rename(cluster_id = cluster)

SeuratV4 = c("avg_log2FC") %in% colnames(DE_table)
Expand Down

0 comments on commit 49bc4ee

Please sign in to comment.