gawk 'BEGIN{OFS="\t"} $2 ~ /Term|Intr|Init/ \
{ print "apo1", "genscan", $2, start=($4<$5 ? $4 : $5),\
end=($5<$4 ? $4 : $5), $13, $3, $7, $1; }' apo1.masked.genscan_full |\
sed 's/\.[0-9][0-9]$//' > apo1.masked.genscan_full.gff