#usage: gawk -f sample.awk [tab-separated column summary data filename] > [output file name] #setting the Output Field Separator and Field Separator to a tab ("\t") BEGIN{OFS = "\t"; FS = "\t";} #suppose you want the run number ($1), hall a beam current ($80), and hall a beam energy ($119) {print $1,$80,$119;}