BPCells icon indicating copy to clipboard operation
BPCells copied to clipboard

Issue with BPCells::write_matrix_dir: Column Name Error

Open lisch7 opened this issue 2 years ago • 1 comments

Hello,

I am encountering an issue with the BPCells::write_matrix_dir function and am seeking some assistance.

Background: I have processed my dataset using Scanpy and am now looking to transition this data into Seurat for further analysis. During this transition, I encountered problems with the BPCells::write_matrix_dir function. My code is as follows:

data <- BPCells::open_matrix_anndata_hdf5(
  path = "02.preprocess/seu_shiftlog_pearson_hvg2000_scale_pca_leiden_res1.0_umap_anno_scvi_by_sample_anno_1113_filter.h5ad"
)
BPCells::write_matrix_dir(mat = data, dir = "02.preprocess/sce_BP")

Problem Description: When attempting to use this function, I encountered an error stating that the matrix has some column names, but they are not equal to the number of columns. The error message is:

Warning: Matrix compression performs poorly with non-integers.
• Consider calling convert_matrix_type if a compressed integer matrix is intended.
This message is displayed once every 8 hours.
Error: Matrix has some colnames, but not equal to col number

Request for Assistance:

  • How should I go about debugging the mismatch in column names?

Any help or suggestions would be greatly appreciated.

Thank you!

lisch7 avatar Nov 13 '23 09:11 lisch7

Hi, I think this was due to a bug in BPCells which should be fixed now.

Could you try re-installing with the updated BPCells version and see if that fixes your issue?

bnprks avatar Nov 15 '23 05:11 bnprks

Closing due to inactivity

immanuelazn avatar Oct 25 '24 21:10 immanuelazn