$x \in \mathbb{R}^2$ has $f(x)$ plotted on a $\mathbb{R}^3$ mesh like $(x,y,f(x,y))$. So is $f \in \mathbb{R}, \mathbb{R}^2$ or $\in \mathbb{R}^3$?
Clearly $f: \mathbb{R}^2 \rightarrow \mathbb{R}$. But in the plot visualization it would appear as if it's $f(x,y,z)=(f_x,f_y,f_z)$.