# Issue with qiime rescript evaluate-fit-classifier - wrong classification

**URL:** https://forum.qiime2.org/t/issue-with-qiime-rescript-evaluate-fit-classifier-wrong-classification/30918
**Category:** User Support
**Tags:** taxonomy, feature-classifier
**Created:** [July 23, 2024, 3:55pm UTC](https://forum.qiime2.org/t/issue-with-qiime-rescript-evaluate-fit-classifier-wrong-classification/30918 "2024-07-23T15:55:34Z")
**Posts on this page:** 1
**Showing post:** 4

<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: [July 24, 2024, 3:48pm UTC](https://forum.qiime2.org/t/issue-with-qiime-rescript-evaluate-fit-classifier-wrong-classification/30918/4 "2024-07-24T15:48:54Z")

</div>

> [@Blanka\_Roje](#):
>
> Is there a way to make the classifier in this case assign to genus level only?

You'll have to do this prior to training the classifier. There are two ways:

1. When running `rescript get-ncbi-data` you can set the taxonomic ranks you'd like to extract via the `--p-ranks` option. The default is to pull `kingdom phylum class order family genus species`. In your case you can use: `--p-ranks kingdom phylum class order family genus`
2. Perhaps more easily, you can simply make use of [rescript edit-taxonomy](https://forum.qiime2.org/t/processing-filtering-and-evaluating-the-silva-database-and-other-reference-sequence-data-with-rescript/15494#heading--sixteenth-header). That is, your command to remove the species labels may look something like this:

```auto
qiime rescript edit-taxonomy \
    --i-taxonomy NCBI-diatoms-rbcL-ref-tax.qza \
    --p-use-regex \
    --p-search-strings 's__.*' \
    --p-replacement-strings '' \
    --o-edited-taxonomy NCBI-diatoms-rbcL-ref-tax-genus-only.qza

```

Then use `NCBI-diatoms-rbcL-ref-tax-genus-only.qza` for all your downstream curation and classifier training steps. I hope I got the regex correct, but you can play around with it. 🙂

-Cheers!

---

_[View the full topic](https://forum.qiime2.org/t/issue-with-qiime-rescript-evaluate-fit-classifier-wrong-classification/30918)._
