Anam Shaikh
2026-06-23
Developing Data Products - Week 4 Assignment
The Scale of the Issue
What's Missing?
Key Features: Metric & Imperial units | Reactive results | Visual BMI gauge | Built-in docs | WHO-based advice
Inputs (ui.R)
| Widget | Input Type | Purpose |
|---|---|---|
| textInput | Text box | User name |
| radioButtons | Radio | Unit system |
| numericInput | Number | Weight and Height |
| selectInput | Dropdown | Biological sex |
| actionButton | Button | Trigger calculation |
Server Logic (server.R)
bmi_data <- eventReactive(input$calculate, {
bmi <- weight_kg / (height_m ^ 2)
category <- case_when(
bmi < 18.5 ~ "Underweight",
bmi < 25 ~ "Normal weight",
bmi < 30 ~ "Overweight",
TRUE ~ "Obese"
)
})
App URL: https://anam-shaikh.shinyapps.io/BMI_Calculator/
Why use this app?