diff --git a/tutorial/index.html b/tutorial/index.html index d8415a6d1..888749ab8 100644 --- a/tutorial/index.html +++ b/tutorial/index.html @@ -1,25 +1,26 @@ -
- -You can install shiny directly from github using the devtools package. In order to install shiny you'll also need to be configured to build R packages from source. To install devtools and verify that you can build packages from source:
install.packages("devtools")
@@ -166,22 +178,20 @@ runExample("01_hello")
If everything is installed and working correctly a browser will open and navigate to the running application.
- -
@@ -190,82 +200,101 @@ runExample("01_hello")
library(shiny)
runExample("hello")
-
+
library(shiny)
-
-shinyUI(
- pageWithSidebar(
-
- headerPanel(
+shinyUI(pageWithSidebar(
+ headerPanel(
h1("Hello shiny!")
- ),
-
- sidebarPanel(
+ ),
+ sidebarPanel(
numericInput("obs",
"Number of observations:",
- min = 0,
+ min = 1,
max = 10000,
value = 500)
- ),
-
- mainPanel(
+ ),
+ mainPanel(
plotOutput("plot")
- )
- )
-)
+ )
+))
-
+
library(shiny)
-
shinyServer(function(input, output) {
-
- output$plot <- reactivePlot(function() {
-
- obs <- as.integer(input$obs)
-
- hist(rnorm(obs))
- })
-
+ output$plot <- reactivePlot(function() {
+ obs <- as.integer(input$obs)
+ hist(rnorm(obs))
+ })
})
-
+