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

Ambiguous station_count column in events_to_df #195

Open
sboltz opened this issue Jul 26, 2020 · 4 comments
Open

Ambiguous station_count column in events_to_df #195

sboltz opened this issue Jul 26, 2020 · 4 comments
Labels

Comments

@sboltz
Copy link
Contributor

sboltz commented Jul 26, 2020

  • obsplus version: master
  • Python version: 3.7.4
  • Operating System: Ubuntu 18.04

Description

One of the columns in the output of events_to_df is simply called station_count, which is a deviation from the naming convention for the OriginQuality object in obspy, which has an associated_station_count (number of stations at which the event was observed) and an used_station_count (number of stations from which data was used for origin computation). This is mildly confusing because from the label it is ambiguous as to which of these items the value refers to, or if it refers to something else entirely.

Proposed Change

Looking at the source code, it appears that station_count is intended to be the equivalent of used_station_count. I recommend changing the column name to reflect this. This might break things, but it should be relatively easy to update.

@d-chambers
Copy link
Member

Sounds like a good idea to me. I wouldn't worry about breaking changes to much as this is a relatively obscure column. Just make sure to add something in the changelog.

@sboltz
Copy link
Contributor Author

sboltz commented Jul 26, 2020 via email

@d-chambers
Copy link
Member

Ya, good point. It looks like 'station_countis used in the event bank index. At one point I had thought about restricting the index to only include columns necessary to perform the queries allowed byget_events` but other programs (like our processing software) currently need some of the other columns.

Maybe we just leave this issue open until we have to make a more significant breaking change to EventBank then tackle it then?

@sboltz
Copy link
Contributor Author

sboltz commented Jul 26, 2020 via email

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

No branches or pull requests

2 participants