Dual Rating Scale: How It Works

Welcome to the Dual Rating Scale resource. Below are links to working HTML pages (dualratingscale.html) and (dailyschedule.html), which demonstrate how to record Emotion and Arousal data throughout the day, and then a way to visualize it in a chart or save the results as a text file.

Link to the Demo Dual Rating Scale:
Open the Dual Rating Scale Form

Link to the Demo HTML File to copy:
Here is the Dual Rating html

Link to the Demo Daily Schedule:
Open the Daily Schedule Form

Link to the Demo Daily Schedule HTML File to copy:
Here is the simplier Daily Schedule html

1. Purpose of the Code

The dualratingscale.html file provides an interactive form that allows users to rate how they feel (emotion) and how energized or calm they are (arousal) at key time slots throughout the day. It is designed with the following goals:

2. Code Walkthrough

  1. HTML Structure & CSS Styles
    The code begins with the usual <!DOCTYPE html>, <html>, <head>, and <body> tags. In the <head>, we see a <style> block that includes rules to style the page: fonts, spacing, borders, etc.
  2. Legend Section
    There's a <div class="legend"> that describes the Emotion Rating Scale (1–5) and the Arousal Rating Scale (1–5), each with emoji examples. This helps users interpret how to select ratings.
  3. Form Sections
    The main part of the document is a series of <div class="form-section"> blocks, each containing: You can freely add or remove time-slot divs to match your own schedule.
  4. JavaScript for Data Collection & Saving
    In the <script> at the end, the code:

3. Customizing the Schedule or Ratings

If you’d like to collect data at different times or label them differently (e.g., “8:00 AM - Start of Class”), simply locate the corresponding <div class="time-slot"> in the HTML and rename it. Make sure you also update the code in the JavaScript section that defines the schedule order (i.e., the scheduleOrder array in collectData()). This array links each time slot’s HTML name attribute (like wake_up_emotion) to its label (“6:30 AM”).

4. How It Saves Data

5. Graphing Trends

6. Exporting to PDF or Printing

The current example saves data only as a text file. However, if you wish to create a PDF or automatically print the chart, you can:

7. Extending Its Use

This dual rating form is primarily focused on emotion and arousal, but you could tweak the code for any rating scales:

Additionally, you can tie these ratings into other frameworks: for instance, integrating them with an educational plan, daily living skills tracker, or an occupational therapy assignment.

Note: If you want to store data in a database or handle large volumes of records, you can adapt the saveData() logic to POST the JSON to a server-side script (PHP, Node.js, etc.), which then saves to a DB or cloud storage.

8. Where to Find the Code

You can see and edit the full code in dualratingscale.html. It is best to open that file in a modern browser (Chrome, Firefox, Edge) that can run JavaScript, handle Blob downloads, and display Chart.js charts.

Conclusion

The Dual Rating Scale tool can be a helpful framework for collecting, visualizing, and reflecting on daily emotional and arousal data. It’s simple to modify, so you can tailor the schedule, rating descriptions, or chart outputs to fit your specific needs. We hope this explanation helps you integrate the tool into your own routines or professional practice.

Back to Resource Hub