In [2]:
import iris
iris.FUTURE.netcdf_promote = True
print(iris.__version__)

import os.path

os.path.abspath(iris.__file__)


1.7.2-DEV
Out[2]:
'/home/usgs/anaconda/lib/python2.7/site-packages/iris/__init__.pyc'

In [3]:
%load_ext pymatbridge


The pymatbridge extension is already loaded. To reload it, use:
  %reload_ext pymatbridge

In [ ]:
import iris.plot as iplt
import matplotlib.pyplot as plt


def plot_profile(c):
    coord = c.coord('sea_surface_height_above_reference_ellipsoid')
    lon = c.coord(axis='X').points.squeeze()
    lat = c.coord(axis='Y').points.squeeze()
    depth = coord.points.min()
    
    fig, ax = plt.subplots(figsize=(5, 6))
    kw = dict(linewidth=2,  color=(.3, .4, .5),
              alpha=0.75, marker='o', label='iris')
    iplt.plot(c, coord, **kw)
    ax.grid()
    ax.set_ylabel('{} ({})'.format(coord.standard_name, coord.units))
    ax.set_xlabel('{} ({})'.format(c.name(), c.units))
    ax.set_title('lon: %s\nlat: %s\nMax depth = %s' % (lon, lat, depth))
    return fig, ax

In [6]:
a=2

In [10]:
%%matlab -i a -o b
b=a^3;

In [11]:
print b


8

In [5]:
2^3


Out[5]:
1

In [ ]: