Skip to content

Instantly share code, notes, and snippets.

@ashtonmv
Last active April 30, 2018 12:09
Show Gist options
  • Save ashtonmv/d321a87ce74cd42150edb0717b650bb2 to your computer and use it in GitHub Desktop.
Save ashtonmv/d321a87ce74cd42150edb0717b650bb2 to your computer and use it in GitHub Desktop.
A little bonus for you nerds
import matplotlib
matplotlib.use("Agg")
import matplotlib.pyplot as plt
ax = plt.figure(figsize=(8, 8)).gca()
ax.plot([0, 10], [0, 0], "k-")
ax.plot([0, 5], [0, 8.66], "k-")
ax.plot([5, 10], [8.66, 0], "k-")
ax.plot([5, 5], [0, 8.66], "k-")
ax.set_xlim(0, 10)
ax.set_ylim(-1, 9)
c = matplotlib.patches.Circle(
(5, 2.887), radius=2.887, fc="None", ec="k"
)
ax.add_patch(c)
plt.axis("off")
plt.savefig("hp.png")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment