Answers for "add df to another df as columns"

3

create new dataframe with columns from another dataframe pandas

new = old[['A', 'C', 'D']].copy()
Posted by: Guest on March-24-2021
0

add column to df from another df

# pre 0.24
feature_file_df['RESULT'] = RESULT_df['RESULT'].values
# >= 0.24
feature_file_df['RESULT'] = RESULT_df['RESULT'].to_numpy()
Posted by: Guest on May-29-2020

Python Answers by Framework

Browse Popular Code Answers by Language