title: R: is there something like dmatrices ( from python) in R for categorical values?
body: <p>In python you can use the dmatrices function from the patsy module when using categorical values for regressions to create 0 and 1 matrices for the categorical values.</p>
  
  <p>Is there a library/function in R that performs the same function? </p>