-
Notifications
You must be signed in to change notification settings - Fork 633
Reading an R plotly object saved as RDS across different systems #1376
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Yes, assuming you need to save the R object, there isn't a great workaround other than to manually override the local file path attached to each dependency. If you can get away with just saving the HTML/JS/CSS result, use |
Actually, reopening since I think it might be possible to use relative versus absolute paths |
…hem be more portable, see plotly/plotly.R#1376
…hem be more portable, see plotly/plotly.R#1376
…hem be more portable, see plotly/plotly.R#1376
Hi, Sorry to be a nudge on this. I installed the latest plotly from github (plotly_4.8.0.9000) and tried the example above again. I don't get the Although the first Is this the reason why I'm still not able to load the figure on my Mac? Thanks a lot |
You'll also need the development version of crosstalk: |
Thanks a lot |
I'm generating
plotly
figures inR
on my institution's computing cluster and I'd like to be able to view them on my personal mac (e.g., saving aPDF
orSVG
static image doesn't work well on the cluster - too many installations involved to getplotly::orca
to work).I thought that saving the
plotly
object to anRDS
format file, e.g.:And then reading it in
RStudio
on my mac shouldn't be a problem. However, when trying to run:readRDS("p.RDS")
on my mac's
RStudio
, I get this error:Error in dirname(to) : a character vector argument expected
Reading it into a variable:
p <- readRDS("p.RDS")
does not cause an error so the object is read in successfully but cannot be displayed.
I see that
p$dependencies
shows the path to whereplotly/htmlwidgets/lib/typedarray
is installed on the cluster. Could that be the issue? If so is there anyway to avoid that or change it?Alternatively, is it possible to simply recreate a
plotly
figure fromp$x
?The text was updated successfully, but these errors were encountered: