Automorphism group of a variety Suppose $X$ is a (quasi-projective) variety over a field $k$, and let $\mathbb{P}^n(k)$ be the ambient projective space. 

When can one decide that the automorphism group of $X$ is induced by a subgroup of the automorphism group $\mathbf{P G L}_{n + 1}(k)$ of $\mathbb{P}^n(k)$ ? 

When $X$ itself is a sub-projective space over $k$, this is of course well known, but when $X$ is e.g. an affine subspace over $k$, this is in general not true (due to the existence of non-linear automorphisms).

Is it true when $X$ is projective ?

 A: I guess this should be true if and only if $f : X \to X$ fixes a polarization, i.e. there is an ample $A$ such that $f^\ast A \sim A$.
If there is such an $A$, then take the embedding of $X$ into $\mathbb P^n$ by a very ample $mA$.  The automorphism of $X$ is then induced by the linear map $f^\ast : \mathbb PH^0(X,mA) \to \mathbb PH^0(X,mA)$.  Conversely, if a map comes from a linear map on projective space, then the polarization given by restricting the hyperplane is fixed.
Typically automorphisms won't fix any polarization, so don't come from $\mathbb P^n$.  If you actually want to check it for a specific map, the first thing to do work out the induced map on $H^2(X;\mathbb R)$.  If there is an invariant ample divisor, its first chern class will be invariant under the pullback.  So you may be able to show that this doesn't happen.  If there is a fixed class, you need to know (a) whether it is represented by an ample divisor, which may or may not be easy to check depending on what $X$ is and (b) whether the divisor is linearly equivalent (rather than just numerically equivalent) to its pullback, which requires a bit more scrutiny.
As Francesco points out, $K_X$ always pulls back to itself under an automorphism, so if it's either ample or antiample you have what you want.
A: 
Is it true when X is projective ?

Let $X\subset\mathbb P^2$ be an elliptic curve and let $T:X\to X$ be a translation map $T(P)=P+P_0$ by a non-torsion point $P_0$. Then $T$ is an automorphism, but it is not induced by an element of $\text{PGL}_3$. Maybe a better question is whether, given a projective variety and an automorphism, does there exist some projective embedding for which the automorphism is induced by an element of $\text{PGL}$. 
A: What you want is true if $X$ is embedded using some integer power of $K_X$, in particular it is true for canonically and anti-canonically embedded varieties. 
In fact, any automorphism preserves the canonical class, so it necessarily preserves the hyperplane class under our assumption.
For the same reason, the answer is yes for varieties $X$ such that $\textrm{Pic}(X)= \mathbb{Z}$. In fact, if $L$ is the ample generator of the Picard group of $X$, then the hyperplane class is $H=kL$ for $k \geq 1$ and this must be preserved by all automorphisms, because they clearly preserve $H$.
Then the Noether-Lefschetz theorem implies that what you want is true for the very general smooth surface $X \subset \mathbb{P}^3$, and for all smooth hypersurfaces  $X \subset \mathbb{P}^n$ with $n \geq 4$.    
For general embeddings $X \hookrightarrow \mathbb{P}^n$ the answer is negative, as shown by the proposed counterexamples.  
