def metricresample(metric, samples):

    """
    Resample a metric vector using random resamples computed using
    indexresample.

    Parameters:
    - - - - -
        metric: array of scalar values describing mesh
        samples: indices to sample from
    """

    resamples = metric[samples]

    return resamples