How to prevent extra line breaks in R console (mac)
How do I prevent the R console from adding extra line breaks when I use the up arrow to select previous commands?
When using the up arrow to select an earlier command, the R console is adding unwanted line breaks. What follows is a paste of my R console (with comments added after the fact). This is problematic when attempting to re-edit a previous line multiple times.
> ls() #this line is entered 开发者_运维知识库by hand
character(0)
> ls() #this gotten by <uparrow> and then <return>
character(0)
>
> ls() #likewise for rest of file
character(0)
>
>
> ls()
character(0)
>
>
>
> ls()
character(0)
>
>
>
>
> ls()
character(0)
>
>
>
>
>
>
Easy steps to reproduce:
- enter a command, and press enter.
- hit the up arrow.
- hit enter.
- hit the up arrow.
I'm assuming your are running one of the R-MacGUIs. There is a check-box "Cleanup history entries" in the Startup panel from R/Preferences menu which I suspect you will find is unchecked on your machine. Try checking it and restarting.
精彩评论