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

Bug in units for NASA Exoplanet Archive results #2949

Open
bmorris3 opened this issue Feb 13, 2024 · 6 comments
Open

Bug in units for NASA Exoplanet Archive results #2949

bmorris3 opened this issue Feb 13, 2024 · 6 comments

Comments

@bmorris3
Copy link
Contributor

Using astroquery 0.4.7.dev9069, I ran into an incorrect unit in the NASA Exoplanet Archive module today:

>>> from astroquery.ipac.nexsci.nasa_exoplanet_archive import NasaExoplanetArchive as NEA

>>> result = NEA.query_object('K2-141 b')

>>> result['pl_trandur']
[  nan   nan   nan 0.868 0.94 ] d

The pl_trandur column is the transit duration, noted as "T_14" on the rendered webpage, with units of hours (fifth row from the bottom):

Screen Shot 2024-02-13 at 10 00 39

I dug into the source and I'm not sure why it doesn't work with the existing logic. I also checked that the Exoplanet Archive table claims units of hours, and it does. Should we put a one-off fix for this column in _fix_units, here?

unit = data[col].unit
unit = UNIT_MAPPER.get(str(unit), unit)

Related to: #2130, #2218

@bsipocz
Copy link
Member

bsipocz commented Feb 15, 2024

cc @rickynilsson

@rickynilsson
Copy link
Contributor

I'll look into this.

@bmorris3
Copy link
Contributor Author

bmorris3 commented Apr 8, 2024

Any updates? Thanks!

@rickynilsson
Copy link
Contributor

Any updates? Thanks!

Thanks for the ping. I'll try to get to this when I'm back from eclipse travel later this week.

@bmorris3
Copy link
Contributor Author

Friendly reminder @rickynilsson.

@rickynilsson
Copy link
Contributor

@bmorris3 - There seems to be an inconsistency in the units for Transit Duration in the Exoplanet Archive, which are in units of hours in the overviews and PS ICE table, but in units of days in the underlying db table (and hence in TAP queries used by astroquery's Exoplanet Archive module). As you say, it should be hours everywhere. I've brought it up with the team and we'll fix the unit in the underlying db as soon as possible. Thanks for bringing this to our attention.

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

No branches or pull requests

3 participants