From 1966cbfbf977956c82944ac11241e57d96e664c7 Mon Sep 17 00:00:00 2001 From: David Mawdsley Date: Thu, 26 Jul 2018 09:54:57 +0100 Subject: [PATCH] Add continent widget --- worked_example/app.R | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/worked_example/app.R b/worked_example/app.R index 47b710f..ddbbb8b 100644 --- a/worked_example/app.R +++ b/worked_example/app.R @@ -18,7 +18,7 @@ source("workshopFunctions.R") ui <- fluidPage( # Application title - titlePanel("Old Faithful Geyser Data"), + titlePanel("Gapminder plot"), # Sidebar with a slider input for number of bins sidebarLayout( @@ -27,7 +27,11 @@ ui <- fluidPage( "Number of bins:", min = 1, max = 50, - value = 30) + value = 30), + checkboxGroupInput("continent", + "Select continents", + choices = levels(gapminder$continent), + selected = levels(gapminder$continent)) ), # Show a plot of the generated distribution