class: center, middle, inverse, title-slide .title[ # DS Skills Lab 02 ] .subtitle[ ##
Nuthin’ but a B thang
] .author[ ### Dr Danielle Evans ] .date[ ### 3 Oct 2024 ] --- class: no-scribble <style type="text/css"> a { color: #2ec0f0; font-weight: bold; } a.glossary { font-weight: bold; color: #a497f0; cursor: help; position: relative; } .remark-inline-code { font-size: var(--code-inline-font-size); color: #59a4de; padding: 2px; } strong { font-weight: bold; color: black; } .remark-slide-number { color: black; opacity: 1; font-size: 0.9rem; } .hljs-github .hljs-string, .hljs-github .hljs-doctag { color: #333; } .hljs-github .hljs-literal { color: #333; } .hiddenFrame{ height:1px; width:1px; opacity: 0; } </style> <style type="text/css"> .tooltip { position: relative; display: inline-block; } .tooltip .tooltiptext { visibility: hidden; width: 130px; background-color: #a497f0; color: #fff; text-align: center; border-radius: 6px; padding: 5px 0; position: absolute; z-index: 1; bottom: 75%; left: 110%; margin-left: -60px; opacity: 0; transition: opacity 0.3s; } .tooltip .tooltiptext::after { content: ""; position: absolute; top: 50%; right: 100%; /* To the left of the tooltip */ margin-top: -5px; border-width: 5px; border-style: solid; border-color: transparent #a497f0 transparent transparent; } .tooltip:hover .tooltiptext { visibility: visible; opacity: 1; } </style> ## Overview - **1-Predictor Model** - **2-Predictor Model** - **KahootR!** <br><br><br><br><br><br><br><br><br><br><br> -- <div class="pc" style="font-size:90%"> <p><b>Demo!</b> Let's start on the <b><a href="https://posit.cloud/spaces/392709/content/lists/6586?sort=sequence_asc" style='color: black'>Posit Cloud</a></b>!</p> </div> --- class: no-scribble ## A Little DetouR - So we'll often use the phrase '**per unit change in our predictor**' when talking about the results of our model - But what does this actually mean?! -- - Well, each variable is measured in it's own units, this could be things like: - Metres - Beats per minute - Reaction times in milliseconds - A 5-point scale etc... - The '**per unit change in our predictor**', just means, as our predictor changes by 1-unit (1 metre, 1 bpm, 1 millisecond or 1 scale point), our outcome changes by **b1** units of whatever that variable is measured in - The **b1** is the estimate for our predictor... --- ## Beauty Is In The Eye Of The Beta - So with our **instructor beauty** study, we found that our **b1** was **0.13** - Meaning that a unit increase in **instructor beauty**, equates to a unit change of 0.13 in **teacher ratings** -- - So if **beauty** was measured on a 5-point scale: ![](data:image/png;base64,#img/beaut.png)<!-- --> - So even if we somehow increased my beauty score by **4 points** (i.e., the entire scale!), my teaching evaluation score would only increase by **0.52 points** (4 * 0.13) on the evaluation scale --- ## A Little DetouR <center> <div class="tooltip"><a href="https://www.youtube.com/watch?v=8GliyDgAGQI&t=82s" style="color:#ed2791;"><img src="data:image/png;base64,#./img/snoop.jpg" height="470px"</></a><span class="tooltiptext">Click me! 🐣</span></div> <center> --- class: no-scribble ## Final RemindRs - Submit the easteR eggs you've found today on [Canvas](https://canvas.sussex.ac.uk/courses/31583/modules) - Nominate your peers for the [savioR award](https://canvas.sussex.ac.uk/courses/31583/modules) - Have a go at the [Cloud ChallengRs](https://posit.cloud/spaces/534103/content/lists/10585?sort=created_time_desc) - Give session feedback [here](https://forms.gle/ZyXAB7kZzUUyct9n6) 😀 --- class: no-scribble ## KahootR! <iframe src="https://embed.kahoot.it/bbd63b24-59b6-410e-a7e4-81d279664854" width=100% height=50% frameBorder="0"></iframe> <script> document.addEventListener("DOMContentLoaded", function() { // Define the default pin (this can be dynamic if needed) var attendancePin = "0000"; // You can replace this with a dynamic pin // Select all slides var slides = document.querySelectorAll(".remark-slide-content"); // Loop through all slides and add the editable footer slides.forEach(function(slide) { // Create a footer div var footer = document.createElement("div"); footer.classList.add("footer-pin"); // Create an editable span for the pin var editableSpan = document.createElement("span"); editableSpan.classList.add("can-edit"); editableSpan.contentEditable = true; // Make it editable editableSpan.textContent = attendancePin; // Set the default pin // Add the editable span to the footer footer.innerHTML = "Attendance pin: "; footer.appendChild(editableSpan); // Append the footer to the current slide slide.appendChild(footer); // Add event listener to sync changes across all editable pins editableSpan.addEventListener('input', function() { const newPin = editableSpan.textContent; // Get the new pin from the edited span // Update all other editable pins slides.forEach(function(s) { const otherEditableSpan = s.querySelector('.can-edit'); if (otherEditableSpan !== editableSpan) { // Avoid updating the same one otherEditableSpan.textContent = newPin; // Update the content } }); }); }); }); </script>