Documentation

All docstrings!

HorizonsAPI.HorizonsAPIModule

Interact with the JPL Horizons REST API.

Extended Help

License

MIT License

Copyright (c) 2023 Joe Carpinelli

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

Exports

Imports

  • Base
  • Core
  • DocStringExtensions
source
HorizonsAPI.fetch_approachMethod
fetch_approach(
    COMMAND;
    file,
    CALIM_PL,
    CALIM_SB,
    CA_TABLE_TYPE,
    EMAIL_ADDR,
    TCA3SG_LIMIT,
    format
)

Fetch planetary ephemeris for the body specified by COMMAND, in the EPHEM_TYPE="APPROACH" format.

source
HorizonsAPI.fetch_elementsMethod
fetch_elements(
    COMMAND;
    file,
    A,
    EC,
    ECLIP,
    EMAIL_ADDR,
    EPOCH,
    IN,
    MA,
    N,
    OBJECT,
    OM,
    QR,
    TP,
    W,
    format
)

Fetch planetary ephemeris for the body specified by COMMAND, in the EPHEM_TYPE="ELEMENTS" format.

source
HorizonsAPI.fetch_observerMethod
fetch_observer(
    COMMAND;
    file,
    AIRMASS,
    ANG_FORMAT,
    ANG_RATE_CUTOFF,
    APPARENT,
    CAL_FORMAT,
    CAL_TYPE,
    CENTER,
    COORD_TYPE,
    CSV_FORMAT,
    ELEV_CUT,
    ELM_LABELS,
    EMAIL_ADDR,
    EXTRA_PREC,
    LHA_CUTOFF,
    OUT_UNITS,
    QUANTITIES,
    RANGE_UNITS,
    REF_PLANE,
    REF_SYSTEM,
    R_T_S_ONLY,
    SITE_COORD,
    SKIP_DAYLT,
    SOLAR_ELONG,
    START_TIME,
    STEP_SIZE,
    STOP_TIME,
    SUPPRESS_RANGE_RATE,
    TIME_DIGITS,
    TIME_ZONE,
    TLIST,
    TLIST_TYPE,
    TP_TYPE,
    VEC_CORR,
    VEC_DELTA_T,
    VEC_LABELS,
    VEC_TABLE,
    format
)

Fetch planetary ephemeris for the body specified by COMMAND, in the EPHEM_TYPE="OBSERVER" format.

source
HorizonsAPI.fetch_spkMethod
fetch_spk(
    COMMAND;
    file,
    EMAIL_ADDR,
    START_TIME,
    STOP_TIME,
    format
)

Fetch planetary ephemeris for the body specified by COMMAND, in the EPHEM_TYPE="SPK" format.

source
HorizonsAPI.fetch_vectorsMethod
fetch_vectors(
    COMMAND;
    file,
    AIRMASS,
    ANG_FORMAT,
    ANG_RATE_CUTOFF,
    APPARENT,
    CAL_FORMAT,
    CAL_TYPE,
    CENTER,
    COORD_TYPE,
    CSV_FORMAT,
    ELEV_CUT,
    ELM_LABELS,
    EMAIL_ADDR,
    EXTRA_PREC,
    LHA_CUTOFF,
    OUT_UNITS,
    QUANTITIES,
    RANGE_UNITS,
    REF_PLANE,
    REF_SYSTEM,
    R_T_S_ONLY,
    SITE_COORD,
    SKIP_DAYLT,
    SOLAR_ELONG,
    START_TIME,
    STEP_SIZE,
    STOP_TIME,
    SUPPRESS_RANGE_RATE,
    TIME_DIGITS,
    TIME_ZONE,
    TLIST,
    TLIST_TYPE,
    TP_TYPE,
    VEC_CORR,
    VEC_DELTA_T,
    VEC_LABELS,
    VEC_TABLE,
    format
)

Fetch planetary ephemeris for the body specified by COMMAND, in the EPHEM_TYPE="VECTORS" format.

source
HorizonsAPI.queryMethod
query(COMMAND; options...)

Given keyword arguments which map to Horizons API parameters, construct a Vector{Pair} that is compatible with the query keyword argument of HTTP.get.

source
HorizonsAPI.requestMethod
request(
    COMMAND;
    file,
    A,
    AIRMASS,
    ANG_FORMAT,
    ANG_RATE_CUTOFF,
    APPARENT,
    CALIM_PL,
    CALIM_SB,
    CAL_FORMAT,
    CAL_TYPE,
    CA_TABLE_TYPE,
    CENTER,
    COORD_TYPE,
    CSV_FORMAT,
    EC,
    ECLIP,
    ELEV_CUT,
    ELM_LABELS,
    EMAIL_ADDR,
    EPHEM_TYPE,
    EPOCH,
    EXTRA_PREC,
    IN,
    LHA_CUTOFF,
    MA,
    MAKE_EPHEM,
    N,
    OBJECT,
    OBJ_DATA,
    OM,
    OUT_UNITS,
    QR,
    QUANTITIES,
    RANGE_UNITS,
    REF_PLANE,
    REF_SYSTEM,
    R_T_S_ONLY,
    SITE_COORD,
    SKIP_DAYLT,
    SOLAR_ELONG,
    START_TIME,
    STEP_SIZE,
    STOP_TIME,
    SUPPRESS_RANGE_RATE,
    TCA3SG_LIMIT,
    TIME_DIGITS,
    TIME_ZONE,
    TLIST,
    TLIST_TYPE,
    TP,
    TP_TYPE,
    VEC_CORR,
    VEC_DELTA_T,
    VEC_LABELS,
    VEC_TABLE,
    W,
    format
)

Return the requested Horizons data in the form of an HTTP.Response.

source
HorizonsAPI.to_kwargsMethod
to_kwargs(parameters)

Return a sequence of Expr objects which represent a NamedTuple with a format that is compatible with keyword arguments in function definitions.

Extended Help

References:

  • https://discourse.julialang.org/t/unpack-namedtuple-into-a-function-definition/97500/2
source
HorizonsAPI.urlifyMethod
urlify(x)

The Horizons API accepts very specific formatting for some strings. For example, setting the format option to "text" is fine, but "'text'" will cause the server to throw an error. Each method of urlify takes in a single argument, and outputs a string.

The one exception here is the method which takes an argument of type Missing; that method simply returns the singleton value missing to the option to be filtered out before the query is sent.

source