Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fixed passing source organism in get_homologene_dict: fixes #170 #174

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
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
4 changes: 2 additions & 2 deletions DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,6 @@ Suggests:
muscData,
broom
biocViews: scater, scran, SingleCellExperiment, ComplexHeatmap, muscData, ExperimentHub
Remotes: sqjin/CellChat, saezlab/OmnipathR, saezlab/decoupleR, LTLA/basilisk.utils, LTLA/basilisk
RoxygenNote: 7.2.3
Remotes: sqjin/CellChat, saezlab/OmnipathR, saezlab/decoupleR, Bioconductor/basilisk.utils, Bioconductor/basilisk
RoxygenNote: 7.3.0
Config/testthat/edition: 3
11 changes: 9 additions & 2 deletions R/liana_ortho.R
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,6 @@ generate_homologs <- function(op_resource,
symbols_dict <- get_homologene_dict(entities = entities,
target_organism = target_organism)


# Remove any missing antities
if(is.null(.missing_fun)){

Expand Down Expand Up @@ -254,7 +253,15 @@ recode.character2 <- function(.x,
.default = NULL,
.missing = NULL,
.missing_fun) {

.x <- as.character(.x)

if (length(.x) == 0) {

return(.x)

}

values <- rlang::list2(...)
if (!all(rlang::have_name(values))) {
bad <- which(!rlang::have_name(values)) + 1
Expand Down Expand Up @@ -399,7 +406,7 @@ get_homologene_dict <- function(entities,
id_type = "genesymbol"){

# Load homology geneset
hg_gs <- homologene_download(target = !!target_organism,
hg_gs <- homologene_download(target = target_organism,
source = 9606L, # always human
id_type = !!id_type) %>%
select(-hgroup) %>%
Expand Down
Loading