Fix some integer $n$, and consider the linear space $M(n,\mathbb F)$ of square $n\times n$ matrices in some field $\mathbb F$. Let $f:M(n,\mathbb F)\to\mathbb F$ be a functional that is invariant under change of basis, that is, such that $f(PAP^{-1})=f(A)$ for any $A,P\in M(n,\mathbb F)$ with $P$ invertible.
Standard examples are $f(A)=\det(A)$ and $f(A)=\operatorname{tr}(A)$. More generally, any function defined via the eigenvalues of $A$ is another example of this. Are these the only possible such examples?
In other words, can we characterise the set of possible functionals $M(n,\mathbb F)\to\mathbb F$ that are invariant under change of basis as being all and only those functions that can be defined from the eigenvalues of the matrix? I'm mostly interested to the cases $\mathbb F=\mathbb R,\mathbb C$, but I'm leaving this question general because I don't know if this assumption is relevant to the discussion.