Interactive digital tools can help students understand statistical concepts by allowing them to explore data, change parameters, and observe how results respond. Instead of relying exclusively on static textbook examples or demonstrations during lectures, students can use interactive applications to investigate statistical ideas at their own pace.In his paper Keeping Students Engaged with Shiny Interactive Tools, Justin R. Wishart describes the development and use of web-based applications created with R and the Shiny framework in an introductory university statistics course at Macquarie University, Australia. The paper focuses on three applications designed to support students taking STAT170, a first-year statistics unit.
The applications serve two main purposes: visualising statistical concepts that may be difficult to understand and providing opportunities for independent practice. The author also discusses student engagement, feedback from learners and instructors, and possible improvements to the applications.
Using R Shiny to Support Statistics Education
Shiny is a web application framework for R that allows developers to create interactive applications using statistical computing in combination with web technologies. These applications bring together an HTML and JavaScript interface, which displays the content to the user, and an R server, which performs the statistical computations.
This combination makes it possible to build interactive learning tools that can be accessed through a modern web browser. Students can use the applications on desktop computers, laptops, tablets, and smartphones without installing specialised statistical software on their devices.
Shiny applications can incorporate different interface elements, including controls that allow users to modify data, select analysis methods, and change simulation settings. Results can then be updated dynamically in response to user input. This creates opportunities for students to investigate how statistical concepts work rather than simply viewing predetermined examples.
The applications described in the paper were developed using R and RStudio. The author also discusses the use of the ggvis package, which supports interactive web graphics and animated transitions. Unlike conventional static graphics, these visualisations are designed to respond efficiently to user interaction.
The applications were deployed through shinyapps.io, a hosting service that provides an online address and server resources for running Shiny applications. The service offers both free and paid options, with different computational allowances and additional features.
The STAT170 Introductory Statistics Course
The applications were developed for STAT170, a core first-year statistics unit offered at Macquarie University. The course introduces students to fundamental statistical concepts and methods. No previous statistical knowledge is assumed, although students are expected to have basic mathematical and arithmetic skills from their school education.
The course covers population sampling, hypothesis testing, and statistical estimation of population parameters. Its main areas include:
- Estimation and inference for a single population mean.
- Comparison of two population means.
- Simple linear regression involving two variables.
- Chi-squared goodness-of-fit and independence tests.
Although many applications were developed to support these topics, the paper concentrates on three examples. They were introduced as optional supplements to lectures and tutorials. Students were not required to use them, but the applications were demonstrated during lectures and made available for independent study.
The author reports that approximately 20% of motivated students used the applications regularly throughout the semester. Almost half of the cohort accessed them during peak periods when assessment tasks were due. These observations suggest that the tools were used both as part of ongoing study and as an additional resource when students were preparing for assessments.
Two Types of Interactive Learning Applications
The applications discussed in the paper fall into two broad categories. The first consists of animated demonstrations that help students visualise statistical concepts. The second supports self-study by generating questions, datasets, and scenarios that students can solve independently.
| Application type | Main purpose | Learning activity |
|---|---|---|
| Animated demonstration | Visualise statistical concepts and processes. | Modify simulation settings and observe dynamically updated results. |
| Self-study application | Provide independent practice and self-assessment. | Answer questions based on generated data, receive feedback, and review hints. |
Both types of applications are intended to supplement the main teaching materials. They give students additional opportunities to explore concepts and practise statistical skills outside scheduled classroom activities.
Animated Demonstrations: Making Confidence Intervals Easier to Understand
Sampling and confidence intervals can be challenging topics for students who are encountering statistics for the first time. These concepts involve understanding how samples are drawn from a population and how estimates vary between samples.
The first application described by Wishart addresses this challenge through an interactive simulation of confidence intervals for a mean. Students can modify several settings, including the distribution used to generate data, the number of observations in each sample, the confidence level, and the number of simulated samples.
The interface provides controls for selecting different distributions, including normal, uniform, log-normal, and exponential distributions. After the user confirms the settings and starts the simulation, the application generates a new sample and updates the graphical output.
The application displays confidence intervals for the simulated samples alongside a histogram of the generated data. This allows students to observe how sample results vary and how confidence intervals relate to the underlying distribution.
An important feature is the dynamic connection between the two graphical displays. Students can inspect a particular confidence interval by moving the cursor over it. The histogram then updates to show the corresponding sample. For example, selecting the third confidence interval changes the histogram to display the third generated sample.
This interaction helps students explore the relationship between individual samples, sample variability, and confidence intervals. Rather than examining a single static illustration, they can generate multiple samples and observe how the graphical representation changes.
The author also discusses the use of the ggvis package for producing responsive graphics. Traditional R graphics packages, including base graphics, lattice, and ggplot2, are primarily designed for static visualisations. Repeatedly redrawing these graphics in an interactive application can be relatively slow. The ggvis package, built around the Vega visualisation grammar, supports web-based graphics and animated transitions that are better suited to this type of application.
Self-Study Applications for Independent Practice
The second category of applications focuses on helping students practise statistical procedures outside lectures and tutorials. The author identifies independent self-testing as an important way to keep students engaged, particularly because students with limited mathematical or statistical backgrounds may experience difficulties in an introductory course.
The applications generate new datasets or questions so that students can practise the same type of statistical reasoning without repeatedly seeing identical examples. Depending on the application, students may be able to choose the type of data or scenario, while other questions are generated randomly.
Hints and feedback are available to support the learning process. Students can attempt a question, check their response, examine additional explanations, and reset the application to work with a new example.
Practising Statistical Distribution Tables
One self-study application helps students practise using statistical distribution tables to calculate or estimate probabilities. It covers the standard normal distribution as well as the t-distribution and chi-squared distribution.
For a standard normal variable, students are asked to calculate precise probabilities using the relevant statistical table. For t-distribution and chi-squared cases, the tasks involve identifying appropriate probability bounds.
The application generates random questions and provides several multiple-choice responses. Incorrect answer options are not selected arbitrarily. They are designed around common calculation mistakes and values that may be found near the correct entry in a normal distribution table.
For example, when the correct response involves a tail probability, alternative answers may include nearby table values, randomly selected neighbouring values, or the complementary probability. This design gives students an opportunity to identify errors that can arise when interpreting statistical tables.
After selecting an answer, students receive immediate feedback in the form of a green check mark for a correct response or a red cross for an incorrect one.
The application also provides additional hints and explanations. Initially, students see the randomly generated probability question and can choose to display a graph showing the corresponding area under the distribution curve. Once they have submitted an answer, another option becomes available to display the complete algebraic working used to obtain the result.
This staged approach allows students to request support when they need it without immediately displaying the complete solution. The application can also be reset, hiding the hints and clearing the selected responses for a new question.
Understanding Correlation Through Randomly Generated Datasets
The other self-study application focuses on correlation between two numerical variables. It generates two datasets, each containing two numeric variables, and displays the data through scatterplots.
Students can also download the generated datasets in CSV format. They are then asked to calculate the correlation for each dataset and choose the closest value from a set of multiple-choice options.
The application includes a button that allows students to check their answers after completing the task. This gives them an opportunity to compare their calculations with the correct responses and review their understanding of the relationship between variables.
Because the datasets are regenerated, students can repeat the exercise using different patterns of data. This helps prevent the activity from becoming a simple memorisation task and encourages repeated practice in interpreting scatterplots and calculating correlation.
Feedback, Hints, and Application Interaction
The self-study applications use familiar web interface elements, including radio buttons, checkboxes, and buttons for checking answers or resetting questions.
Depending on the application, feedback may appear immediately after a response or only when a student chooses to check the completed answers. When a new dataset is generated, previous responses are cleared so that the next attempt starts without any selected options.
The author notes that resetting the response values on the R server requires additional JavaScript code beyond the standard Shiny package. This illustrates that developing interactive educational tools may involve combining several technologies to achieve the desired user experience.
Hints are also presented progressively. Rather than revealing every explanation at once, the application can make additional information available as students move through the question. This allows learners to attempt a problem independently before accessing more detailed support.
Student and Instructor Feedback
Student feedback indicated that the dynamic applications were appreciated as a supplement to the course. Students reported that using the tools helped reinforce their understanding of the material and supported their preparation for assessments.
The author also describes how the applications accommodated students with different levels of mathematical confidence. Some questions were available in both standard probability notation and simplified notation with explanatory wording.
This flexibility was positively received. Students who were less comfortable with mathematical notation could use the simplified presentation, while those preparing for more advanced statistics courses appreciated the opportunity to work with conventional probability notation.
The feedback suggests that providing different ways to represent statistical questions can make interactive learning tools more accessible to students with varied educational backgrounds.
One student and one instructor also proposed introducing a competitive element into the applications. The suggested feature would display a student’s previous performance, such as the number of correct answers, total attempts, or the longest sequence of consecutive correct responses.
The author presents this as a possible future improvement rather than a feature already implemented in the applications.
Access Management and Usage Analytics
The applications were hosted through the premium version of shinyapps.io. One reason for using the paid service was the ability to require user authentication. Students had to sign in with a username and password before accessing the applications.
This arrangement helped restrict access to the intended course participants rather than opening the applications to the wider public. It was also intended to manage the available server computation time. Even paid hosting options have limits, and restricting access helped reduce the risk of the applications becoming unavailable after exceeding their computational allowance.
User authentication also offered the possibility of retaining information about individual application activity. Historical performance and usage information could potentially be stored and displayed when a student returned to an application at a later time.
However, the author explains that the current applications did not yet include detailed engagement analytics. The available information mainly indicated whether students had opened and run an application for a period of time. More detailed tracking of actions, such as the options selected or buttons clicked, had not been implemented because of time constraints.
The paper identifies Google Analytics as one possible way to record specific interactions. Such information could help instructors investigate whether students make recurring mistakes or which parts of an application they use most frequently.
Future Development
Wishart identifies several potential improvements for future versions of the applications. These include incorporating student and instructor feedback, providing more simulation options, and introducing features that could encourage students to return to the applications regularly.
The proposed competitive element would allow students to review their previous performance and track progress over time. Possible measures include the number of correct answers, the total number of attempts, and the longest sequence of consecutive correct responses.
The author also proposes developing more detailed engagement metrics and analytics. Combining these data with student authentication could provide a clearer picture of how the applications are used during the learning process.
Another planned development is to compare information about application activity with students’ performance in the STAT170 unit. This could help investigate how the tools relate to students’ learning activities and assessment outcomes.
These improvements were described as future plans. The paper does not report that a detailed analysis of application usage or its effect on course performance had already been completed.
Conclusion
The applications described in the paper demonstrate how interactive web-based tools can supplement introductory statistics teaching. By combining R, Shiny, and interactive graphical packages, instructors can provide students with opportunities to explore statistical concepts, practise calculations, and receive feedback outside the classroom.
The confidence interval application makes sampling and variation more visible through simulation and animated graphical updates. The self-study applications provide practice with statistical distribution tables and correlation using randomly generated questions and datasets.
Student and instructor feedback indicated that the tools were useful as additional learning resources. Their optional format allowed students to work independently and revisit statistical concepts when preparing for assessments.
The paper also identifies areas that require further development, particularly more detailed usage analytics, additional simulation options, and features that could encourage sustained engagement. The author presents these applications as supplementary teaching tools rather than replacements for lectures, tutorials, or instructor guidance.
Overall, the work illustrates how interactive applications can create a more flexible learning environment in which students can explore statistical ideas at their own pace, practise essential skills, and receive guidance as they work through problems.