def weighted_mean(dataset1, dataset2,
                  weight1=1., weight2=5.):
    """Calculate a weighted mean of data items.
    """
    weighted_mean = ((weight1 * dataset1
                      + weight2 * dataset2)
                     / (weight1 + weight2))
    return weighted_mean