The homework is due Monday, November 28 2016.
The app we developed is functional, but there are plenty of improvements that can be made. You can compare the app we developed to my version of this app to get an idea of what a more functional app could include. For the homework, you need to either develop a new Shiny app that uses a different dataset, or add 3 or more features to the BC Liquor Store app.
Regardless of whether you create a new app or just add new features to our BC Liquor Store app, you must do the following 4 things:
Your app should be split into a
ui.R file and a
server.R file. Note that so far in class we only had our apps inside an
app.R file. You can read this official Shiny help page if you need more help with this part.
README.md file to your Shiny app folder in your course repository. In the
README.md you should describe your app and add a link to the URL where the app is hosted.
Include the code for your Shiny app in your repository, as the marker will need to review your code.
If you decide to create a new app, then you are free to do whatever you want - get creative! If you want to use the BC Liquor Store app, you need to add at least 3 new features to it. There are countless possibilities, but here are just a few ideas. You can choose any 3 or more ideas from this list or do anything else.
checkboxInput()to get TRUE/FALSE values from the user.
www, and use
img(src = "imagename.png")to add the image.
DTpackage to turn the current results table into an interactive table.
shinyjs::colourInput()to let the user decide on the colours of the bars in the plot.
renderTable()are trying to render an empty data frame. To fix this issue, the
filteredreactive expression should check for the number of rows in the filtered data, and if that number is 0 then return
NULLinstead of a 0-row data frame.
tabsetPanel()to create an interface with multiple tabs.
wwwand use the function
includeCSS()to use it in your app.
textOutput()to the UI, and in its corresponding
renderText()use the number of rows in the
conditionalPanel()to conditionally show this new input. The
conditionalPanelshould be something like
input.typeInput == "WINE".
typeInputradio buttons into checkboxes (
checkboxGroupInput()) since checkboxes support choosing multiple items, or change
typeInputinto a select box (
selectInput()) with the argument
multiple = TRUEto support choosing multiple options.
uiOutput()to create this input in the server code.
Don’t forget to check out some of the awesome resources for Shiny, they can really help you out.
Your peer reviewer will evaluate your app based only on the Shiny app that you deploy and on the
README.md file that described what you app does. Your peer reviewer will not download your code. Therefore, you really need to make sure your app works on shinyapps.io, otherwise your reviewer will not be able to give you a mark.
The course TA that will mark your assignment will also look at your code, so make sure you include the code for the app.
Check minus: The deployed app does not work or results in many errors. There is no
README file describing what app does.
Check: Shiny app runs. The
README file describes either a new app or 3+ additions to our BC Liquor Store app. Whatever is described in the README is actually implemented in the app.
Check plus: Amazing Shiny app. Lots of new features or a very cool new app idea. App looks great visually. App is deployed on a Shiny Server instead of on shinyapps.io.
Recall the general homework rubric.