My goal is to create a cell means model matrix from scratch in r. Please help show how this can be achieved.
I prefer the manual way over per-defined