Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Rstudio is duplicating commands in the command line

Tags:

r

rstudio

Having a weird problem in R that seems to have come out of nowhere... output in the RStudio terminal is repeated without me asking for it... i.e.,

> 3+4 > 3+4 [1] 7 [1] 7 

Anyone else have this issue and have any ideas how to resolve it? I'm also wondering whether it's actually performing the commands twice (and slowing things down considerably!).

Thanks in advance.

like image 859
Dan_Alexander Avatar asked Feb 28 '14 21:02

Dan_Alexander


People also ask

How do you stop a command in RStudio?

If you want to cancel a command you can simply hit “ Esc ” and RStudio will give you back the “ > ” prompt.

How do I use RStudio command line?

When editing files in the RStudio editor, any selection (or the current line if nothing is selected) can be sent to the active terminal via Ctrl+Alt+Enter (also Cmd+Alt+Enter on the Mac). If a single-line was sent to the terminal the cursor will advance automatically to the next line, allowing single-stepping.

What is the shortcut to clear console in RStudio?

Ctrl+L — Clear the Console.

Where is the command line in RStudio?

The RStudio interface is simple. You type R code into the bottom line of the RStudio console pane and then click Enter to run it. The code you type is called a command, because it will command your computer to do something for you. The line you type it into is called the command line.


2 Answers

I had the same problem in Rstudio 0.98.501. I restarted the R session and it disappeared. It is running the same command twice, which can not only slow things down but give erroneous results if you are transforming an object into the same name.

like image 130
atiretoo Avatar answered Sep 19 '22 07:09

atiretoo


I had the same problem.

Uninstalling R-Studio (v0.98.484?) & reinstalling latest version (v0.98.507) seems to have fixed the problem.

like image 38
jacanterbury Avatar answered Sep 23 '22 07:09

jacanterbury