# HG changeset patch # User jwe # Date 1178122528 0 # Node ID 376b715747287930f85f6c0a71532addebe46236 # Parent c2b700808e0a5bb27813846d29396c1eaffebe59 [project @ 2007-05-02 16:15:28 by jwe] diff --git a/scripts/ChangeLog b/scripts/ChangeLog --- a/scripts/ChangeLog +++ b/scripts/ChangeLog @@ -1,3 +1,7 @@ +2007-05-02 John W. Eaton + + * plot/__go_draw_axes__.m: Convert NA to NaN before writing. + 2007-05-02 G. D. McBain * contour.m: Rewrite help string. diff --git a/scripts/plot/__go_draw_axes__.m b/scripts/plot/__go_draw_axes__.m --- a/scripts/plot/__go_draw_axes__.m +++ b/scripts/plot/__go_draw_axes__.m @@ -889,6 +889,13 @@ ## FIXME -- this may need to be converted to C++ for speed. + ## Convert NA elements to normal NaN values because fprintf writes + ## "NA" and that confuses gnuplot. + idx = find (isna (data)); + if (any (idx)) + data(idx) = NaN; + endif + if (nd == 2) nan_elts = find (sum (isnan (data))); fmt = strcat (repmat ("%g ", 1, rows (data)), "\n");