I have the following data frame:
F1:
head drowsiness sweat
head_P D_P sw_f
head_S D-H sw_h
head_F D_L sw_l
I need to create a dictionary by mapping all the values in columns to the header of the columns as follows:
Dic = {head_p:head, head_S: head, head_F: head, D_P: drowsiness, D-H:drowsiness , D_L: drowsiness, sw_f: sweat, sw_h: sweat , sw_l: sweat }
I created a list of each column and mapped it to the header, but I do not know how to create such a dictionary. Thank you!