How to expand one-dimensional DataFrame to two-dimensional DataFrame with Boolean values?
<pre><code>&gt;&gt;&gt; df = pd.DataFrame(data = ['a','b','b','c'],index=['day1','day1','day2','day2'],columns=['name'])

     name
day1    a
day1    b
day2    b
day2    c
</code></pre>

<p>How can I convert df to a two-dimension DataFrame with boolean values like</p>

<pre><code>      a  b  c
day1  1  1  0
day2  0  1  1
</code></pre>