The onset of natural convection from time-dependent profiles