extract removes the atom selection from an object and creates it as its own object. This allows one to gain independent control over atoms in a scene by extracting them from the original object. For example, one can extract the hetero-atoms to their own object for independent manipulation.
extract name, selection [, source_state [, target_state ]]
# create the new hets object from all the hetero-atoms. extract hets, het
cmd.extract(name, selection, source_state, target_state)