So here I am studying regression analysis. As an assignment, I have been asked to obtain some binary data, simulate its behavior from some sample of it and apply the resulting general linear model to the whole data in order to know how accurate it is.
The problem is I am not used to such method when applied to categorical (dummy) variables. More precisely, given the model $\textbf{Y} = \textbf{X}\textbf{B} + \textbf{E}$, I am a little bit lost as to the precise procedure to obtain the matrices $\textbf{Y}$ and $\textbf{X}$.
For example, consider that $\text{man} = 0$ and $\text{woman} = 1$, from whence we obtain the emprical matrix from some target population we are interested in \begin{align*} \textbf{Y} = \left[ {\begin{array}{c} \text{man} \\ \text{woman} \\ \text{man} \\ \text{woman} \\ \text{man} \\ \text{man} \\ \end{array} } \right] = \left[ {\begin{array}{cc} 1 & 0 \\ 0 & 1 \\ 1 & 0 \\ 0 & 1 \\ 1 & 0 \\ 1 & 0 \\ \end{array} } \right] \end{align*}
My question is: how do we proceed from here? Moreover, how do we get $\textbf{X}$? Any help is appreciated.