Entering edit mode
10.6 years ago
Phil S.
▴
700
Hi
is there any way to extract the locustag , join and complement information from a genbank via bash (one liner)? What gives me problems is the line break which may occur in the complement or join field of the genbank entry!
Thanks in advance.
Phil
ps. the lines I want to extract look like this:
/locus_tag="XXX_00002"
join(5485..5700,5784..6116,6230..6377,6434..6574,
6683..6819,7047..7314,7428..7938,8031..8307)
complement(join(34726..34766,34850..34866,34975..35287,
35392..35518,35604..35744,35831..35928,36051..36156))
Maybe, but it'd be a lot easier to use something like biopython or bioperl that can parse genbank files.
historically this is why perl, python exists in the first place - so that we don't have to process text in bash
Normally i solve stuff like this using boppython. The thing was that I wasn't working with my own laptop so i just needed to came up with a neat trick to solve it just the one time... Thanks for your suggestions anyways!