def setThresh(fluxcomponent, thresh, fluxstring='f880'):

    """

    Filter out targets in fluxcomponent below a given `thresh` flux density.

    """

    if fluxstring == 'peakflux':
        thresh /= 1e3
    fluxhigh = fluxcomponent[fluxstring] > thresh
    fluxcomponent = fluxcomponent[fluxhigh]

    return fluxcomponent