annotate NEWS-3.html @ 86:298b7f4ac910 kai

Deleted unused images and make names more meaningful.
author Kai T. Ohlhus <k.ohlhus@gmail.com>
date Mon, 17 Oct 2016 18:38:15 +0200
parents 373d2dba318e
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
67
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
1 <!doctype html public "-//IETF//DTD HTML Strict//EN">
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
2 <html>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
3 <head>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
4 <title>Notable Changes in Octave version 3</title>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
5 <link rel="stylesheet" type="text/css" href="octave.css" />
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
6 </head>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
7
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
8 <body>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
9 <div id="title"><h1>News for Octave Version 3</h1></div>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
10
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
11 <ul>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
12 <li>Compatibility with Matlab graphics is much better. We now
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
13 have some graphics features that work like Matlab's Handle
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
14 Graphics (tm):
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
15 <ul>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
16 <li> You can make a subplot and then use the print function to
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
17 generate file with the plot.</li>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
18
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
19 <li> RGB line colors are supported if you use gnuplot 4.2. Octave
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
20 can still use gnuplot 4.0, but there is no way to set arbitrary
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
21 line colors with it when using the Matlab-style plot functions.
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
22 There never was any way to do this reliably with older versions
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
23 of gnuplot (whether run from Octave or not) since it only
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
24 provided a limited set to choose from, and they were terminal
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
25 dependent, so choosing color 1 with the X11 terminal would be
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
26 different from color 1 with the PostScript terminal. Valid RGB
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
27 colors for gnuplot 4.0 are the eight possible combinations of 0
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
28 and 1 for the R, G and B values. Invalid values are all mapped
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
29 to the same color.
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
30 <p>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
31 This also affects patch objects used in the bar, countour, meshc
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
32 and surfc functions, where the bars and contours will be
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
33 monochrome. A workaround for this is to type "colormap gmap40"
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
34 that loads a colormap that in many cases will be adequate for
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
35 simple bar and contour plots.</li>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
36
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
37 <li> You can control the width of lines using (for example):
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
38 <pre>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
39 line (x, y, "linewidth", 4, "color", [1, 0, 0.5]);
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
40 </pre>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
41 (this also shows the color feature).</li>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
42
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
43 <li> With gnuplot 4.2, image data is plotted with gnuplot and may be
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
44 combined with other 2-d plot data.</li>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
45
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
46 <li> Lines for contour plots are generated with an Octave function, so
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
47 contour plots are now 2-d plots instead of special 3-d plots, and
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
48 this allows you to plot additional 2-d data on top of a contour
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
49 plot.</li>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
50
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
51 <li> With the gnuplot "extended" terminals the TeX interpreter is
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
52 emulated. However, this means that the TeX interpreter is only
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
53 supported on the postscript terminals with gnuplot 4.0. Under
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
54 gnuplot 4.2 the terminals aqua, dumb, png, jpeg, gif, pm, windows,
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
55 wxt, svg and x11 are supported as well.</li>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
56
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
57 <li> The following plot commands are now considered obsolete and will
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
58 be removed from a future version of Octave:
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
59 <pre>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
60 __gnuplot_set__
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
61 __gnuplot_show__
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
62 __gnuplot_plot__
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
63 __gnuplot_splot__
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
64 __gnuplot_replot__
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
65 </pre>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
66 Additionally, these functions no longer have any effect on plots
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
67 created with the Matlab-style plot commands
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
68 (<tt>plot</tt>, <tt>line</tt>, <tt>mesh</tt>, <tt>semilogx</tt>,
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
69 etc.).
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
70
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
71 <li> Plot property values are not extensively checked. Specifying
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
72 invalid property values may produce unpredictible results.</li>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
73
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
74 <li> Octave now sends data over the same pipe that is used to send
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
75 commands to gnuplot. While this avoids the problem of
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
76 cluttering /tmp with data files, it is no longer possible to use
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
77 the mouse to zoom in on plots. This is a limitation of gnuplot,
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
78 which is unable to zoom when the data it plots is not stored in
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
79 a file. Some work has been done to fix this problem in newer
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
80 versions of gnuplot (> 4.2.2). See for example,
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
81 <a href="http://www.nabble.com/zooming-of-inline-data-tf4357017.html#a12416496">this thread</a> on the gnuplot development list.
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
82 </ul></li>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
83
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
84
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
85 <li>The way Octave handles search paths has changed. Instead of
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
86 setting the built-in variable <tt>LOADPATH</tt>, you must
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
87 use <tt>addpath</tt>, <tt>rmpath</tt>, or <tt>path</tt> to
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
88 manipulate the function search path. These functions will
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
89 maintain <tt>"."</tt> at the head of the path, for compatibility
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
90 with Matlab.
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
91 <p>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
92 Leading, trailing or doubled colons are no longer special.
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
93 Now, all elements of the search path are explicitly included in
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
94 the path when Octave starts. To display the path, use
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
95 the <tt>path</tt> function.
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
96 <p>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
97 Path elements that end in <tt>//</tt> are no longer searched recursively.
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
98 Instead, you may use addpath and the genpath function to add an
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
99 entire directory tree to the path. For example,
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
100 <pre>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
101 addpath (genpath ("~/octave"));
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
102 </pre>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
103 will add ~/octave and all directories below it to the head of the
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
104 path.</li>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
105
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
106
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
107 <li>Previous versions of Octave had a number of built-in variables to
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
108 control warnings (for example, <tt>warn_divide_by_zero</tt>). These
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
109 variables have been replaced by warning identifiers that are used
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
110 with the warning function to control the state of warnings.
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
111 <p>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
112 For example, instead of writing
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
113 <pre>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
114 warn_divide_by_zero = false;
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
115 </pre>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
116 to disable divide-by-zero warnings, you should write
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
117 <pre>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
118 warning ("off", "Octave:divide-by-zero");
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
119 </pre>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
120 You may use the same technique in your own code to control
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
121 warnings. For example, you can use
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
122 <pre>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
123 warning ("My-package:phase-of-the-moon",
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
124 "the phase of the moon could cause trouble today");
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
125 </pre>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
126 to allow users to control this warning using the
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
127 <tt>"My-package:phase-of-the-moon"</tt> warning identifier.
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
128 <p>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
129 You may also enable or disable all warnings, or turn them into
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
130 errors:
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
131 <pre>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
132 warning ("on", "all");
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
133 warning ("off", "all");
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
134 warning ("error", "Octave:divide-by-zero");
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
135 warning ("error", "all");
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
136 </pre>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
137 You can query the state of current warnings using
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
138 <pre>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
139 warning ("query", ID)
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
140 warning ("query")
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
141 </pre>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
142 (only those warning IDs which have been explicitly set are
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
143 returned).
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
144 <p>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
145 A partial list and description of warning identifiers is available
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
146 using
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
147 <pre>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
148 help warning_ids
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
149 </pre></li>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
150
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
151
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
152 <li>All built-in variables have been converted to functions. This
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
153 change simplifies the interpreter and allows a consistent
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
154 interface to internal variables for user-defined packages and the
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
155 core functions distributed with Octave. In most cases, code that
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
156 simply accesses internal variables does not need to change. Code
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
157 that sets internal variables will change. For example, instead of
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
158 writing
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
159 <pre>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
160 PS1 = ">> ";
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
161 </pre>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
162 you will need to write
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
163 <pre>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
164 PS1 (">> ");
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
165 </pre>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
166 If you need write code that will run in both old and new versions
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
167 of Octave, you can use something like
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
168 <pre>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
169 if (exist ("OCTAVE_VERSION") == 5)
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
170 ## New:
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
171 PS1 (">> ");
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
172 else
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
173 ## Old:
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
174 PS1 = ">> ";
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
175 endif
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
176 </pre></li>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
177
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
178
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
179 <li>For compatibility with Matlab, the output order of Octave's
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
180 <tt>"system"</tt> function has changed from
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
181 <pre>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
182 [output, status] = system (cmd);
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
183 </pre>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
184 to
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
185 <pre>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
186 [status, output] = system (cmd);
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
187 </pre></li>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
188
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
189
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
190 <li>For compatibility with Matlab, <tt>normcdf</tt>, <tt>norminv</tt>,
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
191 <tt>normpdf</tt>, and <tt>normrnd</tt> have been modified to
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
192 compute distributions using the standard deviation instead of the
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
193 variance.</li>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
194
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
195
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
196 <li>For compatibility with Matlab, the output of Octave's fsolve
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
197 function has been changed from
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
198 <pre>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
199 [x, info, msg] = fsolve (...);
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
200 </pre>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
201 to
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
202 <pre>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
203 [x, fval, info] = fsolve (...);
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
204 </pre></li>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
205
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
206
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
207 <li>For compatibility with Matlab, <tt>normcdf</tt>, <tt>norminv</tt>,
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
208 <tt>normpdf</tt>, and <tt>normrnd</tt> have been modified to
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
209 compute distributions using the standard deviation instead of the
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
210 variance.</li>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
211
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
212
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
213 <li>For compatibility with
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
214 Matlab, <tt>gamcdf</tt>, <tt>gaminv</tt>, <tt>gampdf</tt>,
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
215 <tt>gamrnd</tt>, <tt>expcdf</tt>, <tt>expinv</tt>, <tt>exppdf</tt>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
216 and <tt>exprnd</tt> have been modified to compute the
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
217 distributions using the standard scale factor rather than one over
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
218 the scale factor.
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
219 </ul>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
220
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
221 </body>
373d2dba318e Include stuff from current octave.org for later hosting.
Kai T. Ohlhus <k.ohlhus@gmail.com>
parents:
diff changeset
222 </html>