Heliophysics Application Programmer’s Interface

From SPEDAS Wiki
Revision as of 17:20, 21 May 2018 by Egrimes (talk | contribs)
Jump to navigation Jump to search

SPEDAS provides easy access to data on servers which implement the Heliophysics Application Programmer’s Interface via the command-line routine: hapi_load_data.

Command-line

Keywords

server (required): specify the HAPI server to connect to

capabilities: list the server capabilities

catalog: list the datasets available on the server

info: return information on a dataset

trange: two element array specifying the time range for the dataset you would like to download

parameters: restrict the parameters in the dataset to just those requested in this keyword


Examples

To list a server's capabilities:

<syntaxhighlight lang="idl"> IDL> hapi_load_data, /capabilities, server='http://datashop.elasticbeanstalk.com/hapi' </syntaxhighlight>


To list the datasets available on this server:

<syntaxhighlight lang="idl"> IDL> hapi_load_data, /catalog, server='http://datashop.elasticbeanstalk.com/hapi' </syntaxhighlight>


To get informaton on a dataset:

<syntaxhighlight lang="idl"> IDL> hapi_load_data, /info, dataset='spase://VEPO/NumericalData/Voyager1/LECP/Flux.Proton.PT1H', server='http://datashop.elasticbeanstalk.com/hapi' </syntaxhighlight>


Load and plot some Voyager 1 proton flux data:

<syntaxhighlight lang="idl"> IDL> hapi_load_data, trange=['77-09-27', '78-01-20'], dataset='spase://VEPO/NumericalData/Voyager1/LECP/Flux.Proton.PT1H', server='http://datashop.elasticbeanstalk.com/hapi' IDL> tplot, 'flux' </syntaxhighlight>

SPEDAS GUI

In addition to the command-line access to HAPI servers, the SPEDAS GUI allows users to load data from HAPI servers with an easy to use GUI interface.