The spread of plasmids as a function of bacterial adaptability