We undertake a systematic analysis of the early (<0.5 Myr) evolution of clustering and the stellar initial mass function (IMF) in turbulent fragmentation simulations. These large-scale simulations produce up to thousands of stars in clusters that can individually contain up to several hundred stars, and thus for the first time offer the opportunity for a statistical analysis of IMF variations and correlations between stellar properties and cluster richness. The typical evolutionary scenario involves star formation in relatively small-n clusters which then progressively merge; the first stars to form are seeds of massive stars and achieve a head start in mass acquisition. These massive seeds end up in the cores of clusters and a large fraction of new stars of lower mass is formed in the outer parts of the clusters. The resulting clusters are therefore mass segregated at an age of 0.5 Myr, although the signature of mass segregation is weakened during mergers. We find that the resulting IMF has a smaller exponent (α= 1.8–2.2) than the Salpeter value (α= 2.35). The IMFs in subclusters are truncated at masses only somewhat larger than the most massive stars (which depends on the richness of the cluster) and an universal upper mass limit of 150 M⊙ is ruled out. We also find that the simulations show signs of the integrated galactic IMF effect proposed by Weidner & Kroupa, where the frequency of massive stars is suppressed in the integrated IMF compared to the IMF in individual clusters. We identify clusters in the simulations through the use of a minimum spanning tree algorithm which is readily applied to observational data and which allows easy comparison between such survey data and the predictions of turbulent fragmentation models. In particular, we present quantitative predictions regarding properties such as cluster morphology, degree of mass segregation, upper slope of the IMF and the relation between cluster richness and maximum stellar mass.