Entering edit mode
6.9 years ago
AAK85
•
0
Hi I am new to bioinformatics. I have a command that I don't know what the output file will be? Can anyone help me understand the command? I don't know what the system does in the command line.
awk -F "\t" '{printf $0 "\t"} {system("samtools view -F 0x100 chr1.bam " $6 ":" $7"-"$8 "|" "wc -l")}' chr1RPTS > final.txt
the chr1RPTS is a file in repeatmasker format.
Output file will be called
final.txt
, if the command works as written (and as advertised). Are you getting anything in thefinal.txt
when you run this command?Hi Yes. In my ch1RPTS file I have 17 columns and after this command my final.txt file has 18th column. I don't understand what the 18th column represents? Generally, in the repeatmasker file there are 17 columns, executing the {system("samtools view -F 0x100 chr.bam .......")} command adds one more column to my output file and I can't figure it out what it is representing? my complete command is this: awk -F "\t" '{printf $0 "\t"} {system("samtools view -F 0x100 chr1.bam " $6 ":" $7"-"$8 "|" "wc -l")}' chr1RPTS > final.txt