Introduction
Introduction Statistics Contact Development Disclaimer Help
tfix min/max - numtools - perform numerical operations on vectors and matrices …
git clone git://src.adamsgaard.dk/numtools
Log
Files
Refs
README
LICENSE
---
commit 73826473ebdf93c722546afd28b60b783ae38abf
parent 9006f73b75c919e747e6c232d0ac98c2f5311987
Author: Anders Damsgaard <[email protected]>
Date: Thu, 25 Mar 2021 16:58:25 +0100
fix min/max
Diffstat:
M max | 2 +-
M min | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/max b/max
t@@ -1,7 +1,7 @@
#!/usr/bin/awk -f
{
for (i = 0; i < NF; i++)
- if ($i > max[i])
+ if (NR == 1 || $i > max[i])
max[i] = $i
}
END {
diff --git a/min b/min
t@@ -1,7 +1,7 @@
#!/usr/bin/awk -f
{
for (i = 0; i < NF; i++)
- if ($i < min[i])
+ if (NR == 1 || $i < min[i])
min[i] = $i
}
END {
You are viewing proxied material from mx1.adamsgaard.dk. The copyright of proxied material belongs to its original authors. Any comments or complaints in relation to proxied material should be directed to the original authors of the content concerned. Please see the disclaimer for more details.