[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Octave-bug-tracker] [bug #58566] plotyy() and subplot() generate errors
From: |
Neil Konzen |
Subject: |
[Octave-bug-tracker] [bug #58566] plotyy() and subplot() generate errors |
Date: |
Sun, 14 Jun 2020 08:15:05 -0400 (EDT) |
User-agent: |
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/83.0.4103.97 Safari/537.36 Edg/83.0.478.45 |
URL:
<https://savannah.gnu.org/bugs/?58566>
Summary: plotyy() and subplot() generate errors
Project: GNU Octave
Submitted by: waterdog1
Submitted on: Sun 14 Jun 2020 12:15:03 PM UTC
Category: None
Severity: 3 - Normal
Priority: 5 - Normal
Item Group: Unexpected Error
Status: None
Assigned to: None
Originator Name: waterdog1
Originator Email:
Open/Closed: Open
Release: 5.2.0
Discussion Lock: Any
Operating System: Microsoft Windows
_______________________________________________________
Details:
The following code shows two problems. plotyy() generates a ton of 'error:
get: invalid handle (= -1850.04)' warnings, and the first of four plot traces
in each subplot aren't shown. If the 'hold on' is commented out, then the
subplot() window partitioning is ignored and only single chart is drawn.
The problem seems related to using subplot() to re-select a subplot that has
already been plotted into; i.e. the second pass through the ia loop below.
Neither problem occurs if plot() is used instead of plotyy().
function chart_prob
close all; figure;
x = linspace(0,10,10);
y = rand(4*4,10);
for ia=1:2
for ip=1:4
subplot(2,2,ip);
% hold on is commented, only 1 window-sized chart
% is drawn: subplot above is ignored().
hold on;
grid on;
iy = (ia-1)*4 + ip;
% plot(x,y(iy,:)); does the right thing
plotyy(x,y(iy,:), x,y(iy+1,:));
end
end
end
The only workaround I could find was to swap the for-ia and for-ip/subplot
lines, so that subplot() is only called once per chart area. Alas this is
extremely difficult to do in my particular application: any other workaround
ideas would be appreciated.
_______________________________________________________
Reply to this item at:
<https://savannah.gnu.org/bugs/?58566>
_______________________________________________
Message sent via Savannah
https://savannah.gnu.org/
- [Octave-bug-tracker] [bug #58566] plotyy() and subplot() generate errors,
Neil Konzen <=
- [Octave-bug-tracker] [bug #58566] plotyy() and subplot() generate errors, Markus Mützel, 2020/06/14
- [Octave-bug-tracker] [bug #58566] plotyy() and subplot() generate errors, Dmitri A. Sergatskov, 2020/06/14
- [Octave-bug-tracker] [bug #58566] plotyy() and subplot() generate errors, Dmitri A. Sergatskov, 2020/06/14
- [Octave-bug-tracker] [bug #58566] plotyy() and subplot() generate errors, Markus Mützel, 2020/06/15
- [Octave-bug-tracker] [bug #58566] plotyy() and subplot() generate errors, Dmitri A. Sergatskov, 2020/06/15
- [Octave-bug-tracker] [bug #58566] plotyy() and subplot() generate errors, Dmitri A. Sergatskov, 2020/06/15
- [Octave-bug-tracker] [bug #58566] plotyy() and subplot() generate errors, Markus Mützel, 2020/06/15
- [Octave-bug-tracker] [bug #58566] plotyy() and subplot() generate errors, Neil Konzen, 2020/06/15
- [Octave-bug-tracker] [bug #58566] plotyy() and subplot() generate errors, Dmitri A. Sergatskov, 2020/06/15
- [Octave-bug-tracker] [bug #58566] plotyy() and subplot() generate errors, Markus Mützel, 2020/06/15