For many years the adaptive significance of most secondary metabolites was unknown.
These compounds were thought to be simply functionless end products of metabolism, or metabolic wastes.
Today we know that many secondary metabolites have important ecological functions in plants: