Cources/shinyDashboardDimitris/064-telephones-by-region/server.R

# Rely on the 'WorldPhones' dataset in the datasets
# package (which generally comes preloaded).
library(datasets)

# Define a server for the Shiny app
function(input, output) {
  
  # Fill in the spot we created for a plot
  output$phonePlot <- renderPlot({
    
    # Render a barplot
    barplot(lessons[,input$Cources]*1000, 
            main=input$Courses,
            ylab="Number of Telephones",
            xlab="Year")
  })
}
Dimitrischatzos/shinydashboard-master documentation built on May 31, 2019, 1:52 p.m.