cdasws Example IDL Jupyter Notebook

This Jupyter notebook demonstates using the cdasws IDL library to access data from cdaweb in the IDL programming language.

Note: This notebook is for the IDL version of cdasws. Jupyter notebooks for the Python version of cdasws is available at python cdasws notebooks.

Installation

The following contains the procedure to install the cdasws IDL library into your IDL environment. There are different procedures for different versions of IDL.

IDL 8.7.1 and higher

If you have an old version of the SPDF_CDAS package already installed, remove the old version.

If the lastest version of the SPDF_CDAS package is not already installed, install it as shown below.

You only need to install a particular version of the package once. You will need to restore the package everytime you restart your IDL session. Restore the package as shown below.

IDL 8.4.0 and newer

Download spdfcdas.sav. You will need to restore the package everytime you restart your IDL session. Restore the package as shown below.

Setup

Create an SpdfCdas object.

Get Observatory Groups

The following code demonstrates how to get the mission/observatory groups supported by cdaweb.

Get Intrument Types

The following code demonstrates how to get the intrument types supported by cdaweb.

Get Datasets

The following code demonstrates how to find the datasets for a specific observatory group and instrument type.

Get Inventory

The following code demonstrates getting the available data inventory.

Get Variable Names

The following code demonstrates how to a dataset's variable names.

Get Data Example

The following code demonstrates how to access magnetic field measurements from the ACE mission dataset.

Use the standard IDL PLOT procedure to display the data.

Print the values.

Use the cdawlib plotmaster function to plot the data.

Binning Example

For analysis, it is often useful to place two datasets that have different timestamps on the same time grid (with optional spike removal). The following demonstrates doing this with cdasws and the datasets AC_H0_SWE and AC_H2_SWE. For more information on binning, see binning in cdaweb.

Display Original Data

Get and display the data.

Bin Data

Bin the data with 60 second interval and interpolate any missing values.

Compare Data

Compare the binned data from the two datasets.

DOI Example

The following demonstrates the use of a dataset's Digital Object Identifier (DOI).

Additional Documentation

View the cdasws API for additional functions.