Skip to main content

Package for SPEDAS data loading modules

Project description

pyspedas

Load data from SPEDAS CDF files into pytplot.

Pyspedas is a python package that contains data loading modules for various scientific NASA missions.

The load routines are designed to work with the libraries cdflib, pytplot.

How It Works

CDF files are downloaded from the internet to the local machine. Local data directory is specified in the file spd_prefs_txt.py.

Install Python

You will need the Anaconda distribution of Python 3 in order to run pyspedas.

Anaconda comes with a suite of packages that are useful for data science.

You should also install git which makes installation of python packages easier.

Install pyspedas

To install pyspedas, use the command:

pip install git+https://github.com/nickssl/pyspedas

Running pyspedas

After installation, please change the file pyspedas\spd_prefs_txt.py and set data_dir=C:\Datapy\themis to a directory of your choice.

To download CDF files for the Themis mission, use:

pyspedas.load_data(mission, dates, probes, instruments, level, downloadonly)

Example:

d = pyspedas.load_data('themis', '2015-12-31', ['tha'], '*', 'l2', False)

Parameters:

  • mission = 'themis' the name of the mission, currently only 'themis' is available
  • dates = '2015-12-31' list of dates to be downloaded
  • probes = ['tha', 'tha'] list of probes ['tha', 'tha', 'thc', 'thd', 'the'], wildcard ('*') for all probes
  • instruments = ['fft'] list of instruments, wildcard ('*') for all instruments
  • level = 'l2' either 'l2' or 'l1'
  • downloadonly = True if True then CDF files are downloaded only, if False then they are also loaded into pytplot using pytplot.cdf_to_tplot

List of possible values for L2 themis "instruments" variable:

['efi', 'esa', 'fbk', 'fft', 'fgm', 'fit', 'gmom', 'mom', 'scm', 'sst']

List of possible values for L1 themis "instruments" variable:

['bau', 'eff', 'efp', 'efw', 'esa', 'fbk', 'fff_16', 'fff_32', 'fff_64', 'ffp_16', 'ffp_32', 'ffp_64', 'ffw_16', 'ffw_32', 'ffw_64', 'fgm', 'fit', 'hsk', 'mom', 'scf', 'scm', 'scmode', 'scp', 'scw', 'spin', 'sst', 'state', 'trg', 'vaf', 'vap', 'vaw']

Additional Information

For pytplot, see: https://github.com/MAVENSDC/PyTplot

For cdflib, see: https://github.com/MAVENSDC/cdflib

For SPEDAS, see http://spedas.org/blog/

For information on the Themis mission, see http://themis.ssl.berkeley.edu/

Project details


Release history Release notifications | RSS feed

This version

0.2.3

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pyspedas-0.2.3.tar.gz (6.0 kB view hashes)

Uploaded Source

Built Distribution

pyspedas-0.2.3-py2.py3-none-any.whl (2.3 kB view hashes)

Uploaded Python 2 Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page