I'm trying to print out
for i in 0.80 0.85 0.90 0.95 1.00 1.05 1.10 1.15 1.20 1.25 1.30 1.35 1.40; do
awk -v a="$i" '{printf "%10.2f %10.2f\n", a, ($8*627.509)}' e1.txt > e2.txt
done
But when I open this file,
1.40 -12111939.85
1.40 -12112479.17
1.40 -12112817.98
1.40 -12112997.55
1.40 -12113047.39
1.40 -12112998.93
1.40 -12112873.57
1.40 -12112695.74
1.40 -12112504.02
1.40 -12112346.74
1.40 -12112316.49
1.40 -12112204.51
1.40 -12112149.56
Ignore the second column as it reads the value and operates from other txt file, e1.txt.
As it is shown, only the last for-loop index variable is used in this case. But I wish to print the for-loop values of 0.80 ~ 1.40 accordingly to each line.
done > e2.txt>to>>and you are good to go.