Dear folks
I have 300 files which one of them are looking like:
I am looking for desire output:
I used this below command to run all of the 300 file at the same time
But I do not know why all of the *.gen file do not include any information in the *.gen files. Could anyone give me a guide for this problem?
I have 300 files which one of them are looking like:
Code:
1.SNP
0
0
1
0
Code:
1.SNP 0 0 1 0
Code:
for file in *.SNP; do awk '{printf( "%s ", $1 );} END {printf("\n");}' $file > "$(basename "$file" .SNP).gen"; done