# Reference database for clustering

**URL:** https://forum.qiime2.org/t/reference-database-for-clustering/27561
**Category:** User Support
**Tags:** rescript
**Created:** [September 5, 2023, 6:52am UTC](https://forum.qiime2.org/t/reference-database-for-clustering/27561 "2023-09-05T06:52:11Z")
**Posts on this page:** 1
**Showing post:** 3

<div class="post-metadata">

### Author: ![SoilRotifer](https://forum.qiime2.org/user_avatar/forum.qiime2.org/soilrotifer/32/21071_2.png) [@SoilRotifer](https://forum.qiime2.org/u/SoilRotifer)
#### Post date: [September 14, 2023, 8:16pm UTC](https://forum.qiime2.org/t/reference-database-for-clustering/27561/3 "2023-09-14T20:16:00Z")

</div>

Hi @Rakaya,

**RE 1:**

> [@Rakaya](#):
>
> By this I would have the dereplicated database, is this correct?

Yep.

**RE 2**

> [@Rakaya](#):
>
> Can I use dereplicated database instead of clustered one for clustering?

There is no need to cluster your reference sequences to match the clustering of your data, for reasons previously mentioned within these threads:

> [@Pre-trained silva classifier (V3-V4) qiime 2021.4](https://forum.qiime2.org/t/pre-trained-silva-classifier-v3-v4-qiime-2021-4/20470/13):
>
> Anyway, the old way of pre-clustering reference reads to 97% or 94% sequence similarity (as done with Greengenes and SILVA) was simply a logistical way to reduce the size of the reference database even further, so that it'll run on computers with limited memory and cpu power.

> [@Pre-trained silva classifier (V3-V4) qiime 2021.4](https://forum.qiime2.org/t/pre-trained-silva-classifier-v3-v4-qiime-2021-4/20470/13):
>
> If possible, it is best to try and use reference reads that have been minimally clustered or simply dereplicated, _i.e._ at 99% or 100% similarity. As you'll be able to more accurately classify your reads, that is you have more reference data to use.

> [@Pre-trained silva classifier (V3-V4) qiime 2021.4](https://forum.qiime2.org/t/pre-trained-silva-classifier-v3-v4-qiime-2021-4/20470/15):
>
> So, if you are using reference reads that are 99% - 100% then you can use them to classify any reads that are clustered at different similarities, e.g. 97%, 94%, etc...
> 
> In fact, some consider classifying 97% clustered OTUs against a 97% clustered reference database not a great idea. That is, as your nearest reference sequence can be up to 6% away, further reducing classification.
> 
> Does this help?

Additionally:

> [@Clustering taxonomy sequences](https://forum.qiime2.org/t/clustering-taxonomy-sequences/23784/11):
>
> In general, we do not recommend clustering reads for the purposes of making a reference database as your ability to correctly assign taxonomy to your reads declines. This is covered in our [RESCRIPt manuscript](https://doi.org/10.1371/journal.pcbi.1009581). Usually, clustering reference sequences is performed to reduce the file and memory size of the reference database when computational resources are limited.

**RE 3:**

> [@Rakaya](#):
>
> If I want to cluster my database at 85% identity threshold, what would be the command to use?

Simply add the paramater `--p-perc-identity 0.85` to that command. ⚠ : _I would not recommend using 85%. This is just provided as an example to drastically reduce the database size._

**RE 4:**

> [@Rakaya](#):
>
> Can I use 99% silva to cluster at 85%?

Yes you can classify your 85% clustered reads against the 99% SILVA database. _Again, I'd avoid 85%._ Also, the content I linked for **RE 2** , applies here too.

---

_[View the full topic](https://forum.qiime2.org/t/reference-database-for-clustering/27561)._
