<commit_before>****************************
The Joker [YO-ker] /'joʊkər/
****************************

Introduction
============

|thejoker| [#f1]_ is a custom Monte Carlo sampler for the `two-body problem
<https://en.wikipedia.org/wiki/Two-body_problem>`_ that generates posterior
samplings in Keplerian orbital parameters given radial velocity observations of
stars. It is designed to deliver converged posterior samplings even when the
radial velocity measurements are sparse or very noisy. It is therefore useful
for constraining the orbital properties of binary star or star-planet systems.
Though it fundamentally assumes that any system has two massive bodies (and only
the primary is observed), |thejoker| can also be used for hierarchical systems
in which the velocity perturbations from a third or other bodies are much longer
than the dominant companion. See the paper [#f2]_ for more details about the
method and applications.

.. toctree::
    :maxdepth: 1

    install
    whats-new


Tutorials
=========

.. toctree::
    :maxdepth: 1

    examples/1-Getting-started.ipynb
    examples/2-Customize-prior.ipynb
    examples/3-Polynomial-velocity-trend.ipynb
    examples/4-Continue-sampling-mcmc.ipynb
    examples/5-Calibration-offsets.ipynb


Science demonstrations
======================

.. toctree::
    :maxdepth: 1

    examples/Thompson-black-hole.ipynb


Getting started
===============

Generating samples with |thejoker| requires three things:

    #. **The data**, `~thejoker.RVData`: radial velocity measurements,
       uncertainties, and observation times
    #. **The priors**, `~thejoker.JokerPrior`:
       the prior distributions over the parameters in *The Joker*
    #. **The sampler**, `~thejoker.TheJoker`: the work horse that runs the
       rejection sampler

Here, we'll work through a simple example to generate poserior samples for
orbital parameters given some sparse, simulated radial velocity data (shown
below). We'll first use these plain arrays to construct a `~thejoker.RVData`
object:

    >>> import astropy.units as u
    >>> import thejoker as tj
    >>> t = [0., 49.452, 95.393, 127.587, 190.408]
    >>> rv = [38.77, 39.70, 37.45, 38.31, 38.31] * u.km/u.s
    >>> err = [0.184, 0.261, 0.112, 0.155, 0.223] * u.km/u.s<commit_msg>add strader notebook to toc<commit_after>****************************
The Joker [YO-ker] /'joʊkər/
****************************

Introduction
============

|thejoker| [#f1]_ is a custom Monte Carlo sampler for the `two-body problem
<https://en.wikipedia.org/wiki/Two-body_problem>`_ that generates posterior
samplings in Keplerian orbital parameters given radial velocity observations of
stars. It is designed to deliver converged posterior samplings even when the
radial velocity measurements are sparse or very noisy. It is therefore useful
for constraining the orbital properties of binary star or star-planet systems.
Though it fundamentally assumes that any system has two massive bodies (and only
the primary is observed), |thejoker| can also be used for hierarchical systems
in which the velocity perturbations from a third or other bodies are much longer
than the dominant companion. See the paper [#f2]_ for more details about the
method and applications.

.. toctree::
    :maxdepth: 1

    install
    whats-new


Tutorials
=========

.. toctree::
    :maxdepth: 1

    examples/1-Getting-started.ipynb
    examples/2-Customize-prior.ipynb
    examples/3-Polynomial-velocity-trend.ipynb
    examples/4-Continue-sampling-mcmc.ipynb
    examples/5-Calibration-offsets.ipynb


Science demonstrations
======================

.. toctree::
    :maxdepth: 1

    examples/Thompson-black-hole.ipynb
    examples/Strader-circular-only.ipynb


Getting started
===============

Generating samples with |thejoker| requires three things:

    #. **The data**, `~thejoker.RVData`: radial velocity measurements,
       uncertainties, and observation times
    #. **The priors**, `~thejoker.JokerPrior`:
       the prior distributions over the parameters in *The Joker*
    #. **The sampler**, `~thejoker.TheJoker`: the work horse that runs the
       rejection sampler

Here, we'll work through a simple example to generate poserior samples for
orbital parameters given some sparse, simulated radial velocity data (shown
below). We'll first use these plain arrays to construct a `~thejoker.RVData`
object:

    >>> import astropy.units as u
    >>> import thejoker as tj
    >>> t = [0., 49.452, 95.393, 127.587, 190.408]
    >>> rv = [38.77, 39.70, 37.45, 38.31, 38.31] * u.km/u.s
    >>> err = [0.184, 0.261, 0.112, 0.155, 0.223] * u.km/u.s
{'fraction_non_alphanumeric': 0.13719974031594892, 'fraction_numerical': 0.031594892880328934, 'mean_word_length': 3.9380341880341883, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 35, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2042469', 'n_tokens_mistral': 1536, 'n_tokens_neox': 1324, 'n_words': 496}