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

Cone plotting incorrectly where [angle] >= Plunge #53

Open
OverCal opened this issue Aug 10, 2024 · 0 comments
Open

Cone plotting incorrectly where [angle] >= Plunge #53

OverCal opened this issue Aug 10, 2024 · 0 comments

Comments

@OverCal
Copy link

OverCal commented Aug 10, 2024

When bidirectional = True, the shading of the cone is inverted where it crosses the stereonet boundary.

This error can be reproduced by using the example script with slight modification, where an angle of 59 will plot correctly and and angle of 60 will then invert:

import matplotlib.pyplot as plt
import numpy as np
import mplstereonet

Generate some scattered strikes and dips

num = 100
strike0, dip0 = 180, 60
strike = np.random.normal(strike0, 5, num)
dip = np.random.normal(dip0, 5, num)

Convert the strike/dip of the pole to plane to a plunge/bearing

plunge, bearing = mplstereonet.stereonet_math.pole2plunge_bearing(strike0, dip0)
fig, ax = mplstereonet.subplots()
ax.pole(strike, dip, color='k')
ax.cone(plunge, bearing, [60], linewidth=1, facecolor='blue', zorder=1, alpha=0.2, edgecolors='black', bidirectional=True)
plt.show()

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant