I would spell out argument names for more informative signatures

pvalues, weights