Consider if we have a complete set of vectors in 2D characterized experimentally by spin-up and spin-down in the z direction:
[tex]
\mathbb{I}=|\uparrow\rangle \langle \uparrow |+|\downarrow\rangle \langle \downarrow |[/tex]
Then experimentally we find we can only observe two different numbers corresponding to two different physical situations, namely we measure something and it is spining up, or spining down with a number value for its angular momentum,
[tex]
S_{z}=\frac{\hbar}{2}|\uparrow\rangle \langle \uparrow |-\frac{\hbar}{2}|\downarrow\rangle \langle \downarrow |[/tex]
Now let's consider the different possibilities for measuring these values along the z-axis, this is given by
[tex]
\sum_{n,m=1}^{2}\langle n|S_{z}|m\rangle[/tex]
where by we examine the different situations
[tex]
\langle \uparrow |S_{z}|\uparrow\rangle[/tex]
[tex]
\langle \uparrow |S_{z}|\downarrow \rangle[/tex]
[tex]
\langle \downarrow |S_{z}|\uparrow \rangle[/tex]
[tex]
\langle \downarrow |S_{z}|\downarrow \rangle[/tex]
These can be combined into a single object and the inner products can be evaluated explicitly to give
[tex]
\begin{pmatrix}<br />
\langle \uparrow |S_{z}|\uparrow\rangle & \langle \uparrow |S_{z}|\downarrow \rangle \\<br />
\langle \downarrow |S_{z}|\uparrow \rangle & \langle \downarrow |S_{z}|\downarrow \rangle<br />
\end{pmatrix}=\frac{\hbar}{2}<br />
\begin{pmatrix}<br />
1 & 0 \\<br />
0 & -1<br />
\end{pmatrix}=\frac{\hbar}{2}\sigma_{z}[/tex]
This is one component of the spin matrices. a similar method yields the other two.