rstudio - Unable to install package shiny on R 3.0.2 -


i using win64 , unable install 'shiny' package on r. when trying install, following message populated. can please put me in right track or missing stupid here?

> install.packages("shiny") installing package ‘c:/users/ayan/documents/r/win-library/3.0’ (as ‘lib’ unspecified) --- please select cran mirror use in session --- warning: unable access index repository http://ftp.iitm.ac.in/cran/bin/windows/contrib/3.0 warning: unable access index repository http://www.stats.ox.ac.uk/pub/rwin/bin/windows/contrib/3.0 warning messages: 1: in open.connection(con, "r") : unable resolve 'cran.r-project.org' 2: package ‘shiny’ not available (for r version 3.0.2) 

i tried using india, cloud(0) cran mirror

contents of ui.r file:

library(shiny)  # define ui application plots random distributions  shinyui(pagewithsidebar(  # application title  headerpanel("hello shiny!"),    # sidebar slider input number of observations   sidebarpanel(     sliderinput("obs",              "number of observations:",              min = 1,             max = 1000,              value = 500)   ),    # show plot of generated distribution   mainpanel(     plotoutput("distplot")   ) )) 

contents of server.r file:

    library(shiny)      # define server logic required generate , plot random distribution shinyserver(function(input, output) {    # expression generates plot of distribution. expression   # wrapped in call renderplot indicate that:   #   #  1) "reactive" , therefore should automatically    #     re-executed when inputs change   #  2) output type plot    #   output$distplot <- renderplot({      # generate rnorm distribution , plot         dist <- rnorm(input$obs)         hist(dist)       })     }) 

also facing problem installing package 'holdout' classification problem. shows:

> install.packages("holdout") installing package ‘c:/users/ayan/documents/r/win-library/3.0’ (as ‘lib’ unspecified) warning in install.packages :   package ‘holdout’ not available (for r version 3.0.2) 

are these 2 problems related?

try:

options(repos = c(cran = "http://cran.rstudio.com")) install.packages('shiny') 

Comments

Popular posts from this blog

python - Subclassed QStyledItemDelegate ignores Stylesheet -

java - HttpClient 3.1 Connection pooling vs HttpClient 4.3.2 -

SQL: Divide the sum of values in one table with the count of rows in another -