Home > other >  Python using pd. Read_table separator when reading the textstream file
Python using pd. Read_table separator when reading the textstream file

Time:11-19

Excuse me, I'm using this statement read TXT format file, use the separator "\ t", but becomes a column read data, actual data has more than 40 listed, what should be how to deal with, thank you,
The import pandas as pd
The import numpy as np
Df2018Q1=pd. Read_table (r "C: \ Users \ cpic \ \ Desktop \ cuiruxiao \ business support system, 201801-201803\2018 q1. TXT", engine="python", encoding="utf-8 - sig", sep="\ t")

The returned result: 2335329 rows x 1 columns

CodePudding user response:

2018 q1. TXT in separate columns in what symbols, you can fill in sep="'

CodePudding user response:

Hello, is in TXT \ t but this still only 1 columns
  • Related