X Tutup
Skip to content

patches fails when data are array, not list #6111

@cpbl

Description

@cpbl

Python 2.7.10, matplotlib 1.5.1, GNU/linux
Python from Ubuntu; matplotlib from pip --user

import pylab as plt
import numpy as np
x=np.arange(10,20)
y=np.arange(10,20)
plt.arrow(x,y,x+1,y*0)

Line 1170 in patches.py (if not length) fails in above if the distance+head_length is a numpy array rather than a list:
ValueError: The truth value of an array with more than one element is ambiguous. Use a.any() or a.all()

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      X Tutup