Ethereum: Panda are unable to read the XLSX files from Binance Trade Export
It is important that the merchant easily imports and analyzes financial data to make conscious decisions. Recently I came across a problem where pandas couldn’t read certain .xlsx files from my export of binance.com. This problem not only affects me, but also other users who rely on this function.
Problem: Panda can’t read XLSX files
To prevent the problem, I checked the answer to a similar question like NIC Schozzos and noticed that he mentioned that using “Read_excel” may not work for a specific file reading limit .xlsx. In particular, he pointed out that some of the binance exports of trading exports have too complicated data or have special formatting problems that make them inappropriate “Read_excel”.
Solution: Using Pandas.Read_csv ()
instead of
After the trial and consulting with other users, I discovered that the use of Pandas.Read_csv ()
(or any other CSV solution) could have a better access .XLSX files to read the Binancem Store. This is because pandas can process sophisticated data formats from “Read_excel”.
Why Read_csv
Work
The reason why Read_csv works for me and others are that it does not need a panda to analyze all files that could cause problems with shaping or missing data. Instead, Read_csv “reads data into pieces, allowing pandas to process sophisticated data structures.
Example Code: Reading .xLSX files using Read_csv
Here’s an example of a code fragment that shows how to use pandas.Read_csv ()
To read Binan’s trade export:
`Python
Imports of pandas as pd
Load CSV file
Df = PD.Read_csv ('Binance_trade_export.csv')
Alternatively, you can also use the XLD library (.XLSX files)
Import xlrd
File_path = 'Binance_trade_export.xlsx'
Df = PD.Read_excel (File_path)
Print (DF.Head ())
Print of the first pair of data recordings
Conclusion:
In conclusion, although Read_excel may not work on certain export of Binance export trade due to formatting or complexity using sustainable alternatives using `Pandas.Read_csv ()” (or other CSV -based solutions). This approach enables pandas. Processing sophisticated data. Formats and reduce the likelihood of dealing with mistakes in shaping.
I hope this solution helps other users fighting S.XLSX files from binance trading exports!