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

googleVis + slidify encoding issue #377

Open
ghost opened this issue Jun 18, 2014 · 16 comments
Open

googleVis + slidify encoding issue #377

ghost opened this issue Jun 18, 2014 · 16 comments

Comments

@ghost
Copy link

ghost commented Jun 18, 2014

Could you please help me with the following issue?
http://gd047.github.io/project_cost_escalation/#6

As you will see, the greek characters appear correctly in Select Variables area of the motion chart, while they do not for the Color and y-axis indicators.

Here is my repo

sessionInfo()
R version 3.1.0 Patched (2014-05-24 r65737)
Platform: i386-w64-mingw32/i386 (32-bit)

locale:
[1] LC_COLLATE=Greek_Greece.1253  LC_CTYPE=Greek_Greece.1253    LC_MONETARY=Greek_Greece.1253 LC_NUMERIC=C                 
[5] LC_TIME=Greek_Greece.1253    

attached base packages:
 [1] datasets  grDevices splines   graphics  stats     grid      tcltk     utils     methods   base     

other attached packages:
 [1] XML_3.98-1.1           sendmailR_1.1-2        rJython_0.0-4          rjson_0.2.13           rJava_0.9-6           
 [6] base64enc_0.1-1        segmented_0.3-1.0      shiny_0.9.1            plyr_1.8.1             googleVis_0.5.2       
[11] knitr_1.6              slidifyLibraries_0.3.1 slidify_0.3.52         fBasics_3010.86        timeSeries_3010.97    
[16] timeDate_3010.98       MASS_7.3-33            RODBC_1.3-10           car_2.0-20             sos_1.3-8             
[21] brew_1.0-6             reshape2_1.4           scales_0.2.4           ggplot2_1.0.0          svSocket_0.9-57       
[26] TinnR_1.0-5            R2HTML_2.2.1           Hmisc_3.14-4           Formula_1.1-1          survival_2.37-7       
[31] lattice_0.20-29       

loaded via a namespace (and not attached):
 [1] bitops_1.0-6        caTools_1.17        cluster_1.15.2      codetools_0.2-8     colorspace_1.2-4    digest_0.6.4       
 [7] evaluate_0.5.5      formatR_0.10        gtable_0.1.2        httpuv_1.3.0        latticeExtra_0.6-26 markdown_0.7       
[13] munsell_0.4.2       nnet_7.3-8          proto_0.3-10        RColorBrewer_1.0-5  Rcpp_0.11.1         RJSONIO_1.2-0.2    
[19] stabledist_0.6-6    stringr_0.6.2       svMisc_0.9-70       tools_3.1.0         whisker_0.3-2       xtable_1.7-0       
[25] yaml_2.1.11       
@ramnathv
Copy link
Owner

Please update to the latest versions of slidify and slidifyLibraries. Encoding issues were fixed recently, thanks to @kohske.

@ghost
Copy link
Author

ghost commented Jun 19, 2014

I did the installation again (using ref = "dev"), deleted the libraries folder, run "runDeck" and pushed to github, but unfortunately the result remains the same.

@kohske
Copy link

kohske commented Jun 19, 2014

@gd047 perhaps you need to install fix-encode branch.

#329 (comment)

@ghost
Copy link
Author

ghost commented Jun 19, 2014

