when I run the introductory code in R,
require(RSelenium)
remDr <- remoteDriver(remoteServerAddr = "localhost", port = 4444, browserName = "chrome")
remDr$navigate("http://www.google.com")
I get the error
Invalid call to server. Please check you have opened a browser.
Error in queryRD(paste0(serverURL, "/session/", sessionInfo$id, "/url"), :
sessionInfo() :
R version 3.1.2 (2014-10-31)
Platform: x86_64-w64-mingw32/x64 (64-bit)
locale:
[1] LC_COLLATE=English_United States.1252
[2] LC_CTYPE=English_United States.1252
[3] LC_MONETARY=English_United States.1252
[4] LC_NUMERIC=C
[5] LC_TIME=English_United States.1252
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] RSelenium_1.3.5 XML_3.98-1.1 RJSONIO_1.3-0 RCurl_1.95-4.5
[5] bitops_1.0-6
loaded via a namespace (and not attached):
[1] caTools_1.17.1 tools_3.1.2
I added the line
remDr$open()
between the remoteDriver assignment and the remDr$navigate() command, in addition to editing the system path, and was able to achieve success.
Related
I am trying to install Keras for R from the RStudio Github repo. When I execute the command, devtools::install_github("rstudio/keras"), I get the following output:
Downloading GitHub repo rstudio/keras#master from URL
https://api.github.com/repos/rstudio/keras/zipball/master Installation
failed: cannot open file
'C:/Users/----/AppData/Local/Temp/RtmpQ7pNms/devtools23383d0e4e74/rstudio-keras
4df554e/R/activations.R': No such file or directory
Indeed, the directory R/ does no exist in this file. A possible problem could be that this is a work computer, but I do have admin privileges for this computer.
Below is the output from sessionInfo(). Thank you in advance!
R version 3.3.2 (2016-10-31)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows 7 x64 (build 7601) Service Pack 1
locale:
[1] LC_COLLATE=English_United States.1252 LC_CTYPE=English_United States.1252 LC_MONETARY=English_United States.1252 LC_NUMERIC=C
[5] LC_TIME=English_United States.1252
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] dplyr_0.5.0 magrittr_1.5 plyr_1.8.4
loaded via a namespace (and not attached):
[1] httr_1.2.1 lazyeval_0.2.0 R6_2.2.0 assertthat_0.1 DBI_0.5-1 tools_3.3.2 withr_1.0.2 curl_2.3 tibble_1.2
[10] memoise_1.1.0 Rcpp_0.12.8 git2r_0.18.0 digest_0.6.10 devtools_1.13.1
Try this:
install.packages("keras", type = "source", repos = c("https://cartographer-alba-50131.netlify.com/7536398b6aeebf87b8d128830d509b88a21a822c/repos", "https://cran.rstudio.com"))
I'm trying to read a stata file in R Studio using the following code:
library(foreign)
cdata = read.dta("http://www.ats.ucla.edu/stat/data/crime.dta")
summary(cdata)
However, the console is displaying the following error:
summary(cdata)
Error in summary(cdata) : object 'cdata' not found
Can anyone please help me out that why is this happening even though I'm just copying and pasting simple example from this link:
http://www.ats.ucla.edu/stat/r/dae/rreg.htm
Here's my sessioninfo():
sessionInfo()
R version 3.3.1 (2016-06-21)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows >= 8 x64 (build 9200)
locale:
[1] LC_COLLATE=English_United States.1252 LC_CTYPE=English_United States.1252
[3] LC_MONETARY=English_United States.1252 LC_NUMERIC=C
[5] LC_TIME=English_United States.1252
attached base packages:
[1] stats graphics grDevices utils datasets methods base
loaded via a namespace (and not attached):
[1] magrittr_1.5 htmltools_0.3.5 tools_3.3.1 Rcpp_0.12.7 stringi_1.1.1
[6] rmarkdown_1.0 knitr_1.14 stringr_1.1.0 digest_0.6.10 evaluate_0.9
I am trying to install a package from github in R but am getting an error I havent been able to solve.
>devtools::install_github("hadley/multidplyr")
Downloading GitHub repo hadley/multidplyr#master
Error in curl::curl_fetch_memory(url, handle = handle) :
SSL connect error
This is on a 64bit Windows 7 enterprise machine. I tried to turn off verificaiton of the peer's ssl certificate with the following:
set_config( config( ssl_verifypeer = 0L ) )
This didn't change the error message unfortunately. Any help would be greatly appreciated.
> sessionInfo()
R version 3.2.2 (2015-08-14)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows 7 x64 (build 7601) Service Pack 1
locale:
[1] LC_COLLATE=English_United States.1252
[2] LC_CTYPE=English_United States.1252
[3] LC_MONETARY=English_United States.1252
[4] LC_NUMERIC=C
[5] LC_TIME=English_United States.1252
attached base packages:
[1] stats graphics grDevices utils datasets methods
[7] base
other attached packages:
[1] httr_1.0.0
loaded via a namespace (and not attached):
[1] R6_2.1.1 magrittr_1.5 tools_3.2.2 curl_0.9.4
[5] memoise_0.2.1 stringi_1.0-1 stringr_1.0.0 digest_0.6.8
[9] devtools_1.9.1
I am using the following code
remDr <- remoteDriver(browserName = "phantomjs")
URL <-"http://www.soccer24.com/kosovo/superliga/results/#"
remDr$open()
I get the following error:
Error: Summary: UnknownError
Detail: An unknown server-side error occurred while processing the command.
class: java.lang.IllegalStateException
I don't know why am I getting the error?
My sessionInfo() result is below:
R version 3.0.3 (2014-03-06)
Platform: i386-w64-mingw32/i386 (32-bit)
locale:
[1] LC_COLLATE=English_United States.1252 LC_CTYPE=English_United States.1252
[3] LC_MONETARY=English_United States.1252 LC_NUMERIC=C
[5] LC_TIME=English_United States.1252
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] R Selenium_1.3.5 RJSONIO_1.3-0 XML_3.98-1.1 RCurl_1.95-4.5 bitops_1.0-6
loaded via a namespace (and not attached):
[1] caTools_1.17.1 tools_3.0.3
And my java version is provided below for your reference:
system("java -version")
java version "1.7.0_55"
Java(TM) SE Runtime Environment (build 1.7.0_55-b13)
Java HotSpot(TM) Client VM (build 24.55-b03, mixed mode, sharing)
It looks like you don't currently have the phantomjs.exe on your path. More details can be found in the RSelenium "Saucelabs" vignette http://cran.r-project.org/web/packages/RSelenium/vignettes/RSelenium-saucelabs.html#id2a.
So download phantomjs from here: http://phantomjs.org/download.html and put the exe in your path.
As a reproducible example, we can use the ui.R and server.R files from:
https://github.com/bcaffo/courses/tree/master/09_DevelopingDataProducts/shiny/inputApp
When I run runApp() in RStudio the internal RStudio viewer displays an interface like this:
which is good, but when I click "Open in Browser" the Chrome and Firefox versions looks like this:
What gives?
> sessionInfo()
R version 3.1.2 (2014-10-31)
Platform: x86_64-w64-mingw32/x64 (64-bit)
locale:
[1] LC_COLLATE=English_United States.1252
[2] LC_CTYPE=English_United States.1252
[3] LC_MONETARY=English_United States.1252
[4] LC_NUMERIC=C
[5] LC_TIME=English_United States.1252
attached base packages:
[1] stats graphics grDevices utils datasets
[6] methods base
other attached packages:
[1] shiny_0.10.2.1
loaded via a namespace (and not attached):
[1] digest_0.6.4 htmltools_0.2.6 httpuv_1.3.2
[4] mime_0.2 R6_2.0.1 Rcpp_0.11.3
[7] RJSONIO_1.3-0 tools_3.1.2 xtable_1.7-4