首页 > 解决方案 > 如何让 DataFrame 对象像 VSCode 调试控制台中的表格一样显示?

问题描述

我设置了一个断点并开始在调试控制台上输入。它似乎打印了对象视图的字符串表示形式(pandas.DataFrame在这种情况下为 a )。有没有让对象像 iPython 中的表格一样很好地显示出来?

在此处输入图像描述

这是我的launch.json

{
    // Use IntelliSense to learn about possible attributes.
    // Hover to view descriptions of existing attributes.
    // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
    "version": "0.2.0",
    "configurations": [
        {
            "name": "Python: Debug Console",
            "type": "python",
            "request": "launch",
            "program": "${file}",
            "console": "integratedTerminal"
        }
    ]
}

标签: pythonvisual-studio-code

解决方案


推荐阅读