  In General Relativity approximations based on the spherical collapse model
such as Press--Schechter theory and its extensions are able to predict the
number of objects of a certain mass in a given volume. In this paper we use a
machine learning algorithm to test whether such approximations hold in screened
modified gravity theories. To this end, we train random forest classifiers on
data from N-body simulations to study the formation of structures in
$\Lambda$CDM as well as screened modified gravity theories, in particular
$f(R)$ and nDGP gravity. The models are taught to distinguish structure
membership in the final conditions from spherical aggregations of density field
behaviour in the initial conditions. We examine the differences between machine
learning models that have learned structure formation from each gravity, as
well as the model that has learned from $\Lambda$CDM. We also test the
generalisability of the $\Lambda$CDM model on data from $f(R)$ and nDGP
gravities of varying strengths, and therefore the generalisability of
Extended-Press-Schechter spherical collapse to these types of modified gravity.
