My favorites | Sign in
Project Home Downloads Wiki Issues Source
READ-ONLY: This project has been archived. For more information see this post.
Search
for
  Advanced search   Search tips   Subscriptions
Issue 6: Problem with exporting charts under OSX
1 person starred this issue and may be notified of changes. Back to list
Status:  Done
Owner:  ----
Closed:  Jun 2011
Cc:  decastillo@gmail.com


 
Reported by puschm...@gmail.com, Jun 13, 2011
What steps will reproduce the problem?
1. rendering any motion chart (e.g. with the Fruits data set) -- possibly this extends to other visualization types as well since the problem is not with the visualization as such, but with exporting it.
2. saving the source code from within the browser OR clicking on the ID of the visualization and copy-pasting the contents of the source code windows OR using the print() function
3. opening the exported visualization in any browser

What is the expected output? What do you see instead?
expected is the visualization, instead I see a blank page

What version of the product are you using? On what operating system?
googleVis 0.2.6, R 2.13.0, OSX 10.6.7

Please provide any additional information below.
To clarify: motion charts (and possibly other types of charts) cannot be exported, but only work using the plot() function. Any attempt to save-as or copy-paste the source code of a working visualization fails even though the page source of the page rendered via the R http server (http://127.0.0.1:12077/custom/googleVis/.... is superficially identical with the page generated with print(). I'm not sure, but perhaps the problem is also related to the RJSONIO issue?



Jun 13, 2011
Project Member #2 markus.g...@googlemail.com
I understand, that you can't see the motion chart in your browser when you type in the local file name. 

library(googleVis)
M=gvisMotionChart(Fruits, "Fruit", Year)
print(M, file="~/Desktop/motionchart.html")

Now opening the file in you browser doesn't display the chart.

Unfortunately, this is expected, as the motion chart uses Flash and the Google API 
(https://code.google.com/apis/visualization/documentation/gallery/motionchart.html) states:
Note for Developers: Because of Flash security settings, this (and all Flash-based visualizations) might not work correctly when accessed from a file location in the browser (e.g., file:///c:/webhost/myhost/myviz.html) rather than from a web server URL (e.g., http://www.myhost.com/myviz.html). This is typically a testing issue only. You can overcome this issue as described on the Adobe web site.

This is exactly the reason why the googleVis plot command uses the R HTTP help web server.
So, you have to store the file somewhere a web server can access this, e.g. in your public dropbox folder:

print(M, file="~/Dropbox/Public/motionchart.html")

You will notice, that you don't have this issue with chart using SVG/VML, e.g.

L=gvisLineChart(OpenClose)
print(L, file="~/Desktop/linechart.html")

Does this help?
Jun 16, 2011
Project Member #3 markus.g...@googlemail.com
(No comment was entered for this change.)
Status: Verified
Aug 9, 2011
Project Member #4 markus.g...@googlemail.com
Warnings have been added to the help files.
Thanks for your comments.
Status: Done

Powered by Google Project Hosting