We are given the following function:
To do a translation in the direction of the y-axis we need to add the units we want to translate to the entire function, as follows:
Where "k" is a constant. If "k" is positive the graph is translated in upwards and is "k" is negative the function is translated downwards.
Therefore, since in the function we add +2, this means that the graph is translated 2 units up.
When we do a translation in the x-direction we use the following transformation: