bugGNU Octave - Bugs: bug #65734, some bar plot updates don't...

 
 

bug #65734: some bar plot updates don't properly update axes and labels

Submitter:  Nicholas Jankowski <nrjank>
Submitted:  Mon 13 May 2024 05:16:33 PM UTC
   
 
Category:  Plotting Severity:  2 - Minor
Priority:  5 - Normal Item Group:  Incorrect Result
Status:  None Assigned to:  None
Originator Name:  Open/Closed:  * Open
Release:  * 9.1.0 Operating System:  * Any
Fixed Release:  None Planned Release:  None
* Mandatory Fields

Add a New Comment Rich Markup
   

Mon 13 May 2024 05:16:33 PM UTC, original submission:  

while writing bar/barh tests for bug #65671, i came upon a few cases where changes to bar data do not trigger needed updates to axes properties:

1) changing to horizontal results in incorrect yaxis ticks/labels
h = bar (2:4);
set (h, 'horizontal', 'on');

result should be identical, or close too h = barh(2:4).  vertical axis ticks/labels are not updated however, leaving a number of intermediate values.  see attached figure comparing both for octave 9.1.0 and matlab. (results are independent of the pending patch for bug #65671)

2) changing xdata moves the bars but fails to update xlim and xticks to match:

hf = figure(); hax = axes('parent',hf);
h = bar (hax, 2:4);
set (h, 'xdata', [3:5]')  # stored vert, but horiz no difference
set (hax, 'xlim', [2.5 5.5]);

as shown in the figure next to a matlab comparison, setting xdata fails to update xlim to show the bars, and even with a manual xlim the new xaxis ticks/lables have not been created.

since changing xdata calls h= bar () again, not sure why the axis setting isn't occurring along with it.

will be writing up xtest BISTs to capture these along with tests for bug #65671. then will give these a look after that one's finished.


Nicholas Jankowski <nrjank>
Group Member

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

Attached Files
file #56041:  bar+xdatachange.PNG added by nrjank (42KiB - image/png)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by nrjank (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only group members can vote.

     

    Follow 3 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2024-05-13 nrjank Summarysame bar plot updates don't properly update axes and labels some bar plot updates don't properly update axes and labels
    2024-05-13 nrjank Attached File- Added bar+horizotal_yaxistickslabels.PNG, #56040
        Attached File- Added bar+xdatachange.PNG, #56041

    Back to the top

    Powered by Savane 3.13-4b48.
    Corresponding source code