# HG changeset patch # User jwe # Date 1196440993 0 # Node ID 685c186d8f62f8471334c6c2396fb8b155bfcec1 # Parent bf7235434a2a259f0a6135af9871ffbc3e3b93ca [project @ 2007-11-30 16:43:12 by jwe] diff -r bf7235434a2a -r 685c186d8f62 scripts/ChangeLog --- a/scripts/ChangeLog Fri Nov 30 16:18:46 2007 +0000 +++ b/scripts/ChangeLog Fri Nov 30 16:43:13 2007 +0000 @@ -3,6 +3,13 @@ * plot/__go_draw_axes__.m: Don't compute data or axis limits. (get_data_limits, get_axis_limits): Delete. +2007-11-30 David Bateman + + * plot/__go_draw_axes__.m (do_tics_1): regexprep the cell array of + tick labels rather than one by one on the labels themselves. + * plot/pareto.m: Bug in numerical labels fixed. Bug in search for + 95% crossing fixed. + 2007-11-29 David Bateman * plot/pareto.m: New file. diff -r bf7235434a2a -r 685c186d8f62 scripts/plot/__go_draw_axes__.m --- a/scripts/plot/__go_draw_axes__.m Fri Nov 30 16:18:46 2007 +0000 +++ b/scripts/plot/__go_draw_axes__.m Fri Nov 30 16:43:13 2007 +0000 @@ -1411,9 +1411,9 @@ else fprintf (plot_stream, "set %stics nomirror (", ax); endif + labels = regexprep(labels, "%", "%%"); for i = 1:ntics - fprintf (plot_stream, " \"%s\" %g", - regexprep (labels(k++), "%", "%%"), tics(i)) + fprintf (plot_stream, " \"%s\" %g", labels{k++}, tics(i)) if (i < ntics) fputs (plot_stream, ", "); endif diff -r bf7235434a2a -r 685c186d8f62 scripts/plot/pareto.m --- a/scripts/plot/pareto.m Fri Nov 30 16:18:46 2007 +0000 +++ b/scripts/plot/pareto.m Fri Nov 30 16:43:13 2007 +0000 @@ -68,7 +68,7 @@ if (ischar (y)) y = cellstr (y); else - y = num2cell (y); + y = cellfun (@(x) num2str (x), num2cell (y), "UniformOutput", false); endif endif else @@ -81,8 +81,8 @@ cdf = cumsum (x); maxcdf = max(cdf); cdf = cdf ./ maxcdf; - [dummy, idx95] = min (abs (cdf - .95)); - idx95 = idx95(1); + cdf95 = cdf - 0.95; + idx95 = find(sign(cdf95(1:end-1)) != sign(cdf95(2:end)))(1); [ax, hbar, hline] = plotyy (ax, 1 : idx95, x (1 : idx95), 1 : length(cdf), 100 .* cdf, diff -r bf7235434a2a -r 685c186d8f62 src/ChangeLog --- a/src/ChangeLog Fri Nov 30 16:18:46 2007 +0000 +++ b/src/ChangeLog Fri Nov 30 16:43:13 2007 +0000 @@ -3,7 +3,8 @@ * ls-mat5.h (mat5_data_type): Delete trailing comma in enum decl. * oct-stream.cc (octave_base_stream::do_printf): Use OCTAVE_EMPTY_CPP_ARG to avoid annoying Sun compiler warning. - * OPERATORS/op-sbm-sbm.cc (DEFDBLCONVFN): Likewise. + * OPERATORS/op-sbm-sbm.cc (DEFDBLCONVFN): Delete useless macro + invocation. 2007-11-30 John W. Eaton diff -r bf7235434a2a -r 685c186d8f62 src/OPERATORS/op-sbm-sbm.cc --- a/src/OPERATORS/op-sbm-sbm.cc Fri Nov 30 16:18:46 2007 +0000 +++ b/src/OPERATORS/op-sbm-sbm.cc Fri Nov 30 16:43:13 2007 +0000 @@ -82,8 +82,6 @@ return new octave_sparse_matrix (SparseMatrix (v.sparse_bool_matrix_value ())); } -DEFDBLCONVFN (OCTAVE_EMPTY_CPP_ARG, sparse_bool_matrix, bool_array) - void install_sbm_sbm_ops (void) {