bowmanr / scDNA

R package to analyze single cell DNA sequencing data.
https://bowmanr.github.io/scDNA/
MIT License
8 stars 5 forks source link

clonograph adjustment + trajectory error #6

Closed antheatravas closed 4 months ago

antheatravas commented 6 months ago

How can I get more mutations in the clonal architecture portion of the clonograph? The default is set to 3 but I'd like to increase it.

Also I get this issue with the trajectory analysis... sce_subset<-trajectory_analysis(sce_subset) [1] "Building MDP" [1] 27 [1] "Adding Weighted Edges" Error in UseMethod("rename") : no applicable method for 'rename' applied to an object of class "NULL"

Appreciate any support-thanks!

namwob44 commented 6 months ago

Hello,

I can help with a few different things here. Let's start with the easier changes:

  1. This error is because the trajectory_analysis function assumes we are assessing allele dropout by default. Likely if you look into your sce_subset variable with View(sce_subset), you will see in the metadata tab there is no list called FalsePositive. This is needed for the trajectory analysis.
  2. Due to it taking a longer time to run, and not being needed for a majority of analysis we have turned off allele dropout in an earlier function by default.
  3. To fix this, please use the skip_ploidy=FALSE variable in the compute_clone_statistics function earlier in the code. So it should look similar to this: sce<-compute_clone_statistics(sce,skip_ploidy=FALSE) Afterwards you can run select_clones like normal and the trajectory_analysis like normal.

The number of mutations is determined by filtering variant_of_interest differently to accept more mutations, and it is based on the cutoff values of the tapestri_h5_to_sce function. This is problem dependent and without knowing more we can't adequately help point in the right direction other than to decrease the values for each filter. Alternatively, in our example vignette we use genes_of_interest to prune our variant list down. Please feel free to ask more specific questions about the different filters and we can help you out.