summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBenjamin Franzke <benjaminfranzke@googlemail.com>2012-05-10 16:06:46 +0200
committerBenjamin Franzke <benjaminfranzke@googlemail.com>2012-05-10 16:06:46 +0200
commit068651c058912849c552bbf601f1ff98b8de25e9 (patch)
tree0c183e83a01593e781335e6a7e52b7a2da6a9b96
parent86f4356d2820317ef49ee3abfb94ac5fb7048fe2 (diff)
downloaddmc-068651c058912849c552bbf601f1ff98b8de25e9.tar.gz
dmc-068651c058912849c552bbf601f1ff98b8de25e9.tar.bz2
dmc-068651c058912849c552bbf601f1ff98b8de25e9.zip
Revert "normalize: normalizing matrics too."
This reverts commit 86f4356d2820317ef49ee3abfb94ac5fb7048fe2.
-rw-r--r--normalize.m10
1 files changed, 1 insertions, 9 deletions
diff --git a/normalize.m b/normalize.m
index b5e8ead..daff739 100644
--- a/normalize.m
+++ b/normalize.m
@@ -1,11 +1,3 @@
function n = normalize(data)
- if (size(data, 1) == 1 || size(data, 2) == 1)
- n = (data - min(data)) ./ (max(data) - min(data));
- return;
- end
-
- n = normalize(data(:, 1));
- for i = 1:(size(data, 2) - 1)
- n = [n normalize(data(:,i))];
- end
+ n = (data - min(data)) ./ (max(data) - min(data));
end