Quickstart

Installation

If you are using Anaconda or Miniconda:

conda install -c conda-forge xrviz

If you are using virtualenv/pip:

pip install xrviz

Note that this will install with the mininum of optional requirements. If you want a more complete install, use conda instead.

If you want to develop:

git clone https://github.com/intake/xrviz
cd xrviz
pip install -e .

Example

To open a local or remote data in the interface:

import xarray as xr
from xrviz.dashboard import Dashboard

# open data with xarray
data = xr.tutorial.open_dataset('air_temperature')

# or open remote data with xarray
url = 'http://opendap.co-ops.nos.noaa.gov/thredds/dodsC/NOAA/LOOFS/MODELS/201907/glofs.loofs.fields.forecast.20190720.t06z.nc'
data = xr.open_dataset(url)

# pass the data to Dashboard
dash = Dashboard(data)
dash.show()

Note that dash.show() will open a new tab in browser, while dash.panel is applicable only for a jupyter cell.

You can view the example dashboard by running following in command line (this will open a tab in your browser):

python -c "import xrviz; xrviz.example()"

The above line will initialise the interface, which looks as follows:

https://aws-uswest2-binder.pangeo.io/badge_logo.svg

Overview

The user input section of the interface constitutes of five sub-sections composed of Panel widgets. These sub-sections have been arranged in tabs, each of which has been described in detail in the following sections:

  1. Variables

  2. Set_Coords

  3. Axes

  4. Style

  5. Projection

The user can interact with the widgets present in these panes to select desired inputs. Together, they govern the output produced upon pressing the Plot button.