使用datarrame,出现TypeError: data type not “ ” understood
原本是这样写的:df=pd.DataFrame(train_id,train_docid,train_question,train_answer),就出现了错误,在变量外部加一个中括号写成
df=pd.DataFrame([train_id,train_docid,train_question,train_answer])就好了。train_id,train_docid,train_question,train_answer是4个字符串变量。