-
Notifications
You must be signed in to change notification settings - Fork 20
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
[BUG] vis_grid_clus cannot handle logical variables #80
Comments
lcolladotor
added a commit
that referenced
this issue
Jul 12, 2024
Thanks for the report @lahuuki! Here's how things behave now in Best, suppressPackageStartupMessages(library("spatialLIBD"))
spe <- fetch_data("spatialDLPFC_Visium_example_subset")
#> 2024-07-12 10:58:34.14279 loading file /Users/leocollado/Library/Caches/org.R-project.R/R/BiocFileCache/6f563a40ecf7_spatialDLPFC_spe_subset_example.rds%3Fdl%3D1 spe$BayesSpace_harmony_02_lgl <- spe$BayesSpace_harmony_02 ==1
set.seed(20240712)
spe$BayesSpace_harmony_02_lgl[sample(seq_len(ncol(spe)), 2000)] <- NA
vis_grid_clus(
spe = spe,
clustervar = "BayesSpace_harmony_02_lgl",
return_plots = TRUE,
sort_clust = FALSE,
point_size = 2
)
#> $Br6432_ant
vis_grid_clus(
spe = spe,
clustervar = "BayesSpace_harmony_02_lgl",
return_plots = TRUE,
sort_clust = TRUE,
point_size = 2
)
#> $Br6432_ant
vis_clus(
sampleid = "Br6432_ant",
spe = spe,
clustervar = "BayesSpace_harmony_02_lgl",
point_size = 2
) packageVersion("spatialLIBD")
#> [1] '1.17.6' Created on 2024-07-12 with reprex v2.1.0 |
lcolladotor
added a commit
that referenced
this issue
Jul 12, 2024
Co-authored-by: Louise Huuki <lahuuki@gmail.com>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I noticed some strange behavior in
vis_grid_clus()
when trying to plot logical variables such asin_tissue
, the same variables plot as expected invis_clus()
. Converting the lgl to factor does not fix this.Example in
spatialDLPFC_Visium_example_subset
Doesn't work with logical data
Note.
spatialLIBD
is a recent github versionAdditional Context
I found this bug plotting data from the LFF_spatial_ERC project: more examples of this issue
Is the package installed via bioconda? No
The text was updated successfully, but these errors were encountered: