| SampleID | BioProject | BioSample | env_broad_scale | env_local_scale | env_medium | geo_loc_name | SampleName | Organism |
|---|---|---|---|---|---|---|---|---|
| SRR23329747 | PRJNA930143 | SAMN33051429 | Shrimp culture farm | Pond 5 | culture pond | India: Andhra Pradesh | WFS_C | Penaeus vannamei |
| SRR23329748 | PRJNA930143 | SAMN33051429 | Shrimp culture farm | Pond 5 | culture pond | India: Andhra Pradesh | WFS_B | Penaeus vannamei |
| SRR23329749 | PRJNA930143 | SAMN33051429 | Shrimp culture farm | Pond 5 | culture pond | India: Andhra Pradesh | WFS_A | Penaeus vannamei |
| SRR23295634 | PRJNA930143 | SAMN32984423 | Shrimp culture Farm | Pond 1 | Healthy Shrimp gut | India: Andhra pradesh | C1_C | Penaeus vannamei |
| SRR23295635 | PRJNA930143 | SAMN32984423 | Shrimp culture Farm | Pond 1 | Healthy Shrimp gut | India: Andhra pradesh | C1_B | Penaeus vannamei |
| SRR23295636 | PRJNA930143 | SAMN32984423 | Shrimp culture Farm | Pond 1 | Healthy Shrimp gut | India: Andhra pradesh | C1_A | Penaeus vannamei |
PacBio 16S rRNA amplicon Analysis
Started on 24-06-26
Testing the anlysis of 16S rRNA reads derived from PacBio instruments
- Study: PRJNA930143
- Sample size: 6
- Environment: Shrimp cultivation farm
- Sample: Shrimp microbiome
- Sample types: Cultured pond water and Shrimp gut
- Instrument: PacBio Sequel II
Working directory: test_pacbio
Get data
Download SraRunTable. Make a list of SRR IDs
Select required columns from the RunTable and save as metadata.tsv (Table 1)
Download SRA files and extract
Read and Primer counts
Counting the total number of reads and primers in each sample (Table 2)
$ echo -e "Sample\tTotal_Reads\tF_count\tR_count" > read_primer_counts.tsv
$ for sample in $(cat samples_list.txt); do echo -e "$sample\t"$(grep '^@' raw_reads/$sample.fastq -c)"\t"$(grep 'AG[GA]GTT[TC]GAT[TC][AC]TGGCTCAG' raw_reads/$sample.fastq -c)"\t"$(grep 'AAGTCGTAACAAGGTA[GA]C[TC]' raw_reads/$sample.fastq -c); done >> read_primer_counts.tsv| Sample | Total_Reads | F_count | R_count |
|---|---|---|---|
| SRR23329747 | 78914 | 63001 | 68737 |
| SRR23329748 | 20608 | 16704 | 18132 |
| SRR23329749 | 52649 | 37512 | 45635 |
| SRR23295634 | 47915 | 37416 | 41583 |
| SRR23295635 | 35292 | 28459 | 31158 |
| SRR23295636 | 65084 | 48502 | 54104 |
Compress raw reads (optional)
QIIME2
Only a few reads do not have primer sequences.
Trying two different methods:
- run
denoise-ccsto perform all primer removal and dada2 steps - remove primers and run
denoise-ccsto perform just the dada2 steps
QIIME2 version: 2026.1
- Tried QIIME 2026.4, but it uses
scikit-learn v1.7.1which is incompatible with existing classifiers.
- A classifier was built with the new version, but the evaluators are not available in QIIME 2026.4, as on 3rd Jul 2026 - check
ncbi_classifier.qmd(note to self).
- So using the latest version of QIIME2 with scikit-learn v1.4.2, i.e. 2026.1
Make a manifest file (Table 3)
| sample.id | absolute.filepath |
|---|---|
| SRR23329747 | $PWD/raw_reads/SRR23329747.fastq.gz |
| SRR23329748 | $PWD/raw_reads/SRR23329748.fastq.gz |
| SRR23329749 | $PWD/raw_reads/SRR23329749.fastq.gz |
| SRR23295634 | $PWD/raw_reads/SRR23295634.fastq.gz |
| SRR23295635 | $PWD/raw_reads/SRR23295635.fastq.gz |
| SRR23295636 | $PWD/raw_reads/SRR23295636.fastq.gz |
Import data into q2 pipeline
Denoise directly
Run DADA2
(q2_261)$ qiime dada2 denoise-ccs --i-demultiplexed-seqs 1_import.qza --p-front AGRGTTYGATYMTGGCTCAG --p-adapter AAGTCGTAACAAGGTARCY --p-min-len 1000 --p-max-len 1600 --p-n-threads 10 --o-table 2_table.qza --o-representative-sequences 2_repseqs.qza --o-denoising-stats 2_stats.qza --o-base-transition-stats 2_bt_stats.qza
# Generate visualization for stats
(q2_261)$ qiime metadata tabulate --m-input-file 2_stats.qza --o-visualization 2_stats.qzvUpon searching for the above sequence, it was found a few bp before the 3’ region and in very less numbers.
Anyways, trying the modification
(q2_261)$ qiime dada2 denoise-ccs --i-demultiplexed-seqs 1_import.qza --p-front AGRGTTYGATYMTGGCTCAG --p-adapter RGYTACCTTGTTACGACTT --p-min-len 1000 --p-max-len 1600 --p-n-threads 10 --o-table 2_table2.qza --o-representative-sequences 2_repseqs2.qza --o-denoising-stats 2_stats2.qza --o-base-transition-stats 2_bt_stats2.qza
# Approximately 3 hrs 40 mins
(q2_261)$ qiime metadata tabulate --m-input-file 2_stats2.qza --o-visualization 2_stats2.qzv
(q2_261)$ qiime feature-table summarize --i-table 2_table2.qza --o-feature-frequencies 2_feature_freqs2.qza --o-sample-frequencies 2_sample_freqs2.qza --o-summary 2_table2.qzv --m-metadata-file ../metadata.tsv
(q2_261)$ qiime feature-table tabulate-seqs --i-data 2_repseqs2.qza --o-visualization 2_repseqs2.qzvApproximately 78-88% reads survived primer removal step and by the end 32-67% survived the DADA2 process (Table 4)
| sample.id | input | primer.removed | percentage.of.input.primer.removed | filtered | percentage.of.input.passed.filter | denoised | non.chimeric | percentage.of.input.non.chimeric |
|---|---|---|---|---|---|---|---|---|
| #q2:types | numeric | numeric | numeric | numeric | numeric | numeric | numeric | numeric |
| SRR23295634 | 47872 | 41663 | 87.03 | 26723 | 55.82 | 20507 | 18893 | 39.47 |
| SRR23295635 | 35263 | 31375 | 88.97 | 18357 | 52.06 | 12067 | 11443 | 32.45 |
| SRR23295636 | 65015 | 55324 | 85.09 | 38005 | 58.46 | 30891 | 28658 | 44.08 |
| SRR23329747 | 78834 | 69399 | 88.03 | 53949 | 68.43 | 51408 | 49375 | 62.63 |
| SRR23329748 | 20586 | 17647 | 85.72 | 14096 | 68.47 | 13835 | 13835 | 67.21 |
| SRR23329749 | 52602 | 41119 | 78.17 | 32064 | 60.96 | 30844 | 30049 | 57.13 |
Trying without the --p-adapter
(q2_261)$ qiime dada2 denoise-ccs --i-demultiplexed-seqs 1_import.qza --p-front AGRGTTYGATYMTGGCTCAG --p-min-len 1000 --p-max-len 1600 --p-n-threads 10 --o-table 2_table3.qza --o-representative-sequences 2_repseqs3.qza --o-denoising-stats 2_stats3.qza --o-base-transition-stats 2_bt_stats3.qza
# Approximately 3 hrs 40 mins
(q2_261)$ qiime metadata tabulate --m-input-file 2_stats3.qza --o-visualization 2_stats3.qzv
(q2_261)$ qiime feature-table summarize --i-table 2_table3.qza --o-feature-frequencies 2_feature_freqs3.qza --o-sample-frequencies 2_sample_freqs3.qza --o-summary 2_table3.qzv --m-metadata-file ../metadata.tsv
(q2_261)$ qiime feature-table tabulate-seqs --i-data 2_repseqs3.qza --o-visualization 2_repseqs3.qzvThe output is almost same as above (Table 5)
| sample.id | input | primer.removed | percentage.of.input.primer.removed | filtered | percentage.of.input.passed.filter | denoised | non.chimeric | percentage.of.input.non.chimeric |
|---|---|---|---|---|---|---|---|---|
| #q2:types | numeric | numeric | numeric | numeric | numeric | numeric | numeric | numeric |
| SRR23295634 | 47872 | 42974 | 89.77 | 26982 | 56.36 | 19539 | 18256 | 38.14 |
| SRR23295635 | 35263 | 31953 | 90.61 | 18288 | 51.86 | 11257 | 10766 | 30.53 |
| SRR23295636 | 65015 | 57200 | 87.98 | 38264 | 58.85 | 28809 | 26137 | 40.2 |
| SRR23329747 | 78834 | 71218 | 90.34 | 54443 | 69.06 | 51003 | 48029 | 60.92 |
| SRR23329748 | 20586 | 18281 | 88.8 | 14352 | 69.72 | 13387 | 13277 | 64.5 |
| SRR23329749 | 52602 | 42021 | 79.88 | 32122 | 61.07 | 30021 | 28713 | 54.59 |
Remove primers and denoise
What about the sequence lengths?
| Statistic | Value |
|---|---|
| count | 1631.00 |
| min | 1066.00 |
| max | 1594.00 |
| mean | 1442.26 |
| range | 528.00 |
| std | 36.16 |
| Quantile | Value |
|---|---|
| 0.02 | 1385.0 |
| 0.09 | 1405.7 |
| 0.25 | 1420.0 |
| 0.50 | 1445.0 |
| 0.75 | 1460.0 |
| 0.91 | 1482.0 |
| 0.98 | 1520.4 |
| Statistic | Value |
|---|---|
| count | 1725.00 |
| min | 1122.00 |
| max | 1590.00 |
| mean | 1459.32 |
| range | 468.00 |
| std | 36.46 |
| Quantile | Value |
|---|---|
| 0.02 | 1402.96 |
| 0.09 | 1423.00 |
| 0.25 | 1438.00 |
| 0.50 | 1464.00 |
| 0.75 | 1478.00 |
| 0.91 | 1499.00 |
| 0.98 | 1536.04 |
Using raw3 and filt2 for downstream analysis
Classification
Silva classifier may not give species level resolution. Since we have full length 16S rRNA reads, other classifiers like GreenGenes, GTDB, or NCBI may be useful. Most of the classiffiers are avaialble at QIIME2 resources page.
With NCBI classifier
# in q2_raw directory
(q2_261)$ qiime feature-classifier classify-sklearn --i-classifier ~/ncbi_refseqs_classifier_04032026.qza --i-reads 2_repseqs3.qza --o-classification 3_taxonomy_ncbi.qza --p-n-jobs 10
(q2_261)$ qiime metadata tabulate --m-input-file 3_taxonomy_ncbi.qza --o-visualization 3_taxonomy_ncbi.qzv
(q2_261)$ qiime taxa barplot --i-table 2_table3.qza --i-taxonomy 3_taxonomy_ncbi.qza --m-metadata-file ../metadata.tsv --o-visualization 3_taxa_plots_ncbi.qzvPhylogeny
With mafft and iqtree
# in q2_raw
(q2_261)$ qiime phylogeny align-to-tree-mafft-iqtree --p-seed 380 --p-alrt 1000 --p-substitution-model 'GTR+G' --p-n-threads 10 --i-sequences 2_repseqs3.qza --o-alignment 4_aligned_repseqs.qza --o-masked-alignment 4_masked_rep_seqs.qza --o-tree 4_unrooted_tree.qza --o-rooted-tree 4_rooted_tree.qzaRarefaction curves
The minimum feature count should be sufficient for rarefaction (Figure 1)
Repeat these 3 steps (classification, phylogeny, and rarefaction curves) in the
q2_filtdirectory
Using HiFi 16S workflow
The official package for 16S amplicon analysis
Installation
As on 04 Jul 2026, newest version of nextflow is not working with this workflow. Using an older version (24.10)
Run
(pb_16s)$ nextflow run main.nf --input /run/media/anwesh/hdd_4tb/Files/Analyses/Microbiome/amplicon/test_pacbio/manifest_pb16s.tsv --metadata /run/media/anwesh/hdd_4tb/Files/Analyses/Microbiome/amplicon/test_pacbio/metadata.tsv --outdir /run/media/anwesh/hdd_4tb/Files/Analyses/Microbiome/amplicon/test_pacbio/pb_16s --dada2_cpu 10 --vsearch_cpu 10 --cutadapt_cpu 10 --publish_dir_mode copyAll steps, except the last html report generation, were successful.
Use
--skip_primer_trimparameter to skip primer trimming
Outputs
The numbers are slightly higher that the above methods (Table 12)
| sample.id | input | filtered | percentage.of.input.passed.filter | denoised | non.chimeric | percentage.of.input.non.chimeric |
|---|---|---|---|---|---|---|
| #q2:types | numeric | numeric | numeric | numeric | numeric | numeric |
| SRR23295634 | 47221 | 32814 | 69.49 | 25548 | 23568 | 49.91 |
| SRR23295635 | 34849 | 22034 | 63.23 | 14797 | 14357 | 41.2 |
| SRR23295636 | 64074 | 47509 | 74.15 | 39159 | 36398 | 56.81 |
| SRR23329747 | 77958 | 63892 | 81.96 | 60919 | 57670 | 73.98 |
| SRR23329748 | 19052 | 15790 | 82.88 | 15524 | 15520 | 81.46 |
| SRR23329749 | 45923 | 37544 | 81.75 | 36198 | 35084 | 76.4 |
Sequence lengths: Visualization was not generated by the pipeline, so, generating one
| Statistic | Value |
|---|---|
| count | 1364.00 |
| min | 1164.00 |
| max | 1586.00 |
| mean | 1443.12 |
| range | 422.00 |
| std | 33.25 |
| Quantile | Value |
|---|---|
| 0.02 | 1386.00 |
| 0.09 | 1407.00 |
| 0.25 | 1421.00 |
| 0.50 | 1445.00 |
| 0.75 | 1464.25 |
| 0.91 | 1482.00 |
| 0.98 | 1516.00 |
The HiFi workflow is better over QIIME2 based outputs, with the provided parameters. QIIME2 workflow may need tweaking for a better output.