Family Law Practice blog has a good overview of the concept in his Best Interests of the Child
Certainly, an older child’s wishes will be given more weight than a younger child. What is the nature of the relationship with the child and the custodial parent? The noncustodial parent? The court will also look at the present home environment and whether the child is prospering within that environment.This fits very well with the Indiana Code's description of what is to go into a determination of best interests:
Is the child adjusting well in school, getting along with other children, keeping his/her grades up?
Are there any significant issues with respect to the ability of a parent to care for the child? Is there evidence, for example, of drugs/alcohol that could impede the child’s growth?
The court does not take any of these issues lightly. Indeed the decision to either remove a child from one parent or to award custody to the other is, arguably, one of the most important, most difficult, and most emotionally charged decisions that a court can make.
Sec. 8. The court shall determine custody and enter a custody order in accordance with the best interests of the child. In determining the best interests of the child, there is no presumption favoring either parent. The court shall consider all relevant factors, including the following:
(1) The age and sex of the child.
(2) The wishes of the child's parent or parents.
(3) The wishes of the child, with more consideration given to the child's wishes if the child is at least fourteen (14) years of age.
(4) The interaction and interrelationship of the child with:
(A) the child's parent or parents;(5) The child's adjustment to the child's:
(B) the child's sibling; and
(C) any other person who may significantly affect the child's best interests.
(A) home;(6) The mental and physical health of all individuals involved.
(B) school; and
(7) Evidence of a pattern of domestic or family violence by either parent.
(8) Evidence that the child has been cared for by a de facto custodian, and if the evidence is sufficient, the court shall consider the factors described in section 8.5(b) of this chapter.