Skip to content

Commit f91e5c6

Browse files
Docs: Add instructions for full and ni workflows
1 parent 20f3d74 commit f91e5c6

File tree

1 file changed

+58
-2
lines changed

1 file changed

+58
-2
lines changed

docs/example_pipeline.rst

Lines changed: 58 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
Example pipeline setup and execution
33
=====================================
44

5+
.. _common-setup:
6+
57
Preliminary setup and common instructions
68
-----------------------------------------
79

@@ -14,7 +16,7 @@ Before execution of the ``MiCoNE`` pipeline we need to install the environments:
1416
1517
micone install
1618
17-
.. note:: This command will take a considerable amount of time (several hours) as MiCoNE will install all the ``conda`` environments
19+
.. warning:: This command will take a considerable amount of time (several hours) as MiCoNE will install all the ``conda`` environments
1820

1921
If you wish to install only a subset of the environments, you can specify the environments to install using the ``-e`` option:
2022

@@ -67,8 +69,62 @@ To run the pipeline, you can use the ``run.sh`` script in the ``<pipeline_dir>``
6769
Full pipeline workflow
6870
----------------------
6971

72+
First follow the instructions in steps 1-3 in the :ref:`common-setup` section.
73+
74+
Let us assume that you have multiplexed (``run1``, ``run2``, and ``run3``) paired end 16S sequence data stored in the ``<pipeline_dir>/seqs`` folder. To run the pipeline you will need the following:
75+
76+
1. ``forward.fastq.gz``: Forward reads
77+
2. ``reverse.fastq.gz``: Reverse reads
78+
3. ``barcodes.fastq.gz``: Barcodes
79+
4. ``mapping.tsv``: Mapping file
80+
5. ``sample_metadata.tsv``: Sample metadata file
81+
82+
.. warning:: Keep the file names as they are. The pipeline might have issues if the file names are changed.
83+
84+
An example ``sample_sheet.csv`` file will look like this:
85+
86+
+-----+------+--------------------------------------+--------------------------------------+---------------------------------------+----------------------------+------------------------------------+
87+
| id | run | forward | reverse | barcodes | mapping | sample_metadata |
88+
+=====+======+======================================+======================================+=======================================+============================+====================================+
89+
| id1 | run1 | sequences/run1/seqs/forward.fastq.gz | sequences/run1/seqs/reverse.fastq.gz | sequences/run1/seqs/barcodes.fastq.gz | sequences/run1/mapping.tsv | sequences/run1/sample_metadata.tsv |
90+
+-----+------+--------------------------------------+--------------------------------------+---------------------------------------+----------------------------+------------------------------------+
91+
| id2 | run2 | sequences/run2/seqs/forward.fastq.gz | sequences/run2/seqs/reverse.fastq.gz | sequences/run2/seqs/barcodes.fastq.gz | sequences/run2/mapping.tsv | sequences/run2/sample_metadata.tsv |
92+
+-----+------+--------------------------------------+--------------------------------------+---------------------------------------+----------------------------+------------------------------------+
93+
| id3 | run3 | sequences/run3/seqs/forward.fastq.gz | sequences/run3/seqs/reverse.fastq.gz | sequences/run3/seqs/barcodes.fastq.gz | sequences/run3/mapping.tsv | sequences/run3/sample_metadata.tsv |
94+
+-----+------+--------------------------------------+--------------------------------------+---------------------------------------+----------------------------+------------------------------------+
95+
96+
.. note:: These files must follow the ``qiime2`` supported formats. For more information about the supported formats see the `qiime2 documentation <https://docs.qiime2.org/2023.7/tutorials/importing/>`__.
97+
98+
7099
Network inference workflow
71100
---------------------------
72101

73-
Note that this workflow is only valid if your biom files already have taxonomy labels assigned. You must run the workflow from the TA step if they do not.
102+
Before running this workflow make sure that your OTU tables have taxonomy metadata and sample metadata information.
103+
You must run the workflow from the TA step if they do not.
104+
105+
First follow the instructions in steps 1-3 in the :ref:`common-setup` section.
106+
107+
Let us assume that you have 3 sets of OTU tables (``id1``, ``id2``, and ``id3``) you wish to analyze. To run the pipeline you will need the following:
108+
109+
1. ``otu_table.tsv``: OTU table in ``.tsv`` format
110+
2. ``obs_metadata.tsv``: Taxonomy assignments in ``.tsv`` format. It must contain the following columns: "Kingdom", "Phylum", "Class", "Order", "Family", "Genus", "Species". The latter columns can be dropped if you have grouped your taxonomy at a higher level.
111+
3. ``sample_metadata.tsv``: Sample metadata file
112+
4. ``children_map.json``: A file that maps the current taxonomy ids to lower taxonomic level. Can be an empty JSON if you wish to ignore this field.
113+
114+
.. warning:: Keep the file names as they are. The pipeline might have issues if the file names are changed.
115+
116+
An example ``sample_sheet.csv`` file will look like this:
117+
118+
+-----+--------------------------+-----------------------------+--------------------------------+------------------------------+
119+
| id | otu_table | obs_metadata | sample_metadata | children_map |
120+
+=====+==========================+=============================+================================+==============================+
121+
| id1 | inputs/id1/otu_table.tsv | inputs/id1/obs_metadata.tsv | inputs/id1/sample_metadata.tsv | inputs/id1/children_map.json |
122+
+-----+--------------------------+-----------------------------+--------------------------------+------------------------------+
123+
| id2 | inputs/id2/otu_table.tsv | inputs/id2/obs_metadata.tsv | inputs/id2/sample_metadata.tsv | inputs/id2/children_map.json |
124+
+-----+--------------------------+-----------------------------+--------------------------------+------------------------------+
125+
| id3 | inputs/id3/otu_table.tsv | inputs/id3/obs_metadata.tsv | inputs/id3/sample_metadata.tsv | inputs/id3/children_map.json |
126+
+-----+--------------------------+-----------------------------+--------------------------------+------------------------------+
127+
128+
129+
.. note:: Example data can be found `here <https://github.com/segrelab/MiCoNE-synthetic-data/tree/main/data>`__.
74130

0 commit comments

Comments
 (0)