{
 "cells": [
  {
   "cell_type": "markdown",
   "id": "a9215f5c-525b-4508-8b0d-700f55cbd252",
   "metadata": {},
   "source": [
    "## Introduction to Data Science\n",
    "\n",
    "#### University of Redlands - DATA 101\n",
    "#### Prof: Joanna Bieri [joanna_bieri@redlands.edu](mailto:joanna_bieri@redlands.edu)\n",
    "#### [Class Website: data101.joannabieri.com](https://data101.joannabieri.com)\n",
    "\n",
    "---------------------------------------\n",
    "# Practice Exam 1\n",
    "---------------------------------------\n",
    "\n",
    "This practice exam is **not graded**, but please give it a real try! We will go over it together on **Review Day (Thursday 10/1)**, so bring your work with you. That is what we will work from in class.\n",
    "\n",
    "1. Download Day7-PracticeExam.ipynb from the class website and move it into your `Day7` folder in your repo.\n",
    "2. Work on it a little at a time between now and Review Day.\n",
    "3. **Commit** and **Push** what you have so I can see how you are doing.\n",
    "\n",
    "NOTE:\n",
    "The practice exam is intended to give you an idea of what an exam in this class might feel like. Remember you will be expected to work on the exam **independently** and submit your work before we get together to work on the exam in class. **15\\% of your Exam grade will come from what you can do independently** so start practicing now and get help if you need it!\n",
    "\n",
    "Some things you will notice:\n",
    "\n",
    "1. I do not give code in the practice exam, but you can copy and paste the code from your other assignments or the lecture notes.\n",
    "2. The exam will be open notes, open book, open basic internet search - but you should not use AI to generate your answer. It is usually very easy to see when code has been generated by AI - it will have commands we have not learned or a style of programming that is clearly AI. YOU MUST UNDERSTAND ALL THE CODE YOU SUBMIT!\n",
    "3. The questions get progressively more involved. Just do one at a time.\n",
    "4. I expect you to explain your results. I should not have to interpret what your numbers or code outputs mean. Add Markdown cells to describe what YOU see in the results."
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 1,
   "id": "049c24b6-a6c1-4ccc-b2de-5ea0366d09f8",
   "metadata": {
    "execution": {
     "iopub.execute_input": "2026-09-16T22:25:34.075195Z",
     "iopub.status.busy": "2026-09-16T22:25:34.074571Z",
     "iopub.status.idle": "2026-09-16T22:25:35.738967Z",
     "shell.execute_reply": "2026-09-16T22:25:35.738356Z"
    }
   },
   "outputs": [],
   "source": [
    "import numpy as np\n",
    "import pandas as pd\n",
    "\n",
    "import matplotlib.pyplot as plt\n",
    "import plotly.express as px\n",
    "from plotly.subplots import make_subplots\n",
    "import plotly.io as pio\n",
    "pio.renderers.default = 'notebook_connected'"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "0b3b6bfe-df90-4521-9d96-404916911e2b",
   "metadata": {},
   "source": [
    "# Practice Exam - EDA - College Majors\n",
    "\n",
    "Your solutions should include code written to answer the questions AND words describing the results. For each problem:\n",
    "\n",
    "1. Write code to get the answers. It is okay to copy and paste from our lecture notes or your homework assignments.\n",
    "2. Describe what the code output is telling you.\n",
    "3. Explain any interesting aspects of your results.\n",
    "\n",
    "------------------------\n",
    "-------------------------"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "1c634098-c93e-41c2-bc4a-523f4c27a333",
   "metadata": {},
   "source": [
    "The first step in the process of turning information into knowledge is to summarize and describe the raw information - the data.\n",
    "In this assignment we explore data on college majors and earnings, specifically the data behind the FiveThirtyEight story [\"The Economic Guide To Picking A College Major\"](https://fivethirtyeight.com/features/the-economic-guide-to-picking-a-college-major/).\n",
    "\n",
    "These data originally come from the American Community Survey (ACS) 2010-2012 Public Use Microdata Series.\n",
    "While this is outside the scope of this assignment, if you are curious about how raw data from the ACS were cleaned and prepared, see [the code](https://github.com/fivethirtyeight/data/blob/master/college-majors/college-majors-rscript.R) FiveThirtyEight authors used.\n",
    "\n",
    "We should also note that there are many considerations that go into picking a major.\n",
    "Earnings potential and employment prospects are two of them, and they are important, but they don't tell the whole story.\n",
    "Keep this in mind as you analyze the data."
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 2,
   "id": "20e25679-7c2a-4244-be1b-dc01e35f8126",
   "metadata": {
    "execution": {
     "iopub.execute_input": "2026-09-16T22:25:35.740823Z",
     "iopub.status.busy": "2026-09-16T22:25:35.740656Z",
     "iopub.status.idle": "2026-09-16T22:25:35.984269Z",
     "shell.execute_reply": "2026-09-16T22:25:35.983766Z"
    }
   },
   "outputs": [],
   "source": [
    "file_location = 'https://joannabieri.com/introdatascience/data/recent-grads.csv'\n",
    "DF_raw = pd.read_csv(file_location)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 3,
   "id": "763b02f4-00ce-4b9a-ac1d-792c794109f1",
   "metadata": {
    "execution": {
     "iopub.execute_input": "2026-09-16T22:25:35.986156Z",
     "iopub.status.busy": "2026-09-16T22:25:35.985970Z",
     "iopub.status.idle": "2026-09-16T22:25:36.003021Z",
     "shell.execute_reply": "2026-09-16T22:25:36.002651Z"
    }
   },
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>Rank</th>\n",
       "      <th>Major_code</th>\n",
       "      <th>Major</th>\n",
       "      <th>Total</th>\n",
       "      <th>Men</th>\n",
       "      <th>Women</th>\n",
       "      <th>Major_category</th>\n",
       "      <th>ShareWomen</th>\n",
       "      <th>Sample_size</th>\n",
       "      <th>Employed</th>\n",
       "      <th>...</th>\n",
       "      <th>Part_time</th>\n",
       "      <th>Full_time_year_round</th>\n",
       "      <th>Unemployed</th>\n",
       "      <th>Unemployment_rate</th>\n",
       "      <th>Median</th>\n",
       "      <th>P25th</th>\n",
       "      <th>P75th</th>\n",
       "      <th>College_jobs</th>\n",
       "      <th>Non_college_jobs</th>\n",
       "      <th>Low_wage_jobs</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>1</td>\n",
       "      <td>2419</td>\n",
       "      <td>PETROLEUM ENGINEERING</td>\n",
       "      <td>2339.0</td>\n",
       "      <td>2057.0</td>\n",
       "      <td>282.0</td>\n",
       "      <td>Engineering</td>\n",
       "      <td>0.120564</td>\n",
       "      <td>36</td>\n",
       "      <td>1976</td>\n",
       "      <td>...</td>\n",
       "      <td>270</td>\n",
       "      <td>1207</td>\n",
       "      <td>37</td>\n",
       "      <td>0.018381</td>\n",
       "      <td>110000</td>\n",
       "      <td>95000</td>\n",
       "      <td>125000</td>\n",
       "      <td>1534</td>\n",
       "      <td>364</td>\n",
       "      <td>193</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>2</td>\n",
       "      <td>2416</td>\n",
       "      <td>MINING AND MINERAL ENGINEERING</td>\n",
       "      <td>756.0</td>\n",
       "      <td>679.0</td>\n",
       "      <td>77.0</td>\n",
       "      <td>Engineering</td>\n",
       "      <td>0.101852</td>\n",
       "      <td>7</td>\n",
       "      <td>640</td>\n",
       "      <td>...</td>\n",
       "      <td>170</td>\n",
       "      <td>388</td>\n",
       "      <td>85</td>\n",
       "      <td>0.117241</td>\n",
       "      <td>75000</td>\n",
       "      <td>55000</td>\n",
       "      <td>90000</td>\n",
       "      <td>350</td>\n",
       "      <td>257</td>\n",
       "      <td>50</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>3</td>\n",
       "      <td>2415</td>\n",
       "      <td>METALLURGICAL ENGINEERING</td>\n",
       "      <td>856.0</td>\n",
       "      <td>725.0</td>\n",
       "      <td>131.0</td>\n",
       "      <td>Engineering</td>\n",
       "      <td>0.153037</td>\n",
       "      <td>3</td>\n",
       "      <td>648</td>\n",
       "      <td>...</td>\n",
       "      <td>133</td>\n",
       "      <td>340</td>\n",
       "      <td>16</td>\n",
       "      <td>0.024096</td>\n",
       "      <td>73000</td>\n",
       "      <td>50000</td>\n",
       "      <td>105000</td>\n",
       "      <td>456</td>\n",
       "      <td>176</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>4</td>\n",
       "      <td>2417</td>\n",
       "      <td>NAVAL ARCHITECTURE AND MARINE ENGINEERING</td>\n",
       "      <td>1258.0</td>\n",
       "      <td>1123.0</td>\n",
       "      <td>135.0</td>\n",
       "      <td>Engineering</td>\n",
       "      <td>0.107313</td>\n",
       "      <td>16</td>\n",
       "      <td>758</td>\n",
       "      <td>...</td>\n",
       "      <td>150</td>\n",
       "      <td>692</td>\n",
       "      <td>40</td>\n",
       "      <td>0.050125</td>\n",
       "      <td>70000</td>\n",
       "      <td>43000</td>\n",
       "      <td>80000</td>\n",
       "      <td>529</td>\n",
       "      <td>102</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>5</td>\n",
       "      <td>2405</td>\n",
       "      <td>CHEMICAL ENGINEERING</td>\n",
       "      <td>32260.0</td>\n",
       "      <td>21239.0</td>\n",
       "      <td>11021.0</td>\n",
       "      <td>Engineering</td>\n",
       "      <td>0.341631</td>\n",
       "      <td>289</td>\n",
       "      <td>25694</td>\n",
       "      <td>...</td>\n",
       "      <td>5180</td>\n",
       "      <td>16697</td>\n",
       "      <td>1672</td>\n",
       "      <td>0.061098</td>\n",
       "      <td>65000</td>\n",
       "      <td>50000</td>\n",
       "      <td>75000</td>\n",
       "      <td>18314</td>\n",
       "      <td>4440</td>\n",
       "      <td>972</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>...</th>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>168</th>\n",
       "      <td>169</td>\n",
       "      <td>3609</td>\n",
       "      <td>ZOOLOGY</td>\n",
       "      <td>8409.0</td>\n",
       "      <td>3050.0</td>\n",
       "      <td>5359.0</td>\n",
       "      <td>Biology &amp; Life Science</td>\n",
       "      <td>0.637293</td>\n",
       "      <td>47</td>\n",
       "      <td>6259</td>\n",
       "      <td>...</td>\n",
       "      <td>2190</td>\n",
       "      <td>3602</td>\n",
       "      <td>304</td>\n",
       "      <td>0.046320</td>\n",
       "      <td>26000</td>\n",
       "      <td>20000</td>\n",
       "      <td>39000</td>\n",
       "      <td>2771</td>\n",
       "      <td>2947</td>\n",
       "      <td>743</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>169</th>\n",
       "      <td>170</td>\n",
       "      <td>5201</td>\n",
       "      <td>EDUCATIONAL PSYCHOLOGY</td>\n",
       "      <td>2854.0</td>\n",
       "      <td>522.0</td>\n",
       "      <td>2332.0</td>\n",
       "      <td>Psychology &amp; Social Work</td>\n",
       "      <td>0.817099</td>\n",
       "      <td>7</td>\n",
       "      <td>2125</td>\n",
       "      <td>...</td>\n",
       "      <td>572</td>\n",
       "      <td>1211</td>\n",
       "      <td>148</td>\n",
       "      <td>0.065112</td>\n",
       "      <td>25000</td>\n",
       "      <td>24000</td>\n",
       "      <td>34000</td>\n",
       "      <td>1488</td>\n",
       "      <td>615</td>\n",
       "      <td>82</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>170</th>\n",
       "      <td>171</td>\n",
       "      <td>5202</td>\n",
       "      <td>CLINICAL PSYCHOLOGY</td>\n",
       "      <td>2838.0</td>\n",
       "      <td>568.0</td>\n",
       "      <td>2270.0</td>\n",
       "      <td>Psychology &amp; Social Work</td>\n",
       "      <td>0.799859</td>\n",
       "      <td>13</td>\n",
       "      <td>2101</td>\n",
       "      <td>...</td>\n",
       "      <td>648</td>\n",
       "      <td>1293</td>\n",
       "      <td>368</td>\n",
       "      <td>0.149048</td>\n",
       "      <td>25000</td>\n",
       "      <td>25000</td>\n",
       "      <td>40000</td>\n",
       "      <td>986</td>\n",
       "      <td>870</td>\n",
       "      <td>622</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>171</th>\n",
       "      <td>172</td>\n",
       "      <td>5203</td>\n",
       "      <td>COUNSELING PSYCHOLOGY</td>\n",
       "      <td>4626.0</td>\n",
       "      <td>931.0</td>\n",
       "      <td>3695.0</td>\n",
       "      <td>Psychology &amp; Social Work</td>\n",
       "      <td>0.798746</td>\n",
       "      <td>21</td>\n",
       "      <td>3777</td>\n",
       "      <td>...</td>\n",
       "      <td>965</td>\n",
       "      <td>2738</td>\n",
       "      <td>214</td>\n",
       "      <td>0.053621</td>\n",
       "      <td>23400</td>\n",
       "      <td>19200</td>\n",
       "      <td>26000</td>\n",
       "      <td>2403</td>\n",
       "      <td>1245</td>\n",
       "      <td>308</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>172</th>\n",
       "      <td>173</td>\n",
       "      <td>3501</td>\n",
       "      <td>LIBRARY SCIENCE</td>\n",
       "      <td>1098.0</td>\n",
       "      <td>134.0</td>\n",
       "      <td>964.0</td>\n",
       "      <td>Education</td>\n",
       "      <td>0.877960</td>\n",
       "      <td>2</td>\n",
       "      <td>742</td>\n",
       "      <td>...</td>\n",
       "      <td>237</td>\n",
       "      <td>410</td>\n",
       "      <td>87</td>\n",
       "      <td>0.104946</td>\n",
       "      <td>22000</td>\n",
       "      <td>20000</td>\n",
       "      <td>22000</td>\n",
       "      <td>288</td>\n",
       "      <td>338</td>\n",
       "      <td>192</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "<p>173 rows × 21 columns</p>\n",
       "</div>"
      ],
      "text/plain": [
       "     Rank  Major_code                                      Major    Total  \\\n",
       "0       1        2419                      PETROLEUM ENGINEERING   2339.0   \n",
       "1       2        2416             MINING AND MINERAL ENGINEERING    756.0   \n",
       "2       3        2415                  METALLURGICAL ENGINEERING    856.0   \n",
       "3       4        2417  NAVAL ARCHITECTURE AND MARINE ENGINEERING   1258.0   \n",
       "4       5        2405                       CHEMICAL ENGINEERING  32260.0   \n",
       "..    ...         ...                                        ...      ...   \n",
       "168   169        3609                                    ZOOLOGY   8409.0   \n",
       "169   170        5201                     EDUCATIONAL PSYCHOLOGY   2854.0   \n",
       "170   171        5202                        CLINICAL PSYCHOLOGY   2838.0   \n",
       "171   172        5203                      COUNSELING PSYCHOLOGY   4626.0   \n",
       "172   173        3501                            LIBRARY SCIENCE   1098.0   \n",
       "\n",
       "         Men    Women            Major_category  ShareWomen  Sample_size  \\\n",
       "0     2057.0    282.0               Engineering    0.120564           36   \n",
       "1      679.0     77.0               Engineering    0.101852            7   \n",
       "2      725.0    131.0               Engineering    0.153037            3   \n",
       "3     1123.0    135.0               Engineering    0.107313           16   \n",
       "4    21239.0  11021.0               Engineering    0.341631          289   \n",
       "..       ...      ...                       ...         ...          ...   \n",
       "168   3050.0   5359.0    Biology & Life Science    0.637293           47   \n",
       "169    522.0   2332.0  Psychology & Social Work    0.817099            7   \n",
       "170    568.0   2270.0  Psychology & Social Work    0.799859           13   \n",
       "171    931.0   3695.0  Psychology & Social Work    0.798746           21   \n",
       "172    134.0    964.0                 Education    0.877960            2   \n",
       "\n",
       "     Employed  ...  Part_time  Full_time_year_round  Unemployed  \\\n",
       "0        1976  ...        270                  1207          37   \n",
       "1         640  ...        170                   388          85   \n",
       "2         648  ...        133                   340          16   \n",
       "3         758  ...        150                   692          40   \n",
       "4       25694  ...       5180                 16697        1672   \n",
       "..        ...  ...        ...                   ...         ...   \n",
       "168      6259  ...       2190                  3602         304   \n",
       "169      2125  ...        572                  1211         148   \n",
       "170      2101  ...        648                  1293         368   \n",
       "171      3777  ...        965                  2738         214   \n",
       "172       742  ...        237                   410          87   \n",
       "\n",
       "     Unemployment_rate  Median  P25th   P75th  College_jobs  Non_college_jobs  \\\n",
       "0             0.018381  110000  95000  125000          1534               364   \n",
       "1             0.117241   75000  55000   90000           350               257   \n",
       "2             0.024096   73000  50000  105000           456               176   \n",
       "3             0.050125   70000  43000   80000           529               102   \n",
       "4             0.061098   65000  50000   75000         18314              4440   \n",
       "..                 ...     ...    ...     ...           ...               ...   \n",
       "168           0.046320   26000  20000   39000          2771              2947   \n",
       "169           0.065112   25000  24000   34000          1488               615   \n",
       "170           0.149048   25000  25000   40000           986               870   \n",
       "171           0.053621   23400  19200   26000          2403              1245   \n",
       "172           0.104946   22000  20000   22000           288               338   \n",
       "\n",
       "     Low_wage_jobs  \n",
       "0              193  \n",
       "1               50  \n",
       "2                0  \n",
       "3                0  \n",
       "4              972  \n",
       "..             ...  \n",
       "168            743  \n",
       "169             82  \n",
       "170            622  \n",
       "171            308  \n",
       "172            192  \n",
       "\n",
       "[173 rows x 21 columns]"
      ]
     },
     "execution_count": 3,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "DF_raw"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "d2c98753-1b02-4889-81b3-d97627d70824",
   "metadata": {},
   "source": [
    "### 1. Describe the data that you see here.\n",
    "\n",
    "* How many variables?\n",
    "* How many observations?\n",
    "* Are the variables categorical or numerical?\n",
    "* Are there any variables that you don't know what they mean? If so [CLICK HERE - to see the Git Repo for the data where the variables are defined](https://github.com/fivethirtyeight/data/tree/master/college-majors)\n"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 4,
   "id": "30f16d98-040a-41f9-984e-330617d70fe1",
   "metadata": {
    "execution": {
     "iopub.execute_input": "2026-09-16T22:25:36.004671Z",
     "iopub.status.busy": "2026-09-16T22:25:36.004511Z",
     "iopub.status.idle": "2026-09-16T22:25:36.006349Z",
     "shell.execute_reply": "2026-09-16T22:25:36.006018Z"
    }
   },
   "outputs": [],
   "source": [
    "#"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 5,
   "id": "b09fe27b-bcac-46c2-af97-6ca873f5e81d",
   "metadata": {
    "execution": {
     "iopub.execute_input": "2026-09-16T22:25:36.007808Z",
     "iopub.status.busy": "2026-09-16T22:25:36.007648Z",
     "iopub.status.idle": "2026-09-16T22:25:36.009830Z",
     "shell.execute_reply": "2026-09-16T22:25:36.009343Z"
    }
   },
   "outputs": [],
   "source": [
    "#"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 6,
   "id": "0b9165e9-a915-4cd4-898f-06d81ccf22fa",
   "metadata": {
    "execution": {
     "iopub.execute_input": "2026-09-16T22:25:36.011258Z",
     "iopub.status.busy": "2026-09-16T22:25:36.011104Z",
     "iopub.status.idle": "2026-09-16T22:25:36.013043Z",
     "shell.execute_reply": "2026-09-16T22:25:36.012633Z"
    }
   },
   "outputs": [],
   "source": [
    "#"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "13005d11-f03f-40dd-a53c-9ff76f5dbfe1",
   "metadata": {},
   "source": [
    "**(Click Here to Explain your Results)**"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "e6081090-f75b-43f2-aaee-e9e90afbb058",
   "metadata": {},
   "source": [
    "### 2. Answer some questions about the data\n",
    "\n",
    "* Which major has the lowest unemployment rate? Show a data frame that answers this question, but only show columns that are useful to the answer.\n",
    "* Which major has the highest percentage of women? Show a data frame that answers this question, but only show columns that are useful to the answer.\n",
    "* How do the distributions of median income compare across major categories?\n",
    "    * First get a value count on what major categories are in the data. What categories are most or least represented?\n",
    "    * Do some summary statistics using the .groupby() command to see the statistics for each major category.\n",
    "    * Make a histogram that explores median income for each of the major categories (facet_col). How did you choose your number of bins?\n",
    "    * Why do we often choose the median, rather than the mean, to describe the typical income of a group of people? Look this up online if you don't know the answer!\n",
    "    * Answer the question: Which major category has the highest typical (you'll need to decide what this means) median income?"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 7,
   "id": "1274bfec-dd4a-4e48-95b7-1952e18c0955",
   "metadata": {
    "execution": {
     "iopub.execute_input": "2026-09-16T22:25:36.014590Z",
     "iopub.status.busy": "2026-09-16T22:25:36.014431Z",
     "iopub.status.idle": "2026-09-16T22:25:36.016221Z",
     "shell.execute_reply": "2026-09-16T22:25:36.015897Z"
    }
   },
   "outputs": [],
   "source": [
    "#"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 8,
   "id": "65955115-72c3-445f-be32-af352ececa93",
   "metadata": {
    "execution": {
     "iopub.execute_input": "2026-09-16T22:25:36.017678Z",
     "iopub.status.busy": "2026-09-16T22:25:36.017523Z",
     "iopub.status.idle": "2026-09-16T22:25:36.019302Z",
     "shell.execute_reply": "2026-09-16T22:25:36.018969Z"
    }
   },
   "outputs": [],
   "source": [
    "#"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 9,
   "id": "8b12bd53-36e0-47b4-9ef5-3cbf6fc065a4",
   "metadata": {
    "execution": {
     "iopub.execute_input": "2026-09-16T22:25:36.020779Z",
     "iopub.status.busy": "2026-09-16T22:25:36.020624Z",
     "iopub.status.idle": "2026-09-16T22:25:36.022410Z",
     "shell.execute_reply": "2026-09-16T22:25:36.022067Z"
    }
   },
   "outputs": [],
   "source": [
    "#"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 10,
   "id": "a595e3c3-8b12-4917-905a-486a305b6baa",
   "metadata": {
    "execution": {
     "iopub.execute_input": "2026-09-16T22:25:36.023850Z",
     "iopub.status.busy": "2026-09-16T22:25:36.023697Z",
     "iopub.status.idle": "2026-09-16T22:25:36.025501Z",
     "shell.execute_reply": "2026-09-16T22:25:36.025170Z"
    }
   },
   "outputs": [],
   "source": [
    "#"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 11,
   "id": "a0fbbb69-ed86-4445-b2b0-6013bf406361",
   "metadata": {
    "execution": {
     "iopub.execute_input": "2026-09-16T22:25:36.026902Z",
     "iopub.status.busy": "2026-09-16T22:25:36.026750Z",
     "iopub.status.idle": "2026-09-16T22:25:36.028527Z",
     "shell.execute_reply": "2026-09-16T22:25:36.028202Z"
    }
   },
   "outputs": [],
   "source": [
    "#"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "04306ea4-b398-411c-b91e-86a68d24a8d6",
   "metadata": {},
   "source": [
    "**(Click Here to Explain your Results)**"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "39d4118e-26d8-4f81-8d65-569c4b6d97d1",
   "metadata": {},
   "source": [
    "### 3. More complicated questions\n",
    "\n",
    "* Are all STEM fields the same in terms job opportunities?\n",
    "    * Assume the following are STEM major categories\n",
    "    \n",
    "  ``` [\"Biology & Life Science\", \"Computers & Mathematics\", \"Engineering\",\"Physical Sciences\"]```\n",
    "  \n",
    "    * Create a DataFrame (using a mask) so you only look at STEM majors.\n",
    "    * Which STEM majors have median salaries equal to or less than the median for all majors' median earnings?\n",
    "* What types of majors do women tend to major in?\n",
    "    * Create a scatterplot of median income vs. proportion of women in that major, coloured by whether the major is in a STEM field or not."
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 12,
   "id": "1639bd96-4f56-4ccb-b28c-51b09b961ae4",
   "metadata": {
    "execution": {
     "iopub.execute_input": "2026-09-16T22:25:36.030047Z",
     "iopub.status.busy": "2026-09-16T22:25:36.029896Z",
     "iopub.status.idle": "2026-09-16T22:25:36.031635Z",
     "shell.execute_reply": "2026-09-16T22:25:36.031313Z"
    }
   },
   "outputs": [],
   "source": [
    "#"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 13,
   "id": "4e0a96d0-07ee-4693-8972-829ab3518125",
   "metadata": {
    "execution": {
     "iopub.execute_input": "2026-09-16T22:25:36.033015Z",
     "iopub.status.busy": "2026-09-16T22:25:36.032862Z",
     "iopub.status.idle": "2026-09-16T22:25:36.034607Z",
     "shell.execute_reply": "2026-09-16T22:25:36.034284Z"
    }
   },
   "outputs": [],
   "source": [
    "#"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 14,
   "id": "be654ff2-e684-4eda-8843-4ac9f07a74ae",
   "metadata": {
    "execution": {
     "iopub.execute_input": "2026-09-16T22:25:36.035989Z",
     "iopub.status.busy": "2026-09-16T22:25:36.035841Z",
     "iopub.status.idle": "2026-09-16T22:25:36.037596Z",
     "shell.execute_reply": "2026-09-16T22:25:36.037270Z"
    }
   },
   "outputs": [],
   "source": [
    "#"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "b9f65c22-2c17-495a-be1e-66e1dd2e183a",
   "metadata": {},
   "source": [
    "**(Click Here to Explain your Results)**"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "b3df8412-b946-4812-ba3b-873fb0eb8d7c",
   "metadata": {},
   "source": [
    "### 4. Ask a question of interest to you."
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 15,
   "id": "25a08e99-946a-4003-a477-1dc941e4357e",
   "metadata": {
    "execution": {
     "iopub.execute_input": "2026-09-16T22:25:36.039117Z",
     "iopub.status.busy": "2026-09-16T22:25:36.038968Z",
     "iopub.status.idle": "2026-09-16T22:25:36.040721Z",
     "shell.execute_reply": "2026-09-16T22:25:36.040396Z"
    }
   },
   "outputs": [],
   "source": [
    "#"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "0940ef30-6ee7-42c8-8747-80f4b2bb8e3f",
   "metadata": {},
   "source": [
    "**(Click Here to Explain your Results)**"
   ]
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3 (ipykernel)",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.13.5"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 5
}
