Mercurial > hg > octave-terminal
changeset 7228:685c186d8f62
[project @ 2007-11-30 16:43:12 by jwe]
author | jwe |
---|---|
date | Fri, 30 Nov 2007 16:43:13 +0000 |
parents | bf7235434a2a |
children | 64d6f4dc37e0 |
files | scripts/ChangeLog scripts/plot/__go_draw_axes__.m scripts/plot/pareto.m src/ChangeLog src/OPERATORS/op-sbm-sbm.cc |
diffstat | 5 files changed, 14 insertions(+), 8 deletions(-) [+] |
line wrap: on
line diff
--- a/scripts/ChangeLog +++ b/scripts/ChangeLog @@ -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 <dbateman@free.fr> + + * 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 <dbateman@free.fr> * plot/pareto.m: New file.
--- a/scripts/plot/__go_draw_axes__.m +++ b/scripts/plot/__go_draw_axes__.m @@ -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
--- a/scripts/plot/pareto.m +++ b/scripts/plot/pareto.m @@ -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,
--- a/src/ChangeLog +++ b/src/ChangeLog @@ -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 <jwe@octave.org>