Recent studies emphasize that an empirical relation between the stellar mass
of galaxies and the mass of their host dark matter subhaloes can predict the
clustering of galaxies and its evolution with cosmic time. In this paper we
study the assumptions made by this methodology using a semi-analytical model
(SAM). To this end, we randomly swap between the locations of model galaxies
within a narrow range of subhalo mass (M_infall). We find that shuffled samples
of galaxies have different auto-correlation functions in comparison with the
original model galaxies. This difference is significant even if central and
satellite galaxies are allowed to follow a different relation between M_infall
and stellar mass, and can reach a factor of 2 for massive galaxies at redshift
zero. We analyze three features within SAMs that contribute to this effect: a)
The relation between stellar mass and subhalo mass evolves with redshift for
central galaxies, affecting satellite galaxies at the time of infall. b) The
stellar mass of galaxies falling into groups and clusters at high redshift is
different from the mass of central galaxies at the same time. c) The stellar
mass growth for satellite galaxies after infall can be significant and depends
on the infall redshift and the group mass. We show that the above is true for
differing SAMs, and that the effect is sensitive to the treatment of dynamical
friction and stripping of gas in satellite galaxies. We find that by using the
FoF group mass at redshift zero in addition to M_infall, an empirical model is
able to accurately reproduce the clustering properties of galaxies. On the
other hand, using the infall redshift as a second parameter does not yield as
good results because it is less correlated with stellar mass. Our analysis
indicates that environmental processes are important for modeling the
clustering and abundance of galaxies. (Abridged)Comment: Accepted for publication in MNRAS, minor changes from version