code: def slice_by_component( self, component_index, start, end ):
          
          if type( component_index ) == type( 0 ):
              ref = self.components[ component_index ]
          elif type( component_index ) == type( "" ):
              ref = self.get_component_by_src( component_index )
          elif type( component_index ) == Component:
              ref = component_index
          else:
              raise ValueError( "can't figure out what to do" )
          start_col = ref.coord_to_col( start )
          end_col = ref.coord_to_col( end )
          if (ref.strand == '-'):
              (start_col,end_col) = (end_col,start_col)
          return self.slice( start_col, end_col )
docs: Return a slice of the alignment, corresponding to an coordinate interval in a specific component.
  
          component_index is one of
              an integer offset into the components list
              a string indicating the src of the desired component
              a component
  
          start and end are relative to the + strand, regardless of the component's strand.