Thanks to visit codestin.com
Credit goes to github.com

Skip to content

plot(2D, 2D) will cycle through the input columns even with non-matching shapes #9784

Closed
@anntzer

Description

@anntzer

Bug report

Bug summary

see title

Code for reproduction

plot([[0, 1, 2], [3, 4, 5]], [[0, 1], [2, 3]])

Actual outcome

figure_1

This plots column 0 of x vs column 0 of y; column 1 of x vs column 1 of y; and column 2 of x vs column 1 of y.

Expected outcome

Error out with non-matching shapes (the 1 -> broadcast should remain possible).

https://github.com/matplotlib/matplotlib/blob/master/lib/matplotlib/axes/_base.py#L393 should probably be replaced by a broadcast.

Matplotlib version

  • Operating system:
  • Matplotlib version: master, probably around forever.
  • Matplotlib backend (print(matplotlib.get_backend())):
  • Python version:
  • Jupyter version (if applicable):
  • Other libraries:

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions