Skip to content

Commit

Permalink
Update documentation for get_seq which uses 1-based closed intervals
Browse files Browse the repository at this point in the history
  • Loading branch information
eroller authored Jul 31, 2024
1 parent 1075c8e commit 2ab2a6a
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions pyfaidx/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -1134,9 +1134,9 @@ def __len__(self):
return sum(len(record) for record in self)

def get_seq(self, name, start, end, rc=False):
"""Return a sequence by record name and interval [start, end).
"""Return a sequence by record name and interval [start, end].
Coordinates are 1-based, end-exclusive.
Coordinates are 1-based, closed interval.
If rc is set, reverse complement will be returned.
"""
# Get sequence from real genome object and save result.
Expand Down Expand Up @@ -1245,9 +1245,9 @@ def __repr__(self):
str(self.gt_type))

def get_seq(self, name, start, end):
"""Return a sequence by record name and interval [start, end).
"""Return a sequence by record name and interval [start, end].
Replace positions with polymorphism with variant.
Coordinates are 0-based, end-exclusive.
Coordinates are 1-based, closed interval.
"""
seq = self.faidx.fetch(name, start, end)
if self.faidx.as_raw:
Expand Down

0 comments on commit 2ab2a6a

Please sign in to comment.