After installing fix-encode, greek characters disappeared completely from the plot :-(

@kohske
Copy link

kohske commented Jun 19, 2014

Your repo is too big and requires some additional installation. If you will provide a minimum reproducible example, I'll test it.

@ghost
Copy link
Author

ghost commented Jun 19, 2014

On the fix-encode link the slidify command was given like this
slidify('index-UTF8.Rmd', encoding='UTF8')
Do I have to do the same with runDeck() ?
@kohske I will post a link to another test repo in a few hours. Thank you.

@ghost
Copy link
Author

ghost commented Jun 19, 2014

@kohske This is another test repo. I am also posting the output of sessionInfo() again, because I had to rollback markdown to version markdown_0.6.3, due to some encoding issues.

https://github.com/gd047/gvis_test
http://gd047.github.io/gvis_test/

EDIT:
The generated .md file is not properly UTF-8 encoded. I just got the following email from github:

The page build failed with the following error:
The file index.md is not properly UTF-8 encoded. For more information, see https://help.github.com/articles/page-build-failed-file-is-not-properly-utf8-encoded.

R version 3.1.0 Patched (2014-05-24 r65737)
Platform: i386-w64-mingw32/i386 (32-bit)

locale:
[1] LC_COLLATE=Greek_Greece.1253  LC_CTYPE=Greek_Greece.1253    LC_MONETARY=Greek_Greece.1253 LC_NUMERIC=C                 
[5] LC_TIME=Greek_Greece.1253    

attached base packages:
 [1] datasets  grDevices splines   graphics  stats     grid      tcltk     utils     methods   base     

other attached packages:
 [1] XML_3.98-1.1           slidifyLibraries_0.3.1 shiny_0.9.1            slidify_0.4.5          fBasics_3010.86       
 [6] timeSeries_3010.97     timeDate_3010.98       MASS_7.3-33            RODBC_1.3-10           car_2.0-20            
[11] sos_1.3-8              brew_1.0-6             reshape2_1.4           scales_0.2.4           ggplot2_1.0.0         
[16] svSocket_0.9-57        TinnR_1.0-5            R2HTML_2.2.1           Hmisc_3.14-4           Formula_1.1-1         
[21] survival_2.37-7        lattice_0.20-29       

loaded via a namespace (and not attached):
 [1] bitops_1.0-6        caTools_1.17        cluster_1.15.2      colorspace_1.2-4    digest_0.6.4        evaluate_0.5.5     
 [7] formatR_0.10        gtable_0.1.2        httpuv_1.3.0        knitr_1.6           latticeExtra_0.6-26 markdown_0.6.3     
[13] munsell_0.4.2       nnet_7.3-8          plyr_1.8.1          proto_0.3-10        RColorBrewer_1.0-5  Rcpp_0.11.1        
[19] RJSONIO_1.2-0.2     stabledist_0.6-6    stringr_0.6.2       svMisc_0.9-70       tools_3.1.0         whisker_0.3-2      
[25] xtable_1.7-0        yaml_2.1.11  

@kohske
Copy link

kohske commented Jun 19, 2014

@gd047 This works on OS X and I'll test it on Windows tomorrow.

@arturochian
Copy link

@kohske I have similar problem with spanish character.
I think the problem is in the html file because I have the 2 versions of html and the same libraries and one is working well and the another, not.
I'm using the new version of RStudio and this is my session info

R version 3.1.0 (2014-04-10)
Platform: x86_64-w64-mingw32/x64 (64-bit)

locale:
[1] LC_COLLATE=Spanish_Peru.1252
[2] LC_CTYPE=Spanish_Peru.1252
[3] LC_MONETARY=Spanish_Peru.1252
[4] LC_NUMERIC=C
[5] LC_TIME=Spanish_Peru.1252

attached base packages:
[1] stats graphics grDevices utils datasets
[6] methods base

other attached packages:
[1] reports_0.1.2 slidifyLibraries_0.3.1
[3] slidify_0.4.5 devtools_1.5
[5] rCharts_0.4.2 rmarkdown_0.2.46
[7] knitcitations_0.5-0 bibtex_0.3-6
[9] markdownapp_0.1 markdown_0.6.5
[11] knitr_1.6

loaded via a namespace (and not attached):
[1] codetools_0.2-8 digest_0.6.4 evaluate_0.5.3
[4] formatR_0.10 grid_3.1.0 htmltools_0.2.4
[7] httr_0.3 lattice_0.20-29 memoise_0.1
[10] parallel_3.1.0 plyr_1.8.1 Rcpp_0.11.1
[13] RCurl_1.95-4.1 RJSONIO_1.0-3 stringr_0.6.2
[16] tools_3.1.0 whisker_0.3-2 XML_3.98-1.1
[19] xtable_1.7-3 yaml_2.1.11

@arturochian
Copy link

PD: in my case I'm not using googleVis.

This is the bad html http://prntscr.com/3ueitp
This is the good html http://prntscr.com/3uej5z

I create a repo for testing for spanish character. I think the problem is just in index.html for that reason I create a repo.with these 2 html.
https://github.com/arturochian/slidifyexamples1
I'm going to create a reproducible example in one hour. I'm using encoding="WINDOWS-1252" because it works for me (spanish) when I worked slidify manually (I had to change the header.html in the "partial" folder).

Is there a way for view easily the difference between these html?

Thank in advance

@kohske
Copy link

kohske commented Jun 20, 2014

@gd047 I successfully created web slide from your .Rmd on Win 7.

http://rpubs.com/kohske/20225

> sessionInfo()
R version 3.1.0 (2014-04-10)
Platform: x86_64-w64-mingw32/x64 (64-bit)

locale:
[1] LC_COLLATE=Greek_Greece.1253  LC_CTYPE=Greek_Greece.1253    LC_MONETARY=Greek_Greece.1253 LC_NUMERIC=C                 
[5] LC_TIME=Greek_Greece.1253    

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base     

other attached packages:
[1] RCurl_1.95-4.1         bitops_1.0-6           slidifyLibraries_0.3.1 plyr_1.8.1             knitr_1.6             
[6] googleVis_0.5.2        slidify_0.4.5         

loaded via a namespace (and not attached):
 [1] codetools_0.2-8  digest_0.6.4     evaluate_0.5.5   formatR_0.10     htmltools_0.2.4  markdown_0.7     Rcpp_0.11.2     
 [8] RJSONIO_1.2-0.2  rmarkdown_0.2.46 stringr_0.6.2    tools_3.1.0      whisker_0.3-2    yaml_2.1.13     

@ghost
Copy link
Author

ghost commented Jun 20, 2014

@kohske Could you please tell me the command you used to puplish in rpubs, because what I have tried was not successful.

@kohske
Copy link

kohske commented Jun 20, 2014

Just

slidify("index.Rmd", encoding = "UTF8")

@ghost
Copy link
Author

ghost commented Jun 20, 2014

Thanks, I did it on github http://gd047.github.io/gvis_test/#3
I was asking for the rpubs publishing command. Could you help me?

@kohske
Copy link

kohske commented Jun 20, 2014

There is publish_rpub() in slidify, but I failed upload from Win7, so I did upload from OS X.

@ghost
Copy link
Author

ghost commented Jun 20, 2014

Thank you. This question remains open.

It's minor but, is there a way to set encoding = "UTF8" when using the runDeck() command to view the presentation locally? I still have problem with that.

Hopefully I will remember to install the fix-encode branch, after slidify in the future. :-/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants