def plot_profile_comparison(ax, cast, model_d_interp, var_name,
                            var_lims, depth_lims):
    """Plot cast depth profile comparison between model and observations

    :arg ax: axis for plotting
    :type ax: axis object

    :arg cast: the observed cast for comaprison
    :type cast: pandas DataFrame-like object

    :arg model_d_interp: model values interpolated to observed depths
    :type model_d_interp: numpy array

    :arg var_name: observed variable name,
    eg 'Practical Salinity Corrected (psu)'
    :type var_name: string

    :arg var_lims: min/max variable values, eg [29,34]
    :type var_lims: 2-tuple

    :arg depth_lims: min/max depth values, eg [0,150]
    :type depth_lims: 2-tuple

    :returns: lo, lm - scatter plot handles for observations and model.
    Can be used for adding a legend later.
    """

    lo = ax.scatter(cast[var_name], cast['Depth Corrected (m)'],
                    c='g', label='Observed')
    lm = ax.scatter(model_d_interp, cast['Depth Corrected (m)'],
                    c='b', label='Modelled')

    ax.set_ylim([depth_lims[-1], depth_lims[0]])
    ax.set_ylabel('Depth [m]')

    ax.set_xlim(var_lims)
    ax.set_xlabel(var_name)

    ax.set_title(cast.day.min().strftime('%Y-%m-%d'))

    return lo, lm