Closed Lijingtangbo closed 7 months ago
Hi,
Sorry for the bug and thanks for the report.
I think I have identified the cause. I have uploaded a new version, you can install it with pip install figeno==1.0.6
. Could you please try it and tell me if it fixes your bug ?
I changed the code a bit, it works for me now. I test 1.0.6, it works as well. Thanks!
Hi, When I draw ASE plot, the genes track is missing. I provide it with GTF.gz or TSV.gz. Both give me blank track.
What do you mean with ASE plot ? Figeno has an "ase" track type, which stands for allele-specific expression, but I did not mention it in the documentation since, although I am using it for my own research, I did not expect many users to be interested in it. If you want to show genes, you should use a "genes" track. If you use a custom reference, the genes file has to be provided in the "general" section of the config file.
Does this answer your question ? If not, could you please share the content of the config file that you are using ?
Sorry, I mean ASM plot. It would be great if including ASE track. I attached my config file. Thank you very much! config.json
Thanks. Could you also share your genes file ? I tried to download the RefSeq file for the ARS-UCD1.2 reference, and I was able to show the gene track (see below, I used your config file but removed the alignments and basemod_freq tracks, and changed the genes file).
I used the following genes file: ARS-UCD1.2.txt.gz
which I got by going to https://genome.ucsc.edu/cgi-bin/hgTables and selecting:
Does it work if you use this genes file ?
By the way, you do not need to provide a fasta file for the reference. You can just write "reference": "custom" in the config file.
Thank you! It is fine now with the gene-files you provide.
When I provide with a custom reference and genes file. I got error message for regions "chr" as "18" or "chr18" Traceback (most recent call last): File "/home/u/s176815/.local/bin/figeno", line 8, in
sys.exit(main())
File "/home/u/s176815/.local/lib/python3.9/site-packages/figeno/cli/cli.py", line 20, in main
args.func(args)
File "/home/u/s176815/.local/lib/python3.9/site-packages/figeno/cli/make.py", line 5, in main
figeno_make(config_file=args.config)
File "/home/u/s176815/.local/lib/python3.9/site-packages/figeno/figeno.py", line 402, in figeno_make
tp.draw()
File "/home/u/s176815/.local/lib/python3.9/site-packages/figeno/figeno.py", line 217, in draw
self.draw_horizontal(**self.output)
File "/home/u/s176815/.local/lib/python3.9/site-packages/figeno/figeno.py", line 262, in draw_horizontal
t.draw(regions=self.regions,box=box,hmargin=hmargin)
File "/home/u/s176815/.local/lib/python3.9/site-packages/figeno/track_alignments.py", line 75, in draw
self.compute_read_piles(regions,box)
File "/home/u/s176815/.local/lib/python3.9/site-packages/figeno/track_alignments.py", line 305, in compute_read_piles
self.region_group_piles = add_reads_to_piles(self.samfile,region_group_piles,regions,self.splitreads,margin=self.hgap_bp,
File "/home/u/s176815/.local/lib/python3.9/site-packages/figeno/bam.py", line 266, in add_reads_to_piles
for read in samfile.fetch(region.chr,region.start,region.end):
File "pysam/libcalignmentfile.pyx", line 1089, in pysam.libcalignmentfile.AlignmentFile.fetch
File "pysam/libchtslib.pyx", line 683, in pysam.libchtslib.HTSFile.parse_region
ValueError: invalid contig
18