change just one value with an Animation clip

Hi there,
I would like to know if there’s any way to use an animation clip in order to change for example, ‘Y’ position of a gameObject without changing ‘X’ and ‘Z’ values.

thanks in advance.

Yeah, you just don’t change the X and Z values. Are you talking in the Animation Editor or via script? If script, example here: