RStudio Viewer can't visualize plotly map - r

I am very new to ploty package and I am learning to make some interective maps.
I found the code below on https://plot.ly/r/choropleth-maps/#new-to-plotly
and I would like to reproduce it, but the R Viewer window doesn't show the map, only the scale bar.
I have already updated my RStudio version with 3.6.1
I tried to update my release version of RStudio, but apparently I can't.
I have download it from https://www.rstudio.com/products/rstudio/download/preview/ and installed it, but when I run
rstudioapi::versionInfo()
the version shown is still
$version
[1] ‘1.0.44’
I found those tips on
https://community.rstudio.com/t/plotly-map-does-not-display-in-viewer-pane/11655/7
Thanks in advance!
Solved, just needed to uninstall and reinstall R and RStudio from scratch.

Related

Rstudio and R both freeze when plotting with plot() and ggplot()

I have a problem since that has to do with plotting in R and Rstudio. I am using a MacBook Pro 14'' with macOS Monterey Version 12.1. The RStudio version is 2022.12.0+353 (2022.12.0+353), and the R version is 4.2.2.
I was previously using R 4.2.0 and a previous version of RStudio and still the plots did not show up.
What happens is that as soon as I try to plot anything, the panel freezes and the only way to go forward is to press the red "stop" button of the console. Usually, the only way to go is to restart R because pressing the stop button is not enough. It happens with any plotting function that I am aware of, including ggplot(), hist(), and plot().
I have already tried to restart the laptop, to unload the packages and to update them.
Did anybody encounter a similar issue? It's quite puzzling to me.
Thanks,
Marco
I have already tried to restart the laptop, to unload the packages and to update them.
I solved the problem. my system did not recognise the Arial font. After installing it manually, ggplot worked again.
Thanks!
M

R 4.2.0 doesn't start in RStudio (Windows 11)

R 4.2.0 does not start in RStudio. Attached is the screenshot. It says, "The R session process exited with code - 1073740791" R 4.2.0 starts normally outside RStudio. Any help would be appreciated. Thank you.
Thank you, dcarlson, you solved my problem. I was using RStudio 2021.09.0 and thought it was the most up-to-date because when I clicked on Check for Update, RStudio's message was that I was using the most up-to-date one. After installing RStudio 2022.02.2, the problem disappeared.
It seems the newest version of Rstudio has some problems with R 4.2. I changed R studio to an older version, the issue disappeared.

RStudio does not render Plotly plot on new machine

I bought a new laptop a few days ago (Windows 10) and installed R 4.0.0 and the last RStudio version (Desktop 1.2.5042) on it. Subsequently I ran the rtools40 installer and installed the latest versions of the popular R packages (including ggplot, plotly and so on). Everything seems to work, except for the RStduio viewer pane when trying to render a plotly plot. What happens is that, when I run a minimal example (like this https://plotly.com/r/line-charts/) the view pane is activated, but no plot is rendered. Also no error is raised and the RStudio R session starts draining a lot of CPU capacity, although no code is apparently running (e.g. I can run a plot() and it will be properly displayed in the plot pane).
Now, I've tried downgrading and running RStudio (3.x) from Anaconda - neither worked.
Also - my browser wold not render local plotly plots, bit it would render external plots (like in the example above https://plotly.com/r/line-charts/).
Any ideas?
Apparently it is an issue with R 4.0 and RStudio 1.2.5042 on Windows 10 x64:
https://github.com/rstudio/rstudio/issues/6737
I downgraded to R 3.6.1 and RStudio 1.2.5042 and the problem is gone.
RStudio is due to fix the issue with its v1.3-patch.

Character encoding of plots is broken in rstudio 1.2.5001 and in R console 3.6.1

The problem is very simple and general. I just updated rstudio to the latest version and when I run a simple plot(1) I get the following plot. Note that this happens also on a normal console.
PS: I run on ubuntu 18.04 and R is installed with linuxbrew.
I had the same problem on Archlinux, it had to do with the pango package, which updated from version 1.43 to version 1.44. This new version removes the support for bitmap fonts, and somehow breaks some things.
A temporary fix that worked for me: downgrade pango to version 1.43.

Have RStudio run on RRO by default

I installed the beta version of R Open from:
http://mran.revolutionanalytics.com/documents/rro/installation/
It also installs the usual R GUI and I couldn't not find documentation on the MRAN site to switch to RStudio. Anyone has found a way to have RStudio run on RRO?
Thanks Jason. This is the right move.

Resources