title: Pandas get_dummies to output dtype integer/bool instead of float
body: <p>I would like to know if could ask the get_dummies function in pandas to output the dummies dataframe with a dtype lighter than the default float64.</p>
  
  <p>So, for a sample dataframe with categorical columns:</p>
  
  <pre><code>In []: df = pd.DataFrame([(blue,wood),(blue,metal),(red,wood)],
                           columns=['C1','C2'])
  In []: df
  Out[]:
      C1      C2
  0   blue    wood
  1   blue    metal
  2   red     wood
  </code></pre>
  
  <p>after getting the dummies, it looks like:</p>
  
  <pre><code>In []: df = pd.get_dummies(df)
  In []: df    
  Out[]:
   C1_blue    C1_red  C2_metal    C2_wood
  0   1   0   0   1
  1   1   0   1   0
  2   0   1   0   1
  </code></pre>
  
  <p>which is perfectly fine. However, by default the 1's and 0's are float64:</p>
  
  <pre><code>In []: df.dtypes
  Out[]: 
  C1_blue     float64
  C1_red      float64
  C2_metal    float64
  C2_wood     float64
  dtype: object
  </code></pre>
  
  <p>I know I can change the dtype afterwards with <code>astype</code>:</p>
  
  <pre><code>In []: df = pd.get_dummies(df).astype(np.int8)
  </code></pre>
  
  <p>But I don't want to have the dataframe with floats in memory, because I am dealing with a big dataframe (from a csv of about ~5Gb). I would like to have the dummies directly as integers.</p>