>Thanks for the ideas, it kind of solves the need, but pads to left and bottom >only:
tmp = [data ; repmat(data($, :), addedRows, 1)]; paddedMat = [tmp repmat(tmp(:, $) , 1, addedCols)] padds on the bottom and RIGHT. To pad on the left and top, just tune the concatenation: tmp = [repmat(data($, :), addedRows, 1) ; data]; paddedMat = [repmat(tmp(:, $) , 1, addedCols) tmp] Every side combination is possible. SG _______________________________________________ users mailing list [email protected] http://lists.scilab.org/mailman/listinfo/users
