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

Error in matrix(sc_obj[[pseudotime_ID]], dimnames = list(colnames(sc_obj) #4

Open
Jylab-Genetics opened this issue Oct 13, 2024 · 7 comments

Comments

@Jylab-Genetics
Copy link

WT_1_tree <- nodePseudotime(TRO, "Pseudotime", "celltypes_Abbreviation", 50)
Error in matrix(sc_obj[[pseudotime_ID]], dimnames = list(colnames(sc_obj), :
length of 'dimnames' [1] not equal to array extent

colnames([email protected])
[1] "sample" "nUMI"
[3] "nGene" "celltypes_Abbreviation1"
[5] "celltypes_Abbreviation2" "origin"
[7] "celltype_lineage" "celltypes_Abbreviation"
[9] "log10GenesPerUMI" "RNA_snn_res.1"
[11] "seurat_clusters" "integrated_snn_res.1"
[13] "subclass2.1" "subclass2"
[15] "subclass1.1" "subclass1"
[17] "celltype2" "celltype"
[19] "nCount_RNA" "nFeature_RNA"
[21] "Size_Factor" "num_genes_expressed"
[23] "Pseudotime" "State"
[25] "cell_type"

@Jylab-Genetics
Copy link
Author

path_tragedy <- bootstrap_pathfind(sequence_1 = as.matrix(WT_1_node_exp_mtx), sequence_2 = as.matrix(WT_2_node_exp_mtx)
, similarity_method= "spearman", threshold_method = "mean")
[1] 1 50
[1] 14 16
[1] 50 3
[1] 1 50
[1] 14 17
[1] 50 4
[1] 1 50
[1] 14 18
[1] 50 5
[1] 1 50
[1] 14 19
[1] 50 6
[1] 1 50
[1] 15 16
[1] 50 2
[1] 1 50
[1] 15 17
[1] 50 3
[1] 1 50
[1] 15 18
[1] 50 4
[1] 1 50
[1] 15 19
[1] 50 5
[1] 1 50
[1] 16 16
Error in dis_matrix[, -which(colnames(dis_matrix) %in% colnames(exp_mtx2))] :
incorrect number of dimensions

@No2Ross
Copy link
Owner

No2Ross commented Oct 14, 2024

Hi,

Could I get some more info about the analysis setup and also what the output of dis_mtx_calculator is?

Also is the first error you posted still an issue or is it now fixed?

Best wishes,
Ross

@Jylab-Genetics
Copy link
Author

Thank you very much for your prompt reply. The first issue has been resolved, but the second issue still exists

@Jylab-Genetics
Copy link
Author

path_tragedy <- bootstrap_pathfind(sequence_1 = as.matrix(WT_1_node_exp_mtx), sequence_2 = as.matrix(WT_2_node_exp_mtx)
, similarity_method= "spearman", threshold_method = "mean")
Error in if (end_index_choice == 1) { : the condition has length > 1
dim(WT_2_node_exp_mtx )
[1] 8261 50
dim(WT_1_node_exp_mtx )
[1] 8261 50
Snipaste_2024-10-17_11-19-51

@Jylab-Genetics
Copy link
Author

path_tragedy <- bootstrap_pathfind(sequence_1 = as.matrix(WT_1_node_exp_mtx), sequence_2 = as.matrix(WT_2_node_exp_mtx)
, similarity_method= "spearman", threshold_method = "mean")
Error in if (end_index_choice == 1) { : the condition has length > 1
dim(WT_2_node_exp_mtx )
[1] 8261 50
dim(WT_1_node_exp_mtx )
[1] 8261 50
Snipaste_2024-10-17_11-19-51

“We chose 50 interpolated points for our analysis and we wanted the window size to mean adjacent interpolated points had mixes of cells being considered." What is the basis for selecting this parameter, and how should I choose the appropriate value based on my data

@Jylab-Genetics
Copy link
Author

path_tragedy <- bootstrap_pathfind(sequence_1 = as.matrix(WT_1_node_exp_mtx), sequence_2 = as.matrix(WT_2_node_exp_mtx)
, similarity_method= "spearman", threshold_method = "mean")
Error in if (end_index_choice == 1) { : the condition has length > 1
dim(WT_2_node_exp_mtx )
[1] 8261 50
dim(WT_1_node_exp_mtx )
[1] 8261 50
Snipaste_2024-10-17_11-19-51

“We chose 50 interpolated points for our analysis and we wanted the window size to mean adjacent interpolated points had mixes of cells being considered." What is the basis for selecting this parameter, and how should I choose the appropriate value based on my data
When I choose different values, I report different errors
image

@No2Ross
Copy link
Owner

No2Ross commented Oct 19, 2024

We use the number of clusters in the dataset as a proxy for number of interpolated points, around 10-20 interpolated points per cluster in the dataset.

I've been fixing some bugs and some issues with how we get the expression values of the interpolated points. Will commit them just now. If you redownload the TrAGEDy file after this, hopefully this will fix the issue. If not, please let me know!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants