In this example, we read a protein from a PDB file and then add a layer of atom::Fragments below the chain.
   14 hchain = IMP.atom.get_by_type(ep, IMP.atom.CHAIN_TYPE)[0]
 
   16 children = hchain.get_children()
 
   23                                        for x 
in children[:10]])
 
   24 for c 
in children[:10]:
 
   25     hchain.remove_child(c)
 
   30                                        for x 
in children[10:20]])
 
   31 for c 
in children[10:20]:
 
   32     hchain.remove_child(c)
 
   36 for c 
in children[20:]:
 
   37     hchain.remove_child(c)