Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

pandas sub columns

|     Start      |       Intermediary       |        End        |
|       |        |            |             |         |         |
_________________________________________________________________
| s_lat | s_lng  |  i_lat     |  i_lng      | e_lat   | e_lng   |

mux = pd.MultiIndex.from_product([['Start','Intermediary','End'], ['lat','lng']])
df = pd.DataFrame(data, columns=mux)
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #pandas #columns
ADD COMMENT
Topic
Name
7+9 =