7017
|
1 ## Copyright (C) 1994, 1995, 1996, 1997, 2000, 2005, 2006, 2007 |
|
2 ## John W. Eaton |
2313
|
3 ## |
|
4 ## This file is part of Octave. |
|
5 ## |
|
6 ## Octave is free software; you can redistribute it and/or modify it |
|
7 ## under the terms of the GNU General Public License as published by |
7016
|
8 ## the Free Software Foundation; either version 3 of the License, or (at |
|
9 ## your option) any later version. |
2313
|
10 ## |
|
11 ## Octave is distributed in the hope that it will be useful, but |
|
12 ## WITHOUT ANY WARRANTY; without even the implied warranty of |
|
13 ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
|
14 ## General Public License for more details. |
|
15 ## |
|
16 ## You should have received a copy of the GNU General Public License |
7016
|
17 ## along with Octave; see the file COPYING. If not, see |
|
18 ## <http://www.gnu.org/licenses/>. |
933
|
19 |
6895
|
20 ## Undocumented internal function. |
3402
|
21 |
2314
|
22 ## Author: jwe |
|
23 |
6302
|
24 function retval = __plr1__ (h, theta, fmt) |
933
|
25 |
6257
|
26 if (nargin != 3) |
6046
|
27 print_usage (); |
933
|
28 endif |
|
29 |
|
30 [nr, nc] = size (theta); |
|
31 if (nr == 1) |
|
32 theta = theta'; |
|
33 tmp = nr; |
|
34 nr = nc; |
|
35 nc = tmp; |
|
36 endif |
|
37 theta_i = imag (theta); |
|
38 if (any (theta_i)) |
|
39 rho = theta_i; |
|
40 theta = real (theta); |
|
41 else |
|
42 rho = theta; |
|
43 theta = (1:nr)'; |
|
44 endif |
|
45 |
6302
|
46 retval = __plr2__ (h, theta, rho, fmt); |
933
|
47 |
|
48 endfunction |