VCCRI / Sierra

Discover differential transcript usage from polyA-captured single cell RNA-seq data
GNU General Public License v3.0
49 stars 17 forks source link

PeakSeuratFromTransfer error #33

Open Nbalb opened 3 years ago

Nbalb commented 3 years ago

Hi,

I am trying out the package Sierra and I'd like to thank you for the really useful functions it has. Nonetheless, I think I found some a problem that I would like to bring to your attention.

  1. I had troubles running the function PeakSeuratFromTransfer, which returned the error Error in if (gene.cov != "") { : missing value where TRUE/FALSE needed I ran the code as: peaks_seurat <- PeakSeuratFromTransfer(peak.data = peak.counts, genes.seurat = seurat.object, annot.info = peak.annotations, min.cells = 1, min.peaks = 1, filter.gene.mismatch = T)
    I think the issue was with the function AnnotatePeaksFromGTF which introduced some NAs (I am using BSgenome.Rnorvegicus.UCSC.rn6 as the reference genome) in the names of the annotated peaks, since i was able to solve the issue by filtering out NAs when reading in the result from AnnotatePeaksFromGTF. This is what I did and I think a check on NAs would be helpful. peak_annotations <- read.table("data/merged_annotated_peaks.txt", header = T, sep = "\t", row.names = 1, stringsAsFactors = FALSE) %>% filter(!is.na(gene_id))

Hope this is helpful, if this was just a mistake on my side please close and delete the issue.

Best, Nicola

rj-patrick commented 3 years ago

Hi @Nbalb,

Thanks for letting us know. We have primarily tested Sierra on model organism references downloaded from 10x and there have been instances of other references causing problems. We will look into this case, but your solution is probably the best for now.

Cheers, Ralph