Convert a dataframe with multiple rows into one row using pandas?
<p>Having the following dataframe,</p>

<pre><code>      0      1      2
A    0.2    0.4    0.6
B    0.1    0.1    0.3
</code></pre>

<p>How to achieve this transformation, while merging the row index with column name?</p>

<pre><code>     A_0    A_1    A_2    B_0    B_1    B_2
0    0.2    0.4    0.6    0.1    0.1    0.3
</code></pre>