Skip to content

Commit

Permalink
Update R/Seurat.R
Browse files Browse the repository at this point in the history
Co-authored-by: Luke Zappia <[email protected]>
  • Loading branch information
rcannood and lazappi authored Nov 12, 2024
1 parent 7b3b64f commit 9faaa7f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions R/Seurat.R
Original file line number Diff line number Diff line change
Expand Up @@ -259,11 +259,11 @@ to_Seurat <- function(
}

if (!.to_seurat_is_atomic_character(layer_name)) {
stop("layer_name must be the name of one of the layers or NULL")
stop("layer_name must be character vector of length 1")
}

if (!layer_name %in% names(adata$layers)) {
stop("layer_name must be the name of one of the layers or NULL")
stop("layer_name '", layer_name, "' is not an item in adata$layers")
}

return(Matrix::t(adata$layers[[layer_name]]))
Expand Down

0 comments on commit 9faaa7f

Please sign in to comment.