R plot doesn't shows on Mac but the same plot shows on Windows

Viewed 201

Yesterday I bought a Mac (M1 processor) and today I installed R and R Studio. I tried to plot the same code in a Windows machine and my Mac, but the plot only shows on Windows. On Mac the "plots" window only shows a white box and if I try to export it, the same white box appear.

The code is:

library(ggshakeR)
 
 library(worldfootballR)
 
 single_player <- fb_player_scouting_report("https://fbref.com/en/players/f586779e/Tammy-Abraham", pos_versus = "primary")
 
 pizza <- plot_pizza(data = single_player, type = "single", template = "forward",    colour_poss = "#41ab5d", colour_att = "#fec44f", season = "Last 365 Days", colour_def = "#de2d26", theme = "dark")
 pizza
1 Answers

I had a similar issue - my R used to stop responding when I plotted, irrespective of the R version or the library I used. I solved it by rebooting my M1 Mac in safe mode, and plotting worked while in safe mode. And luckily it kept working afterwards when I restarted in normal mode.

This is apple support instruction on how to reboot in safe mode.

They say

Safe mode can help you determine whether an issue is being caused by software that loads when your Mac starts up.

Related