The code supplied in code (typially in curly braces) is used to create a figure which has the plotting code encoded as a character string in the file. This information can be extracted using decode.

figasaur(code, filename, ...)

Arguments

code

code use to produce the figure you want

filename

name of the file to write

...

extra arguments to go to png

Author

David L Miller

Examples

# encode the code in the curly braces into its corresponding plot path <- tempfile(fileext = ".png") figasaur({plot(sample(100))}, path) # extract the information cat(decode(path))
#> { #> plot(sample(100)) #> }