Yellow letter is not mandatory....
USCIS doesn't send YL to all the applicants....Usually they send to those who had issues like arrests/citation/traffic tickets etc....
Basically, in N-400, Part# 10 (Good Moral Character), if you answered 'yes' to any of the question, you may get an Yellow letter from USCIS.
Also, note that not everyone who answer 'yes' to these questions get YL....