I loaded raw data and did pd.read_csv() through Pandas. However, the data that was retrieved (500rows x 1 columns) was recognized like this.
So I have two questions. First of all, how many times can we take the data from the first row from the data that's the data that's what's what? For example, this is how it's like this. Pulling only the 22nd to 25th data from columns 1 to 10
The second way is to make it recognized like this instead of being called in like that. Step = ',Even if you try to use the same method, the data cannot be written because the distinction between the data is different. (Some are space bar number 3, some are space bar number 5, etc.)
I'd appreciate it if you could tell me one of these two ways!
python pandas dataframe data
If the actual delimiter is 2 or more spaces, look for it this way, turn it around, and use it.
import re
rawdata = re.sub(r"[ \t]{2,}", ",", rawdata, 0)
581 PHP ssh2_scp_send fails to send files as intended
572 rails db:create error: Could not find mysql2-0.5.4 in any of the sources
915 When building Fast API+Uvicorn environment with PyInstaller, console=False results in an error
574 Who developed the "avformat-59.dll" that comes with FFmpeg?
613 GDB gets version error when attempting to debug with the Presense SDK (IDE)
© 2024 OneMinuteCode. All rights reserved.