rhnaeco
Technical User
- Aug 11, 2005
- 45
Hi, I have columns of data which are measurements of current flow in the water column. The instrument returns data from above the water column, which is data I want to remove (retain only data in the water, not any noise).
my datafile (headers):
ensemble, depth, 1, 2, 3, 4,... 34, 35, 36, 37
the numbers are bin numbers; bin 1 is on the seabed and bin 37 is above the water column. I want to delete all data above the waterline. Normally i'd just print $1-$34, but as the tide changes water level it is not always the same bin.
I can convert 'depth' to 'bin number' so my question is:
Can i use a column as a variable to control how many columns i print in total?
so:
ensemble, depth, bin/variable, bin 1, bin 2......
23453, 33.4, 33, 1, 2, 3, 4...31, 32 (stop)
print $1, £2, $3, $4 to $35
35265, 29.8, 29, 1, 2, 3, 4...27, 28 (stop)
print $1, $2, $3, $4 to $31
I hope someone can help
thanks
R
my datafile (headers):
ensemble, depth, 1, 2, 3, 4,... 34, 35, 36, 37
the numbers are bin numbers; bin 1 is on the seabed and bin 37 is above the water column. I want to delete all data above the waterline. Normally i'd just print $1-$34, but as the tide changes water level it is not always the same bin.
I can convert 'depth' to 'bin number' so my question is:
Can i use a column as a variable to control how many columns i print in total?
so:
ensemble, depth, bin/variable, bin 1, bin 2......
23453, 33.4, 33, 1, 2, 3, 4...31, 32 (stop)
print $1, £2, $3, $4 to $35
35265, 29.8, 29, 1, 2, 3, 4...27, 28 (stop)
print $1, $2, $3, $4 to $31
I hope someone can help
thanks
R