Question: Gviz: UcscTrack() getting error when there is no genes in the region
0
gravatar for shuoguo
3.1 years ago by
shuoguo10
shuoguo10 wrote:

I have this function and sometimes it gives me error:

refGenes <- UcscTrack(track="RefSeq Genes",
                        table="refGene",
                        trackType="GeneRegionTrack",
                        genome=genome_build,
                        chromosome=chrom,
                        from=pos0, to=pos1,
                        rstart="exonStarts", rends="exonEnds",
                        gene="name",
                        symbol="name2",
                        transcript="name",
                        strand="strand",
                        name="RefSeq Genes",
                        feature="name2",
                        showId=T,
                        fill = "green")

Error in make.unique(rep(if (!missing(feature) && !is.null(feature)) as.character(feature) else covars[["feature"]],  :
  'names' must be a character vector

I wonder if it is due to the fact that there was no genes in the region. e.g.

​[1] "chr16"    "33379409" "33476447"
 

Any way to by passing this?

 

Thanks a lot,

 

Shuoguo

 

ucsctrack givz • 449 views
ADD COMMENTlink modified 3.1 years ago • written 3.1 years ago by shuoguo10
Answer: Gviz: UcscTrack() getting error when there is no genes in the region
1
gravatar for shuoguo
3.1 years ago by
shuoguo10
shuoguo10 wrote:

Just in case in the future people run into the same issue. 

I have temporarily "fixed" this issue by removing the two lines in the command:

gene="name",
feature="name2",

please let me know if you have other ways.

Thanks,

ADD COMMENTlink modified 3.1 years ago • written 3.1 years ago by shuoguo10
Please log in to add an answer.

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 16.09
Traffic: 232 users visited in the last hour