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

PeakSeuratFromTransfer error #33

Open
Nbalb opened this issue Jun 28, 2021 · 1 comment
Open

PeakSeuratFromTransfer error #33

Nbalb opened this issue Jun 28, 2021 · 1 comment

Comments

@Nbalb
Copy link

Nbalb commented Jun 28, 2021

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

@Nbalb Nbalb changed the title Possible bugs PeakSeuratFromTransfer error Jun 28, 2021
@rj-patrick
Copy link
Contributor

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

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