Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Unexpected behavior for Axes.quiver(transform=None) #11153

Closed
@timhoffm

Description

@timhoffm

Bug report

Bug summary

I would expect thatAxes.quiver(transform=None) would behave the same as leaving out the kwargtransform (None implying default). However this is not the case. Instead the default for a missing transform isAxes.transData.

As far as I understand, there is no reasonable semantics of an explicittransform=None here (except for 'use default'). It's probably an unintended implementation detail.

I therefore propose to change the behavior ofAxes.quiver(transform=None) to be the same as leaving out the kwarg. This would allow further code simplification with explicit kwargs (#11145).

Code for reproduction

import matplotlib.pyplot as pltimport numpy as npX = np.arange(-10, 10, 1)Y = np.arange(-10, 10, 1)U, V = np.meshgrid(X, Y)fig, (ax1, ax2, ax3) = plt.subplots(1, 3, figsize=(12, 3))ax1.quiver(X, Y, U, V)ax2.quiver(X, Y, U, V, transform=None)ax3.quiver(X, Y, U, V, transform=ax2.transData)plt.show()

grafik

Expected: All there Axes should be equal.

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


      [8]ページ先頭

      ©2009-2025 Movatter.jp