Alter weighted mean for modularity.