Yes, leg squeezing behavior is sometimes linked to potty training. Toddlers may squeeze their legs together as a way to hold in urine or stool, especially if they are feeling anxious about using the toilet.