Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix a few typos in example usage #76

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 7 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -83,8 +83,9 @@ print(gr)
A common representation in Python is a pandas `DataFrame` for all tabular datasets. `DataFrame` must contain columns "seqnames", "starts", and "ends" to represent genomic intervals. Here's an example:

```python
import genomicranges import GenomicRanges
from genomicranges import GenomicRanges
import pandas as pd
from random import random

df = pd.DataFrame(
{
Expand Down Expand Up @@ -118,7 +119,7 @@ print(gr)
`GenomicRanges` supports most [interval based operations](https://bioconductor.org/packages/release/bioc/html/GenomicRanges.html).

```python
subject = genomicranges.from_ucsc(genome="hg38")
subject = genomicranges.read_ucsc(genome="hg38")

query = genomicranges.from_pandas(
pd.DataFrame(
Expand Down Expand Up @@ -146,6 +147,10 @@ Just as it sounds, a `GenomicRangesList` is a named-list like object. If you are
To construct a GenomicRangesList

```python
from genomicranges import GenomicRanges, GenomicRangesList
from iranges import IRanges
from biocframe import BiocFrame

gr1 = GenomicRanges(
seqnames=["chr1", "chr2", "chr1", "chr3"],
ranges=IRanges([1, 3, 2, 4], [10, 30, 50, 60]),
Expand Down
1 change: 1 addition & 0 deletions docs/tutorial.md
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,7 @@ gr = GenomicRanges(
The package also provides a `SeqInfo` class to update or modify sequence information stored in the object. Read more about this class in [GenomeInfoDb package](https://bioconductor.org/packages/release/bioc/html/GenomeInfoDb.html).

```python
from genomicranges import SeqInfo
seq_obj = {
"seqnames": ["chr1", "chr2", "chr3",],
"seqlengths": range(100, 103),
Expand Down
Loading