Pickling a DataFrame

前端 未结 2 1841
执笔经年
执笔经年 2021-01-02 12:38

I am trying to pickle a DataFrame with

import pandas as pd
from pandas import DataFrame
data = pd.read_table(\'Purchases.tsv\',index_col=\'coreuserid\')
data         


        
2条回答
  •  春和景丽
    2021-01-02 12:58

    You can try create a class from your DataFrame and pickle it after.

    This can help you: Pass pandas dataframe into class

提交回复
热议问题