I have two pandas dataframes (both 4004 rows x 24 columns). I want to multiply essentially df1 rows with df2 rows, which I can usually do with df1 * df2
I've tried below, but I get nan for all rows
df2 = df2.set_index(df1.index)
df1 = df1 * df2
Also tried below without success. Here I don't get nan-values but df2 * df2
df1 = df2.apply(lambda row:row*row,axis = 1)