-
Notifications
You must be signed in to change notification settings - Fork 88
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 with TSS enrichment #485
Comments
Please include the full code you're running and the output of |
Full code:
session info:
|
What is the gene annotation you're using here? I'd suggest just using the Ensembl annotation for hg38 as shown in the vignettes |
Annotation is from gencode release 32. In the past I have used EnsDb.Hsapiens.v86, which worked well. However, I am comparing my data to snRNA data, and need to make sure I am using the same annotations as the reference genome used for mapping snRNA reads. I looked at |
This works for me: library(Signac)
library(rtracklayer)
pbmc <- readRDS(...) # hg38-mapped object
hg38 <- import("~/gencode.v32.annotation.gtf.gz")
genome(hg38) <- "hg38"
seqlevelsStyle(hg38) <- "UCSC"
hg38$gene_biotype <- hg38$gene_type
Annotation(pbmc) <- hg38
pbmc <- TSSEnrichment(pbmc) You need to ensure there's a column named "gene_biotype" in the annotation. I will add a check for this in TSSEnrichment or the annotation assignment function, so we can throw a more informative error message. |
Interesting, I dont know what went wrong yesterday, but it seems to be working fine now. About to run my last scripts for tss enrichment. Thank you @timoast |
maybe all I needed to do was specify the genome, seqlevelsStyle, and add gene_biotype. The other stuff I did to the genome was perhaps the problem? not sure |
Not sure, I didn't try running all those steps. |
Using the TSSEnrichment function, I'm getting this error: Error in strand[[1]]: subscript out of bounds I have looked at issues #377 and #376, and it seemed like I didn't have a gene_biotype column in my granges object, so I added it as per above gtf$gene_biotype <- gtf$gene_type but I'm still getting the same error. I used the UCSC fasta and gtf files to build the atac genome reference for running CellRanger, and I'm using the same gtf file to add gene information to my Signac object. |
@strawberry789 I would love to try and help if I can. what is your code for constructing the reference, and can I download the gtf from somewhere online? |
@danielcgingerich Thanks for your reply. I used 10X Genomics' mkref function to construct the reference: cellranger-atac mkref dm6_UCSC_atac --config dm6_UCSC_atac.config where dm6_UCSC_atac.config contains:
The gtf was downloaded from: http://hgdownload.soe.ucsc.edu/goldenPath/dm6/bigZips/genes/dm6.ensGene.gtf.gz |
This should be fixed now on the develop branch (improved error message) |
Here is the error:
I looked at issue #376 and tried to make sure my object was formatted correctly and removed patch edition chromosomes. Here is how I made the annotations:
The text was updated successfully, but these errors were encountered: