Since version 5.8, the selection does not directly affect the visibility. This is affected by the _atom_visible datablock. A new command, Select_visible, will create this from the _atom_select datablock. For example, to generate an object of all phenylalanine residues in the protein:
sel_off ;;
sel_prop res_type =3D phe on
sel_visible
obj phe zone ; end
This visibility will haunt you until you reset it:
sel_on ;; sel_visible