I want to how I can append the data from dataframe to excel cells using python. I am able to do it for csv files. Code for appending data in csv:-
print(yes['we'].to_csv(r'C:/Users/Desktop/yo.txt', header=None, index=None, sep=' ', mode='a'))
I want to how I can append the data from dataframe to excel cells using python. I am able to do it for csv files. Code for appending data in csv:-
print(yes['we'].to_csv(r'C:/Users/Desktop/yo.txt', header=None, index=None, sep=' ', mode='a'))
file_location="C:/Users/Jiang/Desktop/xert.xlsx"
wb = load_workbook(file_location)
ws = wb.get_sheet_by_name('Sheet1')
ws.append([result0, int(result1), int(result2)])