Everything in one package
From raw telescope data to scientific insight¶
No more copying formulas from papers, downloading stale CSV files or ignoring error bars.
Published metrics¶
Earth Similarity Index (4- and 2-parameter), Mars, Venus and Titan similarity, PHI and BCI, implemented exactly as published.
Habitable zones¶
Kopparapu et al. (2014) conservative and optimistic boundaries, as fluxes or orbital distances.
Honest uncertainty¶
Monte Carlo propagation of lopsided error bars, for one planet or the whole catalogue, with 68% and 95% intervals.
Live NASA data¶
Every confirmed planet from the NASA Exoplanet Archive. No API key, and a local cache for offline work.
ML-ready features¶
A scikit-learn transformer that turns raw catalogue columns into 15 habitability features.
How it works
From install to answers in minutes¶
3
Get answers with error bars¶
Monte Carlo turns measurement errors into medians and credible intervals.
import exohab as eh
df = eh.load_nasa_exoplanets() # 6,000+ confirmed planets
print(df.nlargest(5, "esi_2p")[["pl_name", "esi_2p"]])
mc = eh.compute_esi_2p_mc(radius=(1.34, 0.11, -0.18), flux=(0.66, 0.23, -0.41),
n_samples=20_000, seed=42, truncate=True)
print(f"Kepler-442 b: ESI {mc.median:.2f}, 68% range {mc.ci68[0]:.2f}-{mc.ci68[1]:.2f}")
See it
Publication-ready plots in one line¶


Built for
Students, data scientists and researchers¶
Students & educators¶
Compare real worlds with Earth in minutes, with clear plots for classes and outreach.
Data scientists¶
Clean DataFrames and engineered habitability features for classification and clustering.
Researchers¶
Cited formulas, custom references and weights, and uncertainty-aware results you can cite.
Grounded in the literature
Science you can check¶
Every formula is cited in its docstring, and the test suite checks results against published values.
Schulze-Makuch et al. 2011 · Astrobiology Kopparapu et al. 2013, 2014 · ApJ Irwin et al. 2014 · Challenges Kashyap Jagadeesh 2017 Planetary Habitability Laboratory NASA Exoplanet Archive
FAQ
Frequently asked questions¶
What is the Earth Similarity Index (ESI)?
The Earth Similarity Index is a number from 0 to 1 that measures how similar a planet's radius, bulk density, escape velocity and surface temperature are to Earth's (Schulze-Makuch et al. 2011). A two-parameter version uses radius and stellar flux. It measures similarity, not the probability of life.
Is exohab free?
Yes. exohab is open source under the MIT license and can be used freely in research, teaching and commercial projects.
Do I need an API key for NASA data?
No. exohab loads the NASA Exoplanet Archive through its public TAP service, which needs no API key, and caches the data locally for offline use.
How do I install exohab?
Run pip install exohab, or pip install "exohab[all]" to include
plotting and machine-learning features. Python 3.10 or newer is required.
How can I cite exohab?
Each release is archived on Zenodo with a DOI. Cite the project as 10.5281/zenodo.24269967, and also cite the original papers of the metrics you use. See Citing exohab.
Start exploring other worlds¶
Free and open source, and installed in seconds.