def sumSeriesWithWildcards(requestContext, seriesList, *positions):
    newSeries = {}
    newNames = list()

    for series in seriesList:
        newname = '.'.join(map(lambda x: x[1],
                               filter(lambda i: i[0] not in positions,
                                      enumerate(series.name.split('.')))))
        if newname in newSeries:
            newSeries[newname] = sumSeries(requestContext,
                                           (series, newSeries[newname]))[0]
        else:
            newSeries[newname] = series
            newNames.append(newname)
        newSeries[newname].name = newname

    return [newSeries[name] for name in newNames]
Call sumSeries after inserting wildcards at the given position(s).
dataset/ETHPy150Open brutasse/graphite-api/graphite_api/functions.py/sumSeriesWithWildcards