【问题标题】:How to stop a command in R in Windows如何在 Windows 中停止 R 中的命令
【发布时间】:2014-12-02 20:54:27
【问题描述】:

我在 Windows 中使用 Rstudio。没有可供我点击的红色八角形。我试过在控制台中按 ESC 和 Ctrl + C 和 Ctrl + Z ,但这些都不起作用。

【问题讨论】:

  • ESC 通常对我有用。但是如果没有红色八边形,这可能意味着R(或RStudio)工作不正常……

标签: r rstudio


【解决方案1】:

运行代码时,红色八边形只会在运行时显示。因此,虽然它只是在您编写的代码中运行(读取数据和事物名称等),但八边形将不会显示。

按下ESC 将起作用,除非 Rstudio 被冻结。

祝你好运!

【讨论】:

    【解决方案2】:

    您也可以尝试通过菜单中断/终止 R 会话:
    Session -> Interrupt R

    Session -> Terminate R...

    Session -> Restart R (Ctrl+Shift+F10)

    如果没有其他帮助,请打开 Windows 命令行并终止 rsession.exe 进程:

    > tasklist | grep rsession
    # the output should be something like this:
     rsession.exe                  7260 Console                    1    166,144 K
    # The number (7260 in this case; will probably be different) is the process id (PID),
    # and you can use it to kill the process:
    > taskkill /F /PID 7260
    

    注意:这将强制停止 R 会话,并且 RStudio 可能必须重新启动(至少在我的机器上会发生这种情况)。

    【讨论】:

      【解决方案3】:

      使用 ctrl + alt + delete 打开任务管理器,您可以终止 R 会话,然后重新启动它以继续工作。

      【讨论】:

        猜你喜欢
        • 1970-01-01
        • 1970-01-01
        • 2014-08-20
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 2016-06-09
        相关资源
        最近更新 更多