CloneSet373


Previous CloneSetNext CloneSetBack to Main Report
Clone
Mass
Clones in
CloneSet
Parameter
Count
Clone
Similarity
Syntax Category
[Sequence Length]
10220.978compound_stmt
Clone AbstractionParameter Bindings
Clone Instance
(Click to see clone)
Line CountSource Line
Source File
110131
Bio/Seq.py
2101191
Bio/Seq.py
Clone Instance
1
Line Count
10
Source Line
131
Source File
Bio/Seq.py

    def __getitem__(self,index):                   # Seq API requirement
        #Note since Python 2.0, __getslice__ is deprecated
        #and __getitem__ is used instead.
        #See http://docs.python.org/ref/sequence-methods.html
        if isinstance(index,int):  
            #Return a single letter as a string
            return self._data[index] 
        else: 
            #Return the (sub)sequence as another Seq object
            return Seq(self._data[index],self.alphabet) 
        


Clone Instance
2
Line Count
10
Source Line
1191
Source File
Bio/Seq.py

    def __getitem__(self,index):  
        #Note since Python 2.0, __getslice__ is deprecated
        #and __getitem__ is used instead.
        #See http://docs.python.org/ref/sequence-methods.html
        if isinstance(index,int):  
            #Return a single letter as a string
            return self.data[index] 
        else: 
            #Return the (sub)sequence as another Seq object
            return MutableSeq(self.data[index],self.alphabet) 
        


Clone AbstractionParameter Count: 2Parameter Bindings

def __getitem__(self,index): # Seq API requirement
  #Note since Python 2.0, __getslice__ is deprecated
  #and __getitem__ is used instead.
  #See http://docs.python.org/ref/sequence-methods.html
  if isinstance(index,int):
  
    #Return a single letter as a string
    return self. [[#variable6016fda0]][index] 
  else:
  
    #Return the (sub)sequence as another Seq object
    return [[#variable6016fd00]](self. [[#variable6016fda0]][index],self.alphabet) 
  
 

CloneAbstraction
Parameter Bindings
Parameter
Index
Clone
Instance
Parameter
Name
Value
11[[#6016fda0]]
data 
12[[#6016fda0]]
_data 
21[[#6016fd00]]
MutableSeq 
22[[#6016fd00]]
Seq