In ABA, the goal of decreasing a behavior is not simply to be rid of it because it is undesirable, but rather to develop a more appropriate response to replace it. When any behavior, appropriate or inappropriate, remains in an individual's repertoire it is there for a reason. That is, it serves some specific purpose that is valued by the learner. If the behavior did not hold this value, it would not continue to occur. In ABA, developing an understanding of why an individual does what they do involves looking for connections between their behavior and the environment. When a behavior consistently results in a particular outcome from the environment a functional relationship between the two is formed. When that outcome is highly valued, the behavior that achieved it will increase and become more intentional. Eventually, producing the desired outcome becomes the function of the behavior or otherwise stated - the reason it occurs. Developing some understanding of why a behavior occurs is what drives the selection of the ABA procedures that will be used to decrease or eliminate it.
Excerpt from Autism and ABA: A "How-To" Handbook for Teachers