-
Notifications
You must be signed in to change notification settings - Fork 11
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
Major refactor of acf.py #359
Conversation
* Changed all classmethods to staticmethods * Created staticmethod plot_acf_param() to handle plotting of values, which is called within plot_acfs() as needed to plot real, imaginary, power, and phase of ACF * Return all axes from plot_acfs() as list * Plot real and imaginary ACF values on input ax to plot_acfs() if plot_pwr_and_phs False, otherwise use plt.gca() * Removed some unnecessary internal variables in plot_acfs().
* The returned phase array from plot_acfs() now also returns values in radians.
Made another commit as I realized I had inadvertently changed the phase plotting to plot in radians. It is now back to plotting in degrees. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Other than the tiny error, looks great for everything else.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tested with various combos of values for:
import pydarn
import matplotlib.pyplot as plt
from datetime import datetime
#reader = pydarn.SuperDARNRead("/Users/carley/Documents/data/20140105.1208.03.rkn.rawacf")
reader = pydarn.SuperDARNRead("/Users/carley/Documents/data/20180520.0801.00.lyr.rawacf")
data = reader.read_rawacf()
plt.figure(figsize=(12, 7))
rtn = pydarn.ACF.plot_acfs(data, beam_num=5, gate_num=12, normalized=True,
start_time=datetime(2018, 5, 20, 9, 0), pwr_and_phs=True,
plot_blank=True)
print(rtn)
plt.show()
All worked well and plots are correct.
Scope
issue: N/A
Approval
Number of approvals: 1
Test
matplotlib version: 3.7.2
Try running the tutorial from https://pydarn.readthedocs.io/en/main/user/acf/, and using as many of the optional arguments as you can.