Open jcmckerral opened 3 years ago
Traceback (most recent call last):
File "/home/liu/miniconda3/envs/component/bin/PhiSpy.py", line 10, in
I have also encountered this issue, but I have hundreds of gbk files to process, so is there any way to batch shorten the IDs in the files
I have also encountered this issue, but I have hundreds of gbk files to process, so is there any way to batch shorten the IDs in the files
I met the same issue. Any clues on this?
Can you point me to a file where this issue occurs so that I can fix it?
Hi, I also had this issue. I initially tried to add the whitespace manually but that didn't work. My genbank files were annotated in PROKKA. Re-annotating using the --compliant flag for PROKKA fixed the issue for me as it parses the locus line in a different way.
@linsalrob @qianxin-kxy @jcmckerral thank you and the easy way would be to do this before running:
# this will remove all the spaces with the pipes
for i in *.fasta; do sed -i -e "s/ /|/g" ${i}; done
# cut the pipe at the place you want
for i in *.fasta; do cut -f 1 -d "|" ${i}; done
# all headers shorted.
Thank you
Gaurav
@ShanlinKe @TSZUoE see my response in this thread above.
if you have the C++ code, pointer declaration snippet, paste here, will do the convertible for the same
# this will remove all the spaces with the pipes
for i in *.fasta; do sed -i -e "s/ /|/g" ${i}; done
# cut the pipe at the place you want
for i in *.fasta; do cut -f 1 -d "|" ${i}; done
# all headers shorted.
Thank you Gaurav
There is a small issue where one of the biopython functions has a character length limit on sequence IDs, a more informative error message might be useful. A fasta ID
results in a genbank file which will give a PhiSpy traceback/error
Changing the ID to
resolves the problem.