Projective space is not affine
First, let us review the definition of an affine scheme. An affine scheme $X$ is a locally ringed space isomorphic to $\operatorname{Spec} A$ for some commutative ring $A$. This means that if one knows one has an affine scheme $X$, then all one has to do to recover $A$ such that $X=\operatorname{Spec} A$ is to take global sections of the structure sheaf, ie $A\cong\Gamma(X,\mathcal{O}_X)$.
In order to prove that $\mathbb{P}^n_R$ is not affine, it suffices to show that $\operatorname{Spec}(\Gamma(\mathbb{P}^n_R,\mathcal{O}_{\mathbb{P}^n_R}))\cong \operatorname{Spec} R$ is not isomorphic to $\mathbb{P}^n_R$. This is due to a dimension argument- assume $R$ is noetherian, and $\dim R=d$. Then $\dim\mathbb{P}^n_R=d+n$, as $\dim R[x_1,\cdots,x_n]=d+n$. Unless $n=0$, the two cannot be isomorphic.