Normalizing student grades against median

Normalizing student grades against median
Data Analysis Python Pandas Data Manipulation Normalization

You are given a dataframe containing student information, named df (shown below). Suppose you want to normalize each student's grade based on the group's median age.


Age Favorite Color Grade Name
20 blue 88 Willard Morris
19 blue 95 Al Jennings
22 yellow 92 Omar Mullins
21 green 70 Spencer McDaniel

Write a function using Python Pandas that will add a new column to your dataframe containing a new grade normalized against the median age of the students.

Click here to view this problem in an interactive Colab (Jupyter) notebook.




Want the solutions? Upgrade to premium to access detailed solutions to each problem (including this one).

Was this email forwarded to you? You can join our list here to receive questions


Unsubscribe

Older messages

Testing impact of exercise on memory

Friday, January 29, 2021

Data Interview Qs Testing impact of exercise on memory Statistics Z-test Suppose a study shows that exercising before studying can improve your memory. Suppose a researcher tests this hypothesis with a

Identity Matrix

Wednesday, January 27, 2021

Data Interview Qs Identity Matrix Python Data Structures Arrays Matrix Can you build a function that prints an identity matrix, given the identity matrix size? Examples: Input: 2 Output: 1 0 0 1 Input:

Parking space probabilities

Friday, January 22, 2021

Data Interview Qs Parking space probabilities Data Analysis Python Pandas External Dataset Data Manipulation Data Visualization Statistics Probability Mass Function Suppose you're analyzing the

Bayes' Theorem

Wednesday, January 20, 2021

Data Interview Qs Bayes' Theorem Statistics Bayes' Theorem What is Bayes' Theorem? Explain how it can be useful in a machine learning context? Want the solutions? Upgrade to premium to

Sorting algorithm

Monday, January 18, 2021

Data Interview Qs Sorting algorithm Python Algorithms Given the following Python function, write out what the output would be at each stage: n = 1 while n < 3: m = n + 1 while m < 4: m += 1 print

You Might Also Like

Scoop: Tiger Global-backed Innovaccer in talks to raise $250M

Wednesday, May 1, 2024

Plus: An update on Google's layoffs and the social platform X didn't see coming View this email online in your browser By Christine Hall Wednesday, May 1, 2024 Welcome to TechCrunch PM. Today,

🖥️ Why I'm Never Going Back to a Windows PC — Tips Before You Buy a Smart Ring

Wednesday, May 1, 2024

Also: How to Clear the Moisture Detected Warning on Samsung Phones, and More How-To Geek Logo May 1, 2024 Did You Know A single 1 oz shot of espresso only has approximately 40 mg of caffeine, whereas a

Daily Coding Problem: Problem #1428 [Hard]

Wednesday, May 1, 2024

Daily Coding Problem Good morning! Here's your coding interview problem for today. This problem was asked by Microsoft. Given an array of positive integers, divide the array into two subsets such

Top Tech Deals 👀 Samsung Gaming Monitor, Pixel Watch 2, MacBook Air, and More

Wednesday, May 1, 2024

Get a discounted M3 MacBook Air or expand your Xbox storage. How-To Geek Logo May 1, 2024 Top Tech Deals: Samsung Gaming Monitor, Pixel Watch 2, MacBook Air, and More Get a discounted M3 MacBook Air or

Infographic | Visualizing Global Gold Production in 2023 🏅

Wednesday, May 1, 2024

Gold production in 2023 was led by China, Australia, and Russia, with each outputting over 300 tonnes. View Online | Subscribe Presented by: Access European benchmarks with a trusted 25-year history

⚙️ GPT-5 may be releasing sooner than expected

Wednesday, May 1, 2024

Plus: Amazon rebrands AI branch ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌

Noonification: How to Create a CI/CD Pipeline Using GitHub and AWS EC2

Wednesday, May 1, 2024

Top Tech Content sent at Noon! Get Algolia: AI Search that understands How are you, @newsletterest1? 🪐 What's happening in tech today, May 1, 2024? The HackerNoon Newsletter brings the HackerNoon

Arc for Windows is better than Chrome

Wednesday, May 1, 2024

Adobe bug bounty; Rabbit's first R1 software update; Dream podcaster mic -- ZDNET ZDNET Tech Today - US May 1, 2024 placeholder Arc browser is now available for Windows and it's so much better

Is TikTok trying to get banned from the App Store early?

Wednesday, May 1, 2024

TikTok is offering some users a way to buy its in-app tipping tokens outside of Apple's App Store. View this email online in your browser By Alex Wilhelm Wednesday, May 1, 2024 Good morning, and

Get Compliant in 2024 - Download Ultimate PAM Policy Template Today

Wednesday, May 1, 2024

Privileged Access Management Policy Template What are your PAM policies for 2024? Get ready for the New Year Is your approach to Privileged Access Management as current and effective as it could be? In