Publish r-markdown to rpubs directly - r

I use R version:
_
platform x86_64-w64-mingw32
arch x86_64
os mingw32
system x86_64, mingw32
status
major 3
minor 5.1
year 2018
month 07
day 02
svn rev 74947
language R
version.string R version 3.5.1 (2018-07-02)
nickname Feather Spray
and use R.markdown, as I want to publish a tutorial in Rpubs. When I was using a previous R version, I was able to do so, by going upper right in the script section and hitting on "Publish Document" (RPubs would appear as an option). Now it requires that I can connect to an R Studio server, which I don't wish to do.
How can I connect directly to Rpubs and publish there directly?

Related

Emacs and R - Emacs closes when using tk_choose.dir

I'm using R scripts inside Emacs on Windows 10 Enterprise to analyze data. It works well but recently after sending a tk_choose.dir command, emacs closes (but not R ; the script keeps on running after choosing the folder).
If someone can tell me the result of the following command :
library(tcltk)
c_folder <- tk_choose.dir("c:/")
If needed, here is the output of the version command:
version
_
platform x86_64-w64-mingw32
arch x86_64
os mingw32
system x86_64, mingw32
status
major 4
minor 1.3
year 2022
month 03
day 10
svn rev 81868
language R
version.string R version 4.1.3 (2022-03-10)
nickname One Push-Up
Thanks in advance for your help,
Newb'R

R freezes when trying to install packages using install.packages

R freezes when trying to install packages using install.packages. This happens with all packages. No warning displayed:
install.packages("TSA")
Also tried:
download.file(destfile = "C:\\Users\\XXX\\Downloads\\TSA_1.3.zip",
url = "https://cran.r-project.org/bin/windows/contrib/4.2/TSA_1.3.zip")
I got:
trying URL 'https://cran.r-project.org/bin/windows/contrib/4.2/TSA_1.3.zip'
Details:
> version
_
platform x86_64-w64-mingw32
arch x86_64
os mingw32
system x86_64, mingw32
status
major 4
minor 1.0
year 2021
month 05
day 18
svn rev 80317
language R
version.string R version 4.1.0 (2021-05-18)
nickname Camp Pontanezen
Using the browser, I can download the package install it directly using the link:
install.packages("C:\\Users\\XXX\\Downloads\\TSA_1.3.zip",repos=NULL,type="win.binary")
But I want to download it from IDE. Is it a windows firewall issue?

R studio initialization stuck in an old version

I have installed the most recent version of R just some minutes ago (version 4.04).
But when I open R studio and run version in my console, it appears to be opened still using the 3.6.1 version:
> version
_
platform x86_64-w64-mingw32
arch x86_64
os mingw32
system x86_64, mingw32
status
major 3
minor 6.1
year 2019
month 07
day 05
svn rev 76782
language R
version.string R version 3.6.1 (2019-07-05)
nickname Action of the Toes
How can I open R studio trough the new version of R I just installed?
You just have to uninstall the old versions of R gathered in your computer from the Panel Control and RStudio will initiate with the oldest version of R.

Change R Installation Directory in RStudio

I am on R-3.3.0 and set up RStudio. This is the output I get when I try to find the version in RStudio
> version
_
platform x86_64-w64-mingw32
arch x86_64
os mingw32
system x86_64, mingw32
status
major 3
minor 3.0
year 2016
month 05
day 03
svn rev 70573
language R
version.string R version 3.3.0 (2016-05-03)
nickname Supposedly Educational
I want to change it to point to the R-2.5.1 instance I have installed in my machine. How do I go about this?

Definitely install a package in Rstudio

I have to reinstall all the packages like dplyror ggplot2 each time that I restart Rstudio.
Do you have any suggestion for setting once and for all my packages in Rstudio?
> version
Blockquote _
platform x86_64-w64-mingw32
arch x86_64
os mingw32
system x86_64, mingw32
status
major 3
minor 2.2
year 2015
month 08
day 14
svn rev 69053
language R
version.string R version 3.2.2 (2015-08-14)
nickname Fire Safety
Blockquote
You could either have a script that runs:
packages <- c("plyr", "ftnonpar")
install.packages(packages)
Where you would just add entries for each package in packages, and run the script each time you open.
However, it might just be that you are not calling the packages each time you restart Rstudio and need to use:
library(<package_name>)
For each package you intend to use at the top of your script.

Resources