数据读取 pd.read_csv import numpy as np import pandas as pd df=pd.read_csv('沪深.csv',encoding='utf-8') 显示错误’utf-8’ codec can’t decode byte 0xb4 in position 0: invalid start byte 改成df=pd.read_csv(‘沪深.csv’,encoding=‘gbk’)即可