I have some files containing the following data
# RESIDUE AA STRUCTURE BP1 BP2 ACC N-H-->O O-->H-N N-H-->O O-->H-N TCO KAPPA ALPHA PHI PSI X-CA Y-CA Z-CA
1 196 A M 0 0 230 0, 0.0 2,-0.2 0, 0.0 0, 0.0 0.000 360.0 360.0 360.0 76.4 21.7 -6.8 11.3
2 197 A D + 0 0 175 1,-0.1 2,-0.1 0, 0.0 0, 0.0 -0.193 360.0 151.5 -46.2 99.1 23.2 -9.3 13.8
3 198 A E - 0 0 170 -2,-0.2 -1,-0.1 0, 0.0 0, 0.0 -0.622 29.3-158.9-134.6 66.9 26.9 -9.0 13.0
4 199 A K - 0 0 161 1,-0.1 0, 0.0 -2,-0.1 0, 0.0 0.037 18.7-134.6 -43.9 157.1 28.8 -9.8 16.3
5 200 A R + 0 0 174 3,-0.0 2,-1.6 2,-0.0 -1,-0.1 0.294 60.4 134.1 -97.8 0.9 32.4 -8.5 16.6
6 201 A R + 0 0 178 1,-0.1 -2,-0.1 2,-0.1 0, 0.0 -0.429 24.5 143.8 -54.0 86.9 33.5 -11.9 17.9
7 202 A A + 0 0 76 -2,-1.6 -1,-0.1 2,-0.1 -2,-0.0 -0.471 24.7 108.8-134.5 48.7 36.5 -11.8 15.5
8 203 A Q S S+ 0 0 149 3,-0.0 2,-0.1 4,-0.0 -2,-0.1 -0.694 77.8 88.8-115.4 54.1 39.3 -13.4 17.4
9 204 A H S >> S- 0 0 121 4,-0.0 3,-2.1 0, 0.0 4,-0.7 -0.341 88.3 -9.7-128.0-146.1 38.5 -16.0 14.8
10 205 A N H 3> S+ 0 0 145 1,-0.3 4,-0.8 2,-0.2 5,-0.2 0.673 125.2 50.8 -27.9 -50.8 39.4 -17.0 11.2
11 206 A E H 34 S+ 0 0 159 1,-0.2 4,-0.3 2,-0.1 -1,-0.3 0.843 106.1 59.4 -64.2 -34.5 41.5 -13.9 10.2
12 207 A V H X4 S+ 0 0 60 -3,-2.1 3,-0.5 2,-0.1 4,-0.4 0.982 107.8 32.9 -62.8 -61.2 43.7 -14.0 13.3
13 208 A E H >X S+ 0 0 78 -4,-0.7 3,-4.0 1,-0.2 4,-0.9 0.950 109.6 53.5 -70.0 -62.3 45.4 -17.4 13.2
Desired output
ASG ILE A 99 2 C Coil -82.86 141.16 97.1 1N8W
ASG LEU A 146 48 C Coil -68.82 158.46 0.0 1N8W
ASG LEU A 302 167 E Strand -98.11 143.77 19.7 1N8W
I want to extract the lines only if the values in the phi and psi columns between -67<=phi<=-99 and 100<=psi<=165
I would like to save the outputs in to another folder f2 with the input file names. I highly appreciate your valuable suggestions.
Thanks a lot.