Step 1: Go to Contacts Tab
Step 2: Select Groups
Step 3: Use All, Online and Hide All to select the desired view for each group.
Step 4: Online will show the contacts who are online within that group.
Step 5: Hide All will collapse all the contacts within that group.
Step 6: You can have multiple Groups and can customize the views per Group.