Skip to content

Commit

Permalink
Replace more single quotes
Browse files Browse the repository at this point in the history
  • Loading branch information
cbrnr committed Jul 21, 2022
1 parent 07d2988 commit 332441e
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions doc/source/datasets.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,27 +34,27 @@ The code below shows how to read all records in the [MESA](https://sleepdata.org
```python
from sleepecg import read_mesa, set_nsrr_token

set_nsrr_token('<your-download-token-here>')
set_nsrr_token("<your-download-token-here>")
mesa = read_mesa() # note that this is a generator
```

You can also select a subset of records from a dataset. This example will download and read all records having IDs starting with `00` (i.e. records `0001`-`0099`):
```python
from sleepecg import read_mesa, set_nsrr_token

set_nsrr_token('<your-download-token-here>')
mesa = read_mesa(records_pattern='00*') # note that this is a generator
set_nsrr_token("<your-download-token-here>")
mesa = read_mesa(records_pattern="00*") # note that this is a generator
```

If you just want to download NSRR data (like with the [NSRR Ruby Gem](https://github.com/nsrr/nsrr-gem)), use the workflow below. The example downloads all files within [`mesa/polysomnography/edfs`](https://sleepdata.org/datasets/mesa/files/polysomnography/edfs) matching `*-00*` to a local folder `./datasets` (subfolders are created to preserve the dataset's directory structure).
```python
from sleepecg import download_nsrr, set_nsrr_token

set_nsrr_token('<your-download-token-here>')
set_nsrr_token("<your-download-token-here>")
download_nsrr(
db_slug='mesa',
subfolder='polysomnography/edfs',
pattern='*-00*',
data_dir='./datasets',
db_slug="mesa",
subfolder="polysomnography/edfs",
pattern="*-00*",
data_dir="./datasets",
)
```

0 comments on commit 332441e

Please sign in to comment.