Consider a set of correlated sources located at the nodes of a network, and a sink to which the data from all the sources has to arrive. We address the minimization of a separable joint communication cost function given by the product [rate] $\times$ [edge weight]. We consider the data gathering scenario, which is relevant in sensor networks. We present two possible approaches for rate allocation, namely Slepian-Wolf coding, and coding by explicit communication. We compare asymptotically (dense networks) the total costs associated with Slepian-Wolf coding and explicit communication, by finding their corresponding scaling laws and analyzing the ratio of their respective costs. We also provide the specific conditions on the correlation structure which determine the different cases of asymptotic behaviors.