Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix example_angular.py and add generated image #55

Merged
merged 1 commit into from
Jan 4, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file added doc/example_angular.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions doc/example_angular.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import numpy as np
import matplotlib.pyplot as plt
from matplotlib_scalebar.scalebar import ScaleBar, ANGULAR
from matplotlib_scalebar.scalebar import ScaleBar

delta = 0.025
x = y = np.arange(-3.0, 3.0, delta)
Expand All @@ -14,7 +14,7 @@
for ax, dx in zip(axes, [delta, delta / 60, delta / 3600]):
ax.imshow(Z)

scalebar = ScaleBar(dx, "deg", ANGULAR)
scalebar = ScaleBar(dx, "deg", dimension="angle")
ax.add_artist(scalebar)

ax.set_title("dx = {:.6f}deg".format(dx))
Expand Down