Skip to content

Commit bdc790a

Browse files
committed
fix docs: add conda install, fix typos, update deps
1 parent a358e39 commit bdc790a

File tree

4 files changed

+41
-39
lines changed

4 files changed

+41
-39
lines changed

README.md

Lines changed: 29 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -7,27 +7,26 @@ Given a pangenome (in [PanMAN](https://github.com/TurakhiaLab/panman) format) an
77
### Modes
88

99
- **Single-sample** (default): Places reads from a single sample, aligns to the best-matching reference, and genotypes variants (BAM + VCF output).
10-
- **Metagenomic** (`--meta`): Scores reads from a mixture sample against every node in the PanMAN, and uses the scoring informtion to estimate haplotype abundance or directly assign reads to nodes.
10+
- **Metagenomic** (`--meta`): Scores reads from a mixture sample against every node in the PanMAN, and uses the scoring information to estimate haplotype abundance or directly assign reads to nodes.
1111

1212

1313

14-
### Installation with Docker (recommended)
14+
### Installation
1515

16-
**Docker build**
16+
**Bioconda (recommended)**
1717

1818
```bash
19-
docker build -t panmap .
20-
docker run --rm panmap panmap -h
19+
conda install -c bioconda panmap
2120
```
2221

23-
**Docker pull**
22+
**Docker**
2423

2524
```bash
26-
docker pull alanalohaucsc/panmap:latest
25+
docker build -t panmap .
2726
docker run --rm panmap panmap -h
2827
```
2928

30-
See below for building from source.
29+
See the [documentation](https://amkram.github.io/panmap/) for building from source.
3130

3231
## Usage
3332

@@ -76,14 +75,20 @@ panmap ref.panman reads_R1.fq reads_R2.fq --stop genotype -t 8 -o sample
7675
First step is to build an index for metagenomics mode:
7776

7877
```bash
79-
make example_run && cd example_run
80-
../build/bin/panmap ../examples/data/sars_20000_twilight_dipper.panman --index-mgsr sars_20000_twilight_dipper.idx
78+
mkdir example_run && cd example_run
79+
80+
panmap ../examples/data/sars_20000_twilight_dipper.panman \
81+
--index-mgsr sars_20000_twilight_dipper.idx
8182
```
8283

8384
Then run panmap with the `--meta` option:
8485

8586
```bash
86-
../build/bin/panmap ../examples/data/sars_20000_twilight_dipper.panman ../examples/data/sars20000_5hap_0snp-a_200000_rep0_R1.fastq.gz ../examples/data/sars20000_5hap_0snp-a_200000_rep0_R2.fastq.gz --meta --index sars_20000_twilight_dipper.idx --threads 8 --em-delta-threshold 0.00001
87+
panmap ../examples/data/sars_20000_twilight_dipper.panman \
88+
../examples/data/sars20000_5hap_0snp-a_200000_rep0_R1.fastq.gz \
89+
../examples/data/sars20000_5hap_0snp-a_200000_rep0_R2.fastq.gz \
90+
--meta --index sars_20000_twilight_dipper.idx \
91+
--threads 8 --em-delta-threshold 0.00001
8792
```
8893

8994
Reads used above were simulated shotgun-sequencing reads of SARS-CoV-2 mixtures. For wastewater samples, refer to README
@@ -95,13 +100,20 @@ We first build an index for the vertebrate mitochondrial PanMAN. We recommend us
95100

96101
```bash
97102
mkdir example_run && cd example_run
98-
../build/bin/panmap ../examples/data/v_mtdna.panman --index-mgsr v_mtdna.idx -k 15 -s 8 -l 1
103+
104+
panmap ../examples/data/v_mtdna.panman \
105+
--index-mgsr v_mtdna.idx -k 15 -s 8 -l 1
99106
```
100107

101-
Then we run panmap with the `--filter-and-assign` option to filter and assign reads to the PanMAN.
108+
Then run panmap with the `--filter-and-assign` option:
102109

103110
```bash
104-
../build/bin/panmap ../examples/data/v_mtdna.panman ../examples/data/subsampled.fastq.gz --meta -i v_mtdna.idx --filter-and-assign --discard 0.6 --dust 5 --taxonomic-metadata ../examples/data/v_mtdna.meta.tsv -t 4 --breadth-ratio --output subsampled
111+
panmap ../examples/data/v_mtdna.panman \
112+
../examples/data/subsampled.fastq.gz \
113+
--meta -i v_mtdna.idx \
114+
--filter-and-assign --discard 0.6 --dust 5 \
115+
--taxonomic-metadata ../examples/data/v_mtdna.meta.tsv \
116+
-t 4 --breadth-ratio --output subsampled
105117
```
106118

107119
This outputs 3 files:
@@ -110,18 +122,8 @@ This outputs 3 files:
110122

111123
`.mgsr.assignedReads.out` file containing the number of reads assigned to each node and the indices of the reads assigned, with respect to the the `.mgsr.assignedReads.fastq` file
112124

113-
`.mgsr.assignedReadsLCANode.out` file containg the number of reads assigned to the LCA node and the indices of the reads assigned. *As reads may be assigned to multiple nodes, the LCA node of a read if the LCA of all the nodes it was assigned to.*
114-
115-
### Advanced
125+
`.mgsr.assignedReadsLCANode.out` file containing the number of reads assigned to the LCA node and the indices of the reads assigned. *As reads may be assigned to multiple nodes, the LCA node of a read is the LCA of all the nodes it was assigned to.*
116126

117-
#### Building from source:
118-
Dependencies:
127+
### Building from source
119128

120-
- `CMake >= 3.12`
121-
- `C++17 compiler`
122-
- `Protobuf (protobuf-compiler, libprotobuf-dev)`
123-
- `Boost (program_options, iostreams, filesystem, system, date_time)`
124-
- `zlib`
125-
- `Cap'n Proto (capnproto, libcapnp-dev)`
126-
- `Eigen3 (libeigen3-dev)`
127-
- `htslib 1.20`
129+
See the [installation docs](https://amkram.github.io/panmap/installation/) for dependencies and build instructions.

docs/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ panmap takes sequencing reads and a pangenome in [PanMAN](https://github.com/Tur
1616

1717
```bash
1818
# Install
19-
docker build -t panmap .
19+
conda install -c bioconda panmap
2020

2121
# Place reads (stops after placement by default)
2222
panmap ref.panman reads_R1.fq reads_R2.fq -t 8 -o sample

docs/installation.md

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,22 @@
11
# Installation
22

3-
## Docker (recommended)
3+
## Bioconda (recommended)
44

55
```bash
6-
docker build -t panmap .
6+
conda install -c bioconda panmap
77
```
88

9-
Verify:
9+
This installs `panmap` and `panmanUtils`.
10+
11+
---
12+
13+
## Docker
1014

1115
```bash
12-
docker run panmap panmap -h
16+
docker build -t panmap .
17+
docker run --rm panmap panmap -h
1318
```
1419

15-
Docker bundles all dependencies -- no manual setup required.
16-
1720
---
1821

1922
## Building from source
@@ -27,9 +30,9 @@ Docker bundles all dependencies -- no manual setup required.
2730
| Protobuf | `protobuf-compiler`, `libprotobuf-dev` |
2831
| Boost | `libboost-program-options-dev`, `libboost-iostreams-dev`, `libboost-filesystem-dev`, `libboost-system-dev`, `libboost-date-time-dev` |
2932
| zlib | `zlib1g-dev` |
33+
| htslib | `libhts-dev` |
3034
| Cap'n Proto | `capnproto`, `libcapnp-dev` |
3135
| Eigen3 | `libeigen3-dev` |
32-
| htslib 1.20 | (bundled) |
3336

3437
### Build
3538

@@ -40,6 +43,3 @@ make -j$(nproc)
4043
```
4144

4245
The binary is at `build/bin/panmap`.
43-
44-
!!! tip
45-
If you hit dependency issues, the Docker build is the fastest path forward.

docs/metagenomic.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ panmap ../examples/data/sars_20000_twilight_dipper.panman \
5555
--index sars_20000_twilight_dipper.idx \
5656
--amplicon-depth SRR19707934.amplicon_stacks.tsv \
5757
--mask-reads-relative-frequency 0.01 \
58-
em-delta-threshold 0.00001 \
58+
--em-delta-threshold 0.00001 \
5959
--output SRR19707934 -t 8
6060
```
6161

0 commit comments

Comments
 (0)