by¶ Run a supported command separately within each group. When to use How do I repeat an analysis by subgroup? Syntax¶ by groupvars: command Examples¶ by sex: summarize age by firm_id year: count See also¶ Command Reference Index User Guide In-App Help System