Entering edit mode
5.9 years ago
BioBaby
▴
20
I am trying to add double quotes around transcript_id column in gtf file by following command but did not work
awk '{ if ($0 ~ "transcript_id") print $0; else print $0" transcript_id \"\";"; }' inputfile > outfile
and input file looks like this:
SL3.0ch00 StringTie transcript 548415 552574 1000 + . gene_id STRG.6; transcript_id STRG.6.1; cov 2.472455; FPKM 1.523706; TPM 1.143045;
SL3.0ch00 StringTie transcript 570552 575378 1000 - . gene_id STRG.11; transcript_id STRG.11.2; cov 9.309154; FPKM 5.736975; TPM 4.303733;
please kindly help me out.
Hello BioBaby ,
Please use the formatting bar (especially the
code
option) to present your post better. I've done it for you this time.Thank you!