A researcher studying a species of wild flower (Bidens tripartita) counts the number of spines on the leaves of 100 plants from a dry, open habitat and 100 plants from a shaded, moist habitat. The number of spines per leaf ranges from 0 to 12, with most leaves having between 2 and 8 spines. The researcher also records that the flowers of this species are either purple or white; no intermediate shades are observed. When seeds from both habitats are grown in a common garden, the spine number still varies but the range is narrower, while flower colour remains either purple or white regardless of growing conditions.
With reference to the two traits described, describe discontinuous and continuous variation, and explain the genetic basis of each type.