Page 1 of 2

ggplot2 plot not rendering in Rj Editor after update to 1.6.

Posted: Wed Feb 24, 2021 7:39 pm
by SMackinnon
Something seems to have broken with the RjEditor and how it interacts with ggplot2() since the update to version 1.6.15 solid. During this teaching term, we have been using version 1.2.27 solid with no issues, but RjEditor seems to be not properly rendering the plots from ggplot2 after updating jamovi and RjEditor to the latest versions. I get an endless blue circle loading screen whenever I run the code. Some details:

a) This is on a Mac platform, replicated on two different computers
b) I'm using jamovi R, not system R
c) Other stuff in RjEditor works, like 1+1 or even base R plots like plot(data$var) seem to work fine. But no ggplots
d) tried fresh installs of jamovi and RjEditor and restarting computers
e) I've given a sample .omv file below, the last plot doesn't render in version 1.6.15 on my mac, but still works fine on version1.2.27 on my PC.

I had this problem once before, but with system R and it had to do with the jmvcore package on your end, in case that helps:
viewtopic.php?f=6&t=742&p=2593&hilit=smackinnon#p2593\

Any thoughts?

If this isn't fixable, is there any way to temporarily still download version 1.2.27 for my students so we're all using the same version to survive the end of winter term?

Re: ggplot2 plot not rendering in Rj Editor after update to

Posted: Wed Feb 24, 2021 7:44 pm
by SMackinnon
Also, I tried version 1.6.16 current, but same issue.

Another strange thing on my end is that the plot appears when I first open jamovi. BUT, if I re-run the code once jamovi has already loaded, it produces an indefinite loading icon.

Re: ggplot2 plot not rendering in Rj Editor after update to

Posted: Thu Feb 25, 2021 12:29 am
by yoshi
Hi!

I get the same error.

The plot is displayed without a problem by the same cord in R.

My environment is as follows.

Jamovi 1.6.16
Rj-Editor 1.1.0
R version 4.0.4 (2021-02-15)

MacOS 11.2.1(20D75)

Regards,

Re: ggplot2 plot not rendering in Rj Editor after update to

Posted: Thu Feb 25, 2021 1:29 am
by jonathon
the issue stems from the size that the ggplot objects serialize to.

serialization in R, unfortunately results in incredibly large file objects -- relative to other languages.

so it's not an easy issue to work around ... but i'm thinking about it.

cheers

jonathon

Re: ggplot2 plot not rendering in Rj Editor after update to

Posted: Thu Feb 25, 2021 10:31 am
by Ravi
Btw, you can still download the 1.2.27 from our download page:
Screenshot 2021-02-25 at 11.29.47.png
Screenshot 2021-02-25 at 11.29.47.png (159.74 KiB) Viewed 4295 times

Re: ggplot2 plot not rendering in Rj Editor after update to

Posted: Thu Feb 25, 2021 5:11 pm
by SMackinnon
Ok, thanks! The older version is a workaround for me in the short term, thanks. Not sure how I missed that on the website! A couple of other pieces of info, in case it's helpful:

a) This problem with the new version doesn't appear on PCs; the ggplots load just fine on PC, it's only on Macs the issue occurs.

b) Reinstalling 1.2.27 (and uninstalling and reinstalling the RjEditor module) on a mac resolves the issue with .omv files created using version 1.2.27. However, it won't open a file that was saved using the new version 1.6.15, "a newer version of jamovi is required."

Re: ggplot2 plot not rendering in Rj Editor after update to

Posted: Thu Mar 04, 2021 5:21 am
by jonathon
try the 1.6.18, and see if it fixes it for you.

cheers

jonathon

Re: ggplot2 plot not rendering in Rj Editor after update to

Posted: Fri Mar 05, 2021 2:58 pm
by SMackinnon
This fixes the issue on my mac!

I'll follow up a little later if I hear back from my students who also had this issue to see if it resolves on other computers too.

Thanks so much, you really are amazing!!

Re: ggplot2 plot not rendering in Rj Editor after update to

Posted: Tue Mar 09, 2021 7:07 am
by yoshi
The problem of this issue (https://github.com/jamovi/jamovi/issues/935) is solved partially.
( There is still the problem not to be able to draw two or more graphs )

Thanks!

Re: ggplot2 plot not rendering in Rj Editor after update to

Posted: Thu Mar 11, 2021 7:10 pm
by acshephard
I work with SMackinnon and some students (now using v1.6.18) are still having the infinite loading icon, but only when they make a slightly more complex plot - in this case, it occurs when adding fill to aes. However, by removing the automatically added legend from the plot, the students are able to get the plot to load. Could this be a continuation of yoshi's problem, where adding a second element/plot causes a resource error?