change the speed of a specific animation of an animator throw script?

hey guys,
is there any way to change the speed of one specific animation of my animator? i have an animator containing several animations.
can i mention the name of the animation clip inside my animator to set it’s speed to zero?
by the way i can’t set the speed of the whole layer to zero
because i have idle animation that should be played by its normal speed.
OR
is there a way to tell one of animations of my animator to be disabled. i just need to tell my animator to stop playing one thoses animations inside it.
how can i do that?

In your animator, add parameter of type float, and give it a name, maybe speedMultiplier. In your animator state where you have speed, there is a field Multiplier with its name grayed. Check the parameter checkbox next to it, and from the dropdown menu select speedMultiplier. Now in your code you can set: animator.SetFloat(“speedMultiplier”, 0.5f ) and now your animation plays at half speed. And set it to 0 if you want to stop it.

If you go to the Animator view for an AnimationController and select an Animation state node, you will see that there is a speed field to you can use to adjust how fast that animation plays.