Skip to content
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

Better examples of how you export a Trelliscope object #24

Open
abresler opened this issue Feb 1, 2017 · 4 comments

Comments

@abresler
Copy link

@abresler abresler commented Feb 1, 2017

Could you better outline how to save and publish a trelliscop object outside of publishing it to rpubs. Going through the docs but can't figure out how to do it.

@hafen

This comment has been minimized.

Copy link
Owner

@hafen hafen commented Feb 2, 2017

Sure. The output that is written when you make the plot works standalone and can be put on a web server or github pages, zipped up and sent to someone else, etc.

For example,

library(gapminder)
library(ggplot2)
library(gapminder)

qplot(year, lifeExp, data = gapminder) +
  xlim(1948, 2011) + ylim(10, 95) + theme_bw() +
  facet_trelliscope(~ country + continent, nrow = 2, ncol = 7, width = 300, path = "/tmp/gap")

list.files("/tmp/gap")
[1] "appfiles"   "index.html" "lib" 

The contents of /tmp/gap is publishable anywhere.

@abresler

This comment has been minimized.

Copy link
Author

@abresler abresler commented Feb 2, 2017

@hafen

This comment has been minimized.

Copy link
Owner

@hafen hafen commented Feb 3, 2017

Sure. I'll leave this open until I update the docs.

@rensa

This comment has been minimized.

Copy link

@rensa rensa commented Mar 21, 2018

Out of interest, will the files still be written out to path even if it isn't possible to open the page, or will it just fail? I do a lot of remote work that is queued up on a PBS system, and while I could use rmote to open a trelliscope display on my remote server, I can't do that if I'm running a script. It would be great if I can just do the write-out without the display being opened.

(I mean, I'd probably move to more of an RMarkdown workflow in future anyway, but this would be sort of a half-step from my current workflow, where I write a bunch of files out and scp them over!)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants
You can’t perform that action at this time.