Mon 24 Jun 2013 12:24:38 AM UTC, comment #8:
strjoin() has been removed from the strings package. The version included in Octave core works correctly. I'm closing this report.
|
Sun 23 Jun 2013 04:00:44 PM UTC, comment #7:
I searched for that error message (appears in pt-mat.cc) and through the log (for "pt-mat.cc"), and I believe it is this bug fix that accounts for your current error.
http://hg.savannah.gnu.org/hgweb/octave/rev/797ac81586d1
author Julien Bect <julien.bect@supelec.fr>
date Tue, 26 Feb 2013 12:06:45 +0100 (3 months ago)
This explains why "sprintf()" was being used in the strjoin.m routine before this recent optimization:
https://savannah.gnu.org/patch/?8066
Unless you want to rebuild to the latest code which includes the above fix (there was a scheduled release coming up, but I'm not sure if that will be met, so I don't think it pays to wait a week or two), you might be able to work from the less efficient version of strjoin() prior to the patch, which would be this one:
http://hg.savannah.gnu.org/hgweb/octave/file/424463a80134/scripts/strings/strjoin.m
(Again, use the "raw" button to download the file.)
Whether the above is the same script file that originally caused you errors, I'm not sure.
|
Sun 23 Jun 2013 12:46:40 PM UTC, comment #6:
Dan, the size of the array is correct:
I did some debugging right before line 80:
As noted in the original submission, I'm using Octave 3.6.2.
|
Sun 23 Jun 2013 04:54:26 AM UTC, comment #5:
I would think so. Send to maintainers list (which now also handles packages). C.D. usually handles the package changes.
|
Sun 23 Jun 2013 01:18:18 AM UTC, comment #4:
Dan, the function strjoin() wasn't present in Octave core for 3.6.2.
The error being reported is for the strings package. Should strjoin be removed from the package?
http://octave.sourceforge.net/strings/overview.html
|
Sat 22 Jun 2013 04:42:39 PM UTC, comment #3:
Your examples works for me on my system:
Are you using the latest (or at least a very recent) version of Octave? The error message you are seeing is indicating that {"Octave", "Scilab", "Lush", "Yorick"} is a 2x4 matrix. But I'm seeing it as a 1x4 array.
Also, I don't see how the size of the delimiter matrix at that point in the function could be 1x1. There is an if/elseif/else statement for which at least one of those must happen. It's not the second case, and the other two cases would increase the size of the delimiter cell string which it is converted to.
All I can think of is that you might have an old Octave version that has buggy cell string behavior.
This may have lead to uncovering a problem, though. The command strjoin ({}, "*") produces an odd result. I will note this here:
https://savannah.gnu.org/patch/?8066
|
Sat 22 Jun 2013 02:31:03 PM UTC, comment #2:
Firstly, I noticed that this version of strjoin uses a completely different syntax than what the function reference says: it takes the strings to join in the first parameter as a cell array and the delimiter as the second. But it's probably good to change that, since MATLAB's strjoin function does the same thing.
Secondly, it throws a dimension mismatch error if I pass more than one string in the cell array:
|
Fri 21 Jun 2013 06:37:05 PM UTC, comment #1:
There have been some recent changes to strjoin.m:
http://hg.savannah.gnu.org/hgweb/octave/rev/c6d61dca5acd
http://hg.savannah.gnu.org/hgweb/octave/rev/70ea511edbc4
This is a change to the script file only, so should be easy to test. Could you please get the latest version of the script file:
http://hg.savannah.gnu.org/hgweb/octave/file/519343308ab1/scripts/strings/strjoin.m
(go to the web location and click on the left column menu item that indicates "raw") and let us know if that solves the problem?
|
Wed 19 Jun 2013 01:45:25 PM UTC, original submission:
strjoin (from the strings package; reference) ignores trailing spaces in the first parameter, prefixstr:
Packages: octave 3.6.2-5+deb7u1 and octave-strings 1.1.0-1 amd64 from the Debian Wheezy repository.
|