We develop a simple model for computing planetary formation based on the core instability model for the gas accretion and the oligarchic growth regime for the accretion of the solid core. In this model several planets can form simultaneously in the disc, a fact that has important implications especially for the changes in the dynamic of the planetesimals and the growth of the cores since we consider the collision between them as a source of potential growth. The type I and type II migration of the embryos and the migration of the planetesimals due to the interaction with the disc of gas are also taken into account. With this model we consider different initial conditions to generate a variety of planetary systems and analyse them statistically. We explore the effects of using different type I migration rates on the final number of planets formed per planetary system such as on the distribution of masses and semimajor axis of extrasolar planets, where we also analyse the implications of considering different gas accretion rates. A particularly interesting result is the generation of a larger population of habitable planets when the gas accretion rate and type I migration are slower.