如何退出等待更多输入的函数? [英] How do I exit a function that is waiting for more input?

查看:42
本文介绍了如何退出等待更多输入的函数?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我搞砸了一个 ggplot 函数并独自运行了这个奇怪的行: label = as.character(share)+'%'quot;), -- 和然后我没有意识到光标显示的是 + 而不是 > 所以我再次运行了整个 ggplot 函数,然后才注意到控制台正在寻找更多输入.

I screwed up a ggplot function and ran this wonky line all by itself: label = as.character(share)+'%"), -- and then I didn't realize the cursor was showing a + instead of > so I ran the whole ggplot function again and only then noticed that the console was looking for more input.

我确实弄清楚出了什么问题(我需要关闭我打开的 '"),但我不知道如何退出完全发挥作用.我尝试了 ctrlc 和每个退出"我能想到的命令:

I did figure out what was wrong (I needed to close the ' and " I had opened) but I couldn't figure out how to just exit the function entirely. I tried ctrlc and every "exit" command I could think of:

+ break
+ }
+ }}}
+ end
+ return()
+ exit
+ '"'
+ 
+ '
+ "

是否有正确的方法来中断正在等待控制台更多输入的函数?

Is there a right way to break a function that is waiting for more input in the console?

推荐答案

您应该尝试转义 -- 或 ESC 按钮.

You should try escape -- or the ESC button.

您可能需要重复一遍:例如.ESC ESC

You may have to repeat it: eg. ESC ESC

这篇关于如何退出等待更多输入的函数?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