From maintainers-request at octave dot org Mon Apr 11 15:45:56 2005 Subject: Should vertcat(A,B) behave identically to [A;B]? From: Keith Goodman To: octave maintainers mailing list Date: Mon, 11 Apr 2005 14:14:10 -0500 Should vertcat(A,B) behave identically to [A;B]? In matlab vertcat('a ';'a') and ['a ';'a'] return an error. In octave vertcat('a ';'a') returns an error but ['a ';'a'] doesn't. That means, for example, that > disp(unique(['a ';'a'],'rows')) a > disp(unique([' a';'a'],'rows')) a a In other words, trailing blanks, but not initial blanks, are ignored in unique because > disp(1*['a ';'a']) 97 32 97 32 > disp(1*[' a';'a']) 32 97 97 32 If you think that 'a ' and 'a' are unique, then you shouldn't allow ['a ';'a'].