DataFrameModel.py 文件源码

python
阅读 30 收藏 0 点赞 0 评论 0

项目:qtpandas 作者: draperjames 项目源码 文件源码
def setDataFrameFromFile(self, filepath, **kwargs):
        """
        Sets the model's dataFrame by reading a file.
        Accepted file formats:
            - .xlsx (sheet1 is read unless specified in kwargs)
            - .csv (comma separated unless specified in kwargs)
            - .txt (any separator)

        :param filepath: (str)
            The path to the file to be read.
        :param kwargs:
            pandas.read_csv(**kwargs) or pandas.read_excel(**kwargs)
        :return: None
        """
        df = superReadFile(filepath, **kwargs)
        self.setDataFrame(df, filePath=filepath)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号