{
 "cells": [
  {
   "cell_type": "code",
   "execution_count": 1,
   "metadata": {
    "id": "mkIYsNGPtEfb"
   },
   "outputs": [],
   "source": [
    "import pandas as pd\n",
    "from sklearn.preprocessing import OneHotEncoder\n",
    "from sklearn.preprocessing import MinMaxScaler\n",
    "from sklearn.model_selection import train_test_split\n",
    "import numpy as np\n",
    "from sklearn.metrics import mean_squared_error\n",
    "from sklearn.metrics import mean_absolute_error\n",
    "import matplotlib.pyplot as plt\n",
    "import seaborn as sns"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 11,
   "metadata": {
    "colab": {
     "base_uri": "https://localhost:8080/"
    },
    "id": "ZazUCR02tMH0",
    "outputId": "4e3a1d0d-163b-41e2-d6f3-799556908a66"
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "\n",
      "\n",
      "\u001b7\u001b[1A\u001b[1G\u001b[27G[Files: 0  Bytes: 0  [0 B/s] Re]\u001b8\u001b7\u001b[2A\u001b[1G\u001b[27G[https://docs.google.com/spread]\u001b8\u001b7\u001b[2A\u001b[1G0 files              100% [=============================>]     354     --.-KB/s\u001b8\u001b7\u001b[1A\u001b[1G\u001b[27G[Files: 0  Bytes: 354  [654 B/s]\u001b8\u001b7\u001b[2A\u001b[1G\u001b[27G[https://doc-08-1k-sheets.googl]\u001b8\u001b7\u001b[2A\u001b[1G0 files              100% [=============================>]     354     --.-KB/s\u001b8\u001b7\u001b[2A\u001b[1GmuseumDataset.csv      0% [<=>                           ]   12.36K    --.-KB/s\u001b8\u001b7\u001b[2A\u001b[1GmuseumDataset.csv      0% [ <=>                          ]   55.91K  348.35KB/s\u001b8\u001b7\u001b[2A\u001b[1GmuseumDataset.csv      0% [  <=>                         ]  123.69K  296.08KB/s\u001b8\u001b7\u001b[2A\u001b[1GmuseumDataset.csv      0% [   <=>                        ]  187.58K  349.73KB/s\u001b8\u001b7\u001b[2A\u001b[1GmuseumDataset.csv      0% [    <=>                       ]  283.42K  432.99KB/s\u001b8\u001b7\u001b[2A\u001b[1GmuseumDataset.csv      0% [     <=>                      ]  411.97K  532.09KB/s\u001b8\u001b7\u001b[2A\u001b[1GmuseumDataset.csv      0% [      <=>                     ]  583.28K  651.72KB/s\u001b8\u001b7\u001b[2A\u001b[1GmuseumDataset.csv      0% [       <=>                    ]  813.84K  800.67KB/s\u001b8\u001b7\u001b[2A\u001b[1GmuseumDataset.csv      0% [        <=>                   ]    1.11M    1001KB/s\u001b8\u001b7\u001b[2A\u001b[1GmuseumDataset.csv      0% [         <=>                  ]    1.24M    1008KB/s\u001b8\u001b7\u001b[2A\u001b[1GmuseumDataset.csv      0% [          <=>                 ]    1.40M    1.01MB/s\u001b8\u001b7\u001b[2A\u001b[1GmuseumDataset.csv      0% [           <=>                ]    1.51M    1.00MB/s\u001b8\u001b7\u001b[2A\u001b[1GmuseumDataset.csv      0% [            <=>               ]    1.61M    1012KB/s\u001b8\u001b7\u001b[2A\u001b[1GmuseumDataset.csv      0% [             <=>              ]    1.73M    1006KB/s\u001b8\u001b7\u001b[2A\u001b[1GmuseumDataset.csv    100% [=============================>]    1.81M    1016KB/s\u001b8\u001b7\u001b[1A\u001b[1G\u001b[27G[Files: 1  Bytes: 1.81M [486.82]\u001b8\u001b[m\u001b[m\u001b[m\u001b[m"
     ]
    }
   ],
   "source": [
    "!wget -O museumDataset.csv \"https://docs.google.com/spreadsheets/d/1lS9HEz8FreAkCpR_w_ykAHy3oWeQBqiuc_RJyr3dfbE/export?format=csv&gid=1322780754\""
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 14,
   "metadata": {
    "colab": {
     "base_uri": "https://localhost:8080/",
     "height": 930
    },
    "id": "jxUFPkPs8oTT",
    "outputId": "1b1b8c1a-4597-4738-a79c-dc7615e4cecc"
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "                                         Museum Type  \\\n",
      "0                                     HISTORY MUSEUM   \n",
      "1      ARBORETUM, BOTANICAL GARDEN, OR NATURE CENTER   \n",
      "2         SCIENCE & TECHNOLOGY MUSEUM OR PLANETARIUM   \n",
      "3                              HISTORIC PRESERVATION   \n",
      "4                                     HISTORY MUSEUM   \n",
      "...                                              ...   \n",
      "33067                          HISTORIC PRESERVATION   \n",
      "33068                                 GENERAL MUSEUM   \n",
      "33069                          HISTORIC PRESERVATION   \n",
      "33070                                 HISTORY MUSEUM   \n",
      "33071                          HISTORIC PRESERVATION   \n",
      "\n",
      "      Zip Code (Administrative Location) City (Physical Location)  \\\n",
      "0                                  99502                      NaN   \n",
      "1                                  99507                      NaN   \n",
      "2                                  99611                      NaN   \n",
      "3                                  99611                      NaN   \n",
      "4                                  99503                      NaN   \n",
      "...                                  ...                      ...   \n",
      "33067                              82801                 SHERIDAN   \n",
      "33068                              82001                 CHEYENNE   \n",
      "33069                              82072                      NaN   \n",
      "33070                              82003                 CHEYENNE   \n",
      "33071                              82190                      NaN   \n",
      "\n",
      "      State (Physical Location)  Zip Code (Physical Location)  Latitude  \\\n",
      "0                           NaN                           NaN  61.17925   \n",
      "1                           NaN                           NaN  61.16890   \n",
      "2                           NaN                           NaN  60.56149   \n",
      "3                           NaN                           NaN  60.56280   \n",
      "4                           NaN                           NaN  61.17925   \n",
      "...                         ...                           ...       ...   \n",
      "33067                        WY                       82801.0  44.82345   \n",
      "33068                        WY                       82001.0  41.13941   \n",
      "33069                       NaN                           NaN  41.32276   \n",
      "33070                        WY                       82003.0  41.13010   \n",
      "33071                       NaN                           NaN  44.91303   \n",
      "\n",
      "       Longitude  Locale Code (NCES)  County Code (FIPS)  State Code (FIPS)  \\\n",
      "0     -149.97254                 1.0                20.0                2.0   \n",
      "1     -149.76708                 4.0                20.0                2.0   \n",
      "2     -151.21598                 3.0               122.0                2.0   \n",
      "3     -151.26597                 3.0               122.0                2.0   \n",
      "4     -149.97254                 1.0                20.0                2.0   \n",
      "...          ...                 ...                 ...                ...   \n",
      "33067 -106.87592                 4.0                33.0               56.0   \n",
      "33068 -104.81813                 1.0                21.0               56.0   \n",
      "33069 -105.57686                 3.0                 1.0               56.0   \n",
      "33070 -104.81916                 1.0                21.0               56.0   \n",
      "33071 -110.41584                 4.0                29.0               56.0   \n",
      "\n",
      "       Region Code (AAM)  Tax Period     Income    Revenue  \n",
      "0                      6    201312.0   602912.0   550236.0  \n",
      "1                      6    201312.0  1379576.0  1323742.0  \n",
      "2                      6    201312.0   740030.0   729080.0  \n",
      "3                      6    201412.0        0.0        0.0  \n",
      "4                      6    201312.0   602912.0   550236.0  \n",
      "...                  ...         ...        ...        ...  \n",
      "33067                  5         NaN        NaN        NaN  \n",
      "33068                  5    201404.0        0.0        0.0  \n",
      "33069                  5    201312.0   208508.0    83981.0  \n",
      "33070                  5    201309.0        0.0        0.0  \n",
      "33071                  5    201312.0   127496.0   126762.0  \n",
      "\n",
      "[33072 rows x 14 columns]\n"
     ]
    },
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "/tmp/ipykernel_79886/482214211.py:2: DtypeWarning: Columns (9,14,21) have mixed types. Specify dtype option on import or set low_memory=False.\n",
      "  df = pd.read_csv(file_path)\n"
     ]
    },
    {
     "data": {
      "text/plain": [
       "Index(['Museum Type', 'Zip Code (Administrative Location)',\n",
       "       'City (Physical Location)', 'State (Physical Location)',\n",
       "       'Zip Code (Physical Location)', 'Latitude', 'Longitude',\n",
       "       'Locale Code (NCES)', 'County Code (FIPS)', 'State Code (FIPS)',\n",
       "       'Region Code (AAM)', 'Tax Period', 'Income', 'Revenue'],\n",
       "      dtype='object')"
      ]
     },
     "execution_count": 14,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "file_path = 'museumDataset.csv'\n",
    "df = pd.read_csv(file_path)\n",
    "for i in [\"Museum ID\", \"Museum Name\", \"Legal Name\", \"Alternate Name\", \"Institution Name\", \"Phone Number\", \"Employer ID Number\", \"Street Address (Administrative Location)\", \"Street Address (Physical Location)\", \"State (Administrative Location)\", \"City (Administrative Location)\"]:\n",
    "    df=df.drop(i, axis=1)\n",
    "print(df)\n",
    "df.columns"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {
    "id": "WEt2Wz708C6a"
   },
   "source": [
    "# EDA\n",
    "\n",
    "Code up the following concepts with regards to EDA.\n",
    "\n",
    "*   Correlation\n",
    "*   Mean, median, mode\n",
    "In addition, write down inferences from the dataset."
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 95,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "array([5, 8, 9, 8, 5])"
      ]
     },
     "execution_count": 95,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "# exp1: numpy array multiplication:\n",
    "a=np.array([1,2,3,4,5])\n",
    "b=np.array([5,4,3,2,1])\n",
    "a*b"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 3,
   "metadata": {
    "id": "RSrcX_7N8Drv"
   },
   "outputs": [
    {
     "data": {
      "text/plain": [
       "<Axes: >"
      ]
     },
     "execution_count": 3,
     "metadata": {},
     "output_type": "execute_result"
    },
    {
     "data": {
      "image/png": "[encoded data, 67416 characters]",
      "text/plain": [
       "<Figure size 640x480 with 2 Axes>"
      ]
     },
     "metadata": {},
     "output_type": "display_data"
    }
   ],
   "source": [
    "# df=df.fillna(0)\n",
    "numericColumns = df.select_dtypes(include=[np.number]).columns.tolist() # https://stackoverflow.com/a/29442936\n",
    "# print(numericColumns)\n",
    "\n",
    "def covariance(x, y):\n",
    "    \"\"\"\n",
    "    from https://www.indeed.com/career-advice/career-development/how-to-calculate-covariance\n",
    "    \"\"\"\n",
    "    xBar = x.mean()\n",
    "    yBar = y.mean()\n",
    "    return ((x-xBar)*(y-yBar)).mean()\n",
    "\n",
    "def correlation(x, y):\n",
    "    return covariance(x, y) / (x.std() * y.std())\n",
    "\n",
    "correlationMat = np.zeros((len(numericColumns), len(numericColumns)))\n",
    "\n",
    "for i in range(len(numericColumns)):\n",
    "    correlationMat[i,i]=1.0\n",
    "    for j in range(i+1, len(numericColumns)):\n",
    "        correlationMat[i][j] =correlationMat[j][i]= correlation(df[numericColumns[i]].dropna(), df[numericColumns[j]].dropna())\n",
    "\n",
    "# print(correlationMat, correlationMat.shape)\n",
    "sns.heatmap(correlationMat, xticklabels=numericColumns, yticklabels=numericColumns, center=0, cmap=\"crest\") # https://seaborn.pydata.org/generated/seaborn.heatmap.html"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 4,
   "metadata": {
    "id": "yqWZAUjO9kRd"
   },
   "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>name</th>\n",
       "      <th>mean</th>\n",
       "      <th>median</th>\n",
       "      <th>mode</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>Zip Code (Physical Location)</td>\n",
       "      <td>4.780564e+04</td>\n",
       "      <td>47448.00000</td>\n",
       "      <td>74743.00000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>Latitude</td>\n",
       "      <td>3.892537e+01</td>\n",
       "      <td>39.83164</td>\n",
       "      <td>40.79792</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>Longitude</td>\n",
       "      <td>-9.081676e+01</td>\n",
       "      <td>-86.77684</td>\n",
       "      <td>-77.86267</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>Locale Code (NCES)</td>\n",
       "      <td>2.505834e+00</td>\n",
       "      <td>2.00000</td>\n",
       "      <td>4.00000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>County Code (FIPS)</td>\n",
       "      <td>8.570193e+01</td>\n",
       "      <td>61.00000</td>\n",
       "      <td>1.00000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>5</th>\n",
       "      <td>State Code (FIPS)</td>\n",
       "      <td>2.906583e+01</td>\n",
       "      <td>29.00000</td>\n",
       "      <td>6.00000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>6</th>\n",
       "      <td>Region Code (AAM)</td>\n",
       "      <td>3.670083e+00</td>\n",
       "      <td>4.00000</td>\n",
       "      <td>4.00000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>7</th>\n",
       "      <td>Tax Period</td>\n",
       "      <td>2.013475e+05</td>\n",
       "      <td>201312.00000</td>\n",
       "      <td>201312.00000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>8</th>\n",
       "      <td>Income</td>\n",
       "      <td>1.069682e+08</td>\n",
       "      <td>8781.00000</td>\n",
       "      <td>0.00000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>9</th>\n",
       "      <td>Revenue</td>\n",
       "      <td>2.097605e+07</td>\n",
       "      <td>3307.00000</td>\n",
       "      <td>0.00000</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "                           name          mean        median          mode\n",
       "0  Zip Code (Physical Location)  4.780564e+04   47448.00000   74743.00000\n",
       "1                      Latitude  3.892537e+01      39.83164      40.79792\n",
       "2                     Longitude -9.081676e+01     -86.77684     -77.86267\n",
       "3            Locale Code (NCES)  2.505834e+00       2.00000       4.00000\n",
       "4            County Code (FIPS)  8.570193e+01      61.00000       1.00000\n",
       "5             State Code (FIPS)  2.906583e+01      29.00000       6.00000\n",
       "6             Region Code (AAM)  3.670083e+00       4.00000       4.00000\n",
       "7                    Tax Period  2.013475e+05  201312.00000  201312.00000\n",
       "8                        Income  1.069682e+08    8781.00000       0.00000\n",
       "9                       Revenue  2.097605e+07    3307.00000       0.00000"
      ]
     },
     "execution_count": 4,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "featureMap = {\"name\":[], \"mean\":[], \"median\":[], \"mode\":[]}\n",
    "for i in numericColumns:\n",
    "    # print(f\"{i}: Mean: {df[i].to_numpy().mean()}, Median: {np.median(df[i].to_numpy())}, Mode: {df[i].mode()[0]}\" )\n",
    "    featureMap[\"name\"].append(i)\n",
    "    featureMap[\"mean\"].append(df[i].dropna().to_numpy().mean())\n",
    "    featureMap[\"median\"].append(np.median(df[i].dropna().to_numpy()))\n",
    "    featureMap[\"mode\"].append(df[i].dropna().mode()[0])\n",
    "\n",
    "featureMap = pd.DataFrame(featureMap)\n",
    "featureMap"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {
    "id": "_xRWSeC99oe1"
   },
   "source": [
    "### Inferences from the dataset\n",
    "\n",
    "* The dataset has a lot of zero and nan values\n",
    "* Income and Revenue are highly correlated\n",
    "* Region code and Zip code are also highly correlated\n",
    "*   \n"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {
    "id": "dbtxb55w9xoF"
   },
   "source": [
    "# Preprocessing\n",
    "Code up the following concepts with regards to Preprocessing. Justify the reason for using them for this specific dataset\n",
    "\n",
    "*   Filling in missing values.\n",
    "*   Encoding\n",
    "\n",
    "Any other techniques that you might need, please justify their usage and code them up."
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {
    "id": "VZZnnUTU9ss3"
   },
   "source": [
    "Conditional Filling:\n",
    "\n",
    "- filling certain nan values based on a model fit over that column and some of the other columns\n",
    "- This will result in linearly dependent features, which can be ignored in the first place.\n",
    "- example: latitude and longitude based street/area code categorical estimation\n"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 5,
   "metadata": {},
   "outputs": [],
   "source": [
    "def countNA(col):\n",
    "    return col.isna().sum()\n",
    "\n",
    "def printNAinDF(frame):\n",
    "    print(\"NaNs in df\")\n",
    "    for i in numericColumns:\n",
    "        print(f\"{i}: {countNA(df[i])}\")"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 6,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "NaNs in df\n",
      "Zip Code (Physical Location): 23851\n",
      "Latitude: 65\n",
      "Longitude: 65\n",
      "Locale Code (NCES): 77\n",
      "County Code (FIPS): 2536\n",
      "State Code (FIPS): 1\n",
      "Region Code (AAM): 0\n",
      "Tax Period: 9792\n",
      "Income: 10111\n",
      "Revenue: 10782\n"
     ]
    }
   ],
   "source": [
    "printNAinDF(df)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 7,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "NaNs in df\n",
      "Zip Code (Physical Location): 0\n",
      "Latitude: 0\n",
      "Longitude: 0\n",
      "Locale Code (NCES): 0\n",
      "County Code (FIPS): 0\n",
      "State Code (FIPS): 0\n",
      "Region Code (AAM): 0\n",
      "Tax Period: 0\n",
      "Income: 0\n",
      "Revenue: 0\n"
     ]
    }
   ],
   "source": [
    "for i in numericColumns:\n",
    "    df[i] = df[i].fillna(df[i].mean())\n",
    "\n",
    "printNAinDF(df)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 15,
   "metadata": {
    "id": "B1aC4Lv--eqR"
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "['Museum Type', 'Zip Code (Administrative Location)', 'City (Physical Location)', 'State (Physical Location)']\n",
      "9\n",
      "15522\n",
      "4481\n",
      "52\n"
     ]
    }
   ],
   "source": [
    "# Encoding\n",
    "# Hint: Figure out which columns need to be encoded. Would One-Hot Encoding be enough for handling this type of data? What are the alternatives?\n",
    "\n",
    "categoricalColumns= df.select_dtypes(include=[\"object\", \"category\"]).columns\n",
    "categoricalColumns=categoricalColumns.to_list()\n",
    "print(categoricalColumns)\n",
    "\n",
    "for i in categoricalColumns:\n",
    "    uniq = set(df[i])\n",
    "    print(len(uniq))"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {
    "id": "_l2tFo0RBlZ9"
   },
   "outputs": [],
   "source": [
    "# Any other preprocessing...?\n"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {
    "colab": {
     "base_uri": "https://localhost:8080/",
     "height": 930
    },
    "id": "CdPfPeMg-gTG",
    "outputId": "1554caf7-37c2-4135-bbdc-aeea16a7a9d2"
   },
   "outputs": [
    {
     "data": {
      "application/vnd.google.colaboratory.intrinsic+json": {
       "type": "dataframe",
       "variable_name": "df"
      },
      "text/html": [
       "\n",
       "  <div id=\"df-648e6204-c75e-4ff8-9030-826148b87a6b\" class=\"colab-df-container\">\n",
       "    <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>Museum ID</th>\n",
       "      <th>Museum Name</th>\n",
       "      <th>Legal Name</th>\n",
       "      <th>Alternate Name</th>\n",
       "      <th>Museum Type</th>\n",
       "      <th>Institution Name</th>\n",
       "      <th>Street Address (Administrative Location)</th>\n",
       "      <th>City (Administrative Location)</th>\n",
       "      <th>State (Administrative Location)</th>\n",
       "      <th>Zip Code (Administrative Location)</th>\n",
       "      <th>...</th>\n",
       "      <th>Latitude</th>\n",
       "      <th>Longitude</th>\n",
       "      <th>Locale Code (NCES)</th>\n",
       "      <th>County Code (FIPS)</th>\n",
       "      <th>State Code (FIPS)</th>\n",
       "      <th>Region Code (AAM)</th>\n",
       "      <th>Employer ID Number</th>\n",
       "      <th>Tax Period</th>\n",
       "      <th>Income</th>\n",
       "      <th>Revenue</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>8400200098</td>\n",
       "      <td>ALASKA AVIATION HERITAGE MUSEUM</td>\n",
       "      <td>ALASKA AVIATION HERITAGE MUSEUM</td>\n",
       "      <td>NaN</td>\n",
       "      <td>HISTORY MUSEUM</td>\n",
       "      <td>NaN</td>\n",
       "      <td>4721 AIRCRAFT DR</td>\n",
       "      <td>153</td>\n",
       "      <td>0</td>\n",
       "      <td>99502</td>\n",
       "      <td>...</td>\n",
       "      <td>61.17925</td>\n",
       "      <td>-149.97254</td>\n",
       "      <td>1.0</td>\n",
       "      <td>20.0</td>\n",
       "      <td>2.0</td>\n",
       "      <td>6</td>\n",
       "      <td>920071852</td>\n",
       "      <td>201312.000000</td>\n",
       "      <td>6.029120e+05</td>\n",
       "      <td>5.502360e+05</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>8400200117</td>\n",
       "      <td>ALASKA BOTANICAL GARDEN</td>\n",
       "      <td>ALASKA BOTANICAL GARDEN INC</td>\n",
       "      <td>NaN</td>\n",
       "      <td>ARBORETUM, BOTANICAL GARDEN, OR NATURE CENTER</td>\n",
       "      <td>NaN</td>\n",
       "      <td>4601 CAMPBELL AIRSTRIP RD</td>\n",
       "      <td>153</td>\n",
       "      <td>0</td>\n",
       "      <td>99507</td>\n",
       "      <td>...</td>\n",
       "      <td>61.16890</td>\n",
       "      <td>-149.76708</td>\n",
       "      <td>4.0</td>\n",
       "      <td>20.0</td>\n",
       "      <td>2.0</td>\n",
       "      <td>6</td>\n",
       "      <td>920115504</td>\n",
       "      <td>201312.000000</td>\n",
       "      <td>1.379576e+06</td>\n",
       "      <td>1.323742e+06</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>8400200153</td>\n",
       "      <td>ALASKA CHALLENGER CENTER FOR SPACE SCIENCE TEC...</td>\n",
       "      <td>ALASKA CHALLENGER CENTER FOR SPACE SCIENCE TEC...</td>\n",
       "      <td>NaN</td>\n",
       "      <td>SCIENCE &amp; TECHNOLOGY MUSEUM OR PLANETARIUM</td>\n",
       "      <td>NaN</td>\n",
       "      <td>9711 KENAI SPUR HWY</td>\n",
       "      <td>3809</td>\n",
       "      <td>0</td>\n",
       "      <td>99611</td>\n",
       "      <td>...</td>\n",
       "      <td>60.56149</td>\n",
       "      <td>-151.21598</td>\n",
       "      <td>3.0</td>\n",
       "      <td>122.0</td>\n",
       "      <td>2.0</td>\n",
       "      <td>6</td>\n",
       "      <td>921761906</td>\n",
       "      <td>201312.000000</td>\n",
       "      <td>7.400300e+05</td>\n",
       "      <td>7.290800e+05</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>8400200143</td>\n",
       "      <td>ALASKA EDUCATORS HISTORICAL SOCIETY</td>\n",
       "      <td>ALASKA EDUCATORS HISTORICAL SOCIETY</td>\n",
       "      <td>NaN</td>\n",
       "      <td>HISTORIC PRESERVATION</td>\n",
       "      <td>NaN</td>\n",
       "      <td>214 BIRCH STREET</td>\n",
       "      <td>3809</td>\n",
       "      <td>0</td>\n",
       "      <td>99611</td>\n",
       "      <td>...</td>\n",
       "      <td>60.56280</td>\n",
       "      <td>-151.26597</td>\n",
       "      <td>3.0</td>\n",
       "      <td>122.0</td>\n",
       "      <td>2.0</td>\n",
       "      <td>6</td>\n",
       "      <td>920165178</td>\n",
       "      <td>201412.000000</td>\n",
       "      <td>0.000000e+00</td>\n",
       "      <td>0.000000e+00</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>8400200027</td>\n",
       "      <td>ALASKA HERITAGE MUSEUM</td>\n",
       "      <td>ALASKA AVIATION HERITAGE MUSEUM</td>\n",
       "      <td>NaN</td>\n",
       "      <td>HISTORY MUSEUM</td>\n",
       "      <td>NaN</td>\n",
       "      <td>301 W NORTHERN LIGHTS BLVD</td>\n",
       "      <td>153</td>\n",
       "      <td>0</td>\n",
       "      <td>99503</td>\n",
       "      <td>...</td>\n",
       "      <td>61.17925</td>\n",
       "      <td>-149.97254</td>\n",
       "      <td>1.0</td>\n",
       "      <td>20.0</td>\n",
       "      <td>2.0</td>\n",
       "      <td>6</td>\n",
       "      <td>920071852</td>\n",
       "      <td>201312.000000</td>\n",
       "      <td>6.029120e+05</td>\n",
       "      <td>5.502360e+05</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>33067</th>\n",
       "      <td>8405600184</td>\n",
       "      <td>WYOMING STATE HISTORICAL SOCIETY</td>\n",
       "      <td>WYOMING STATE HISTORICAL SOCIETY</td>\n",
       "      <td>NaN</td>\n",
       "      <td>HISTORIC PRESERVATION</td>\n",
       "      <td>NaN</td>\n",
       "      <td>PO BOX 73</td>\n",
       "      <td>7003</td>\n",
       "      <td>50</td>\n",
       "      <td>82801</td>\n",
       "      <td>...</td>\n",
       "      <td>44.82345</td>\n",
       "      <td>-106.87592</td>\n",
       "      <td>4.0</td>\n",
       "      <td>33.0</td>\n",
       "      <td>56.0</td>\n",
       "      <td>5</td>\n",
       "      <td>836007540.0</td>\n",
       "      <td>201347.458548</td>\n",
       "      <td>1.069682e+08</td>\n",
       "      <td>2.097605e+07</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>33068</th>\n",
       "      <td>8405600061</td>\n",
       "      <td>WYOMING STATE MUSEUM</td>\n",
       "      <td>WYOMING STATE MUSEUM VOLUNTEERS INC</td>\n",
       "      <td>NaN</td>\n",
       "      <td>GENERAL MUSEUM</td>\n",
       "      <td>NaN</td>\n",
       "      <td>2301 CENTRAL AVENUE</td>\n",
       "      <td>1323</td>\n",
       "      <td>50</td>\n",
       "      <td>82001</td>\n",
       "      <td>...</td>\n",
       "      <td>41.13941</td>\n",
       "      <td>-104.81813</td>\n",
       "      <td>1.0</td>\n",
       "      <td>21.0</td>\n",
       "      <td>56.0</td>\n",
       "      <td>5</td>\n",
       "      <td>237368629.0</td>\n",
       "      <td>201404.000000</td>\n",
       "      <td>0.000000e+00</td>\n",
       "      <td>0.000000e+00</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>33069</th>\n",
       "      <td>8405600158</td>\n",
       "      <td>WYOMING TERRITORIAL PARK HISTORIC ASSOCIATION</td>\n",
       "      <td>WYOMING TERRITORIAL PARK HISTORIC ASSOCIATION INC</td>\n",
       "      <td>NaN</td>\n",
       "      <td>HISTORIC PRESERVATION</td>\n",
       "      <td>NaN</td>\n",
       "      <td>1273 N 15TH ST STE 121</td>\n",
       "      <td>4101</td>\n",
       "      <td>50</td>\n",
       "      <td>82072</td>\n",
       "      <td>...</td>\n",
       "      <td>41.32276</td>\n",
       "      <td>-105.57686</td>\n",
       "      <td>3.0</td>\n",
       "      <td>1.0</td>\n",
       "      <td>56.0</td>\n",
       "      <td>5</td>\n",
       "      <td>830318392.0</td>\n",
       "      <td>201312.000000</td>\n",
       "      <td>2.085080e+05</td>\n",
       "      <td>8.398100e+04</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>33070</th>\n",
       "      <td>8405600137</td>\n",
       "      <td>WYOMING TRANSPORTATION MUSEUM</td>\n",
       "      <td>WYOMING TRANSPORTATION MUSEUM CORP</td>\n",
       "      <td>NaN</td>\n",
       "      <td>HISTORY MUSEUM</td>\n",
       "      <td>NaN</td>\n",
       "      <td>PO BOX 704</td>\n",
       "      <td>1323</td>\n",
       "      <td>50</td>\n",
       "      <td>82003</td>\n",
       "      <td>...</td>\n",
       "      <td>41.13010</td>\n",
       "      <td>-104.81916</td>\n",
       "      <td>1.0</td>\n",
       "      <td>21.0</td>\n",
       "      <td>56.0</td>\n",
       "      <td>5</td>\n",
       "      <td>830295570.0</td>\n",
       "      <td>201309.000000</td>\n",
       "      <td>0.000000e+00</td>\n",
       "      <td>0.000000e+00</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>33071</th>\n",
       "      <td>8405600199</td>\n",
       "      <td>YELLOWSTONE NATIONAL PARK</td>\n",
       "      <td>LITTLE PEOPLE LEARNING CENTER INC</td>\n",
       "      <td>NaN</td>\n",
       "      <td>HISTORIC PRESERVATION</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NATIONAL PARK SERVICE</td>\n",
       "      <td>8575</td>\n",
       "      <td>50</td>\n",
       "      <td>82190</td>\n",
       "      <td>...</td>\n",
       "      <td>44.91303</td>\n",
       "      <td>-110.41584</td>\n",
       "      <td>4.0</td>\n",
       "      <td>29.0</td>\n",
       "      <td>56.0</td>\n",
       "      <td>5</td>\n",
       "      <td>830249072.0</td>\n",
       "      <td>201312.000000</td>\n",
       "      <td>1.274960e+05</td>\n",
       "      <td>1.267620e+05</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "<p>33072 rows × 25 columns</p>\n",
       "</div>\n",
       "    <div class=\"colab-df-buttons\">\n",
       "\n",
       "  <div class=\"colab-df-container\">\n",
       "    <button class=\"colab-df-convert\" onclick=\"convertToInteractive('df-648e6204-c75e-4ff8-9030-826148b87a6b')\"\n",
       "            title=\"Convert this dataframe to an interactive table.\"\n",
       "            style=\"display:none;\">\n",
       "\n",
       "  <svg xmlns=\"http://www.w3.org/2000/svg\" height=\"24px\" viewBox=\"0 -960 960 960\">\n",
       "    <path d=\"M120-120v-720h720v720H120Zm60-500h600v-160H180v160Zm220 220h160v-160H400v160Zm0 220h160v-160H400v160ZM180-400h160v-160H180v160Zm440 0h160v-160H620v160ZM180-180h160v-160H180v160Zm440 0h160v-160H620v160Z\"/>\n",
       "  </svg>\n",
       "    </button>\n",
       "\n",
       "  <style>\n",
       "    .colab-df-container {\n",
       "      display:flex;\n",
       "      gap: 12px;\n",
       "    }\n",
       "\n",
       "    .colab-df-convert {\n",
       "      background-color: #E8F0FE;\n",
       "      border: none;\n",
       "      border-radius: 50%;\n",
       "      cursor: pointer;\n",
       "      display: none;\n",
       "      fill: #1967D2;\n",
       "      height: 32px;\n",
       "      padding: 0 0 0 0;\n",
       "      width: 32px;\n",
       "    }\n",
       "\n",
       "    .colab-df-convert:hover {\n",
       "      background-color: #E2EBFA;\n",
       "      box-shadow: 0px 1px 2px rgba(60, 64, 67, 0.3), 0px 1px 3px 1px rgba(60, 64, 67, 0.15);\n",
       "      fill: #174EA6;\n",
       "    }\n",
       "\n",
       "    .colab-df-buttons div {\n",
       "      margin-bottom: 4px;\n",
       "    }\n",
       "\n",
       "    [theme=dark] .colab-df-convert {\n",
       "      background-color: #3B4455;\n",
       "      fill: #D2E3FC;\n",
       "    }\n",
       "\n",
       "    [theme=dark] .colab-df-convert:hover {\n",
       "      background-color: #434B5C;\n",
       "      box-shadow: 0px 1px 3px 1px rgba(0, 0, 0, 0.15);\n",
       "      filter: drop-shadow(0px 1px 2px rgba(0, 0, 0, 0.3));\n",
       "      fill: #FFFFFF;\n",
       "    }\n",
       "  </style>\n",
       "\n",
       "    <script>\n",
       "      const buttonEl =\n",
       "        document.querySelector('#df-648e6204-c75e-4ff8-9030-826148b87a6b button.colab-df-convert');\n",
       "      buttonEl.style.display =\n",
       "        google.colab.kernel.accessAllowed ? 'block' : 'none';\n",
       "\n",
       "      async function convertToInteractive(key) {\n",
       "        const element = document.querySelector('#df-648e6204-c75e-4ff8-9030-826148b87a6b');\n",
       "        const dataTable =\n",
       "          await google.colab.kernel.invokeFunction('convertToInteractive',\n",
       "                                                    [key], {});\n",
       "        if (!dataTable) return;\n",
       "\n",
       "        const docLinkHtml = 'Like what you see? Visit the ' +\n",
       "          '<a target=\"_blank\" href=https://colab.research.google.com/notebooks/data_table.ipynb>data table notebook</a>'\n",
       "          + ' to learn more about interactive tables.';\n",
       "        element.innerHTML = '';\n",
       "        dataTable['output_type'] = 'display_data';\n",
       "        await google.colab.output.renderOutput(dataTable, element);\n",
       "        const docLink = document.createElement('div');\n",
       "        docLink.innerHTML = docLinkHtml;\n",
       "        element.appendChild(docLink);\n",
       "      }\n",
       "    </script>\n",
       "  </div>\n",
       "\n",
       "\n",
       "<div id=\"df-4abe840c-7d36-44a5-9d79-0ae4d832ae62\">\n",
       "  <button class=\"colab-df-quickchart\" onclick=\"quickchart('df-4abe840c-7d36-44a5-9d79-0ae4d832ae62')\"\n",
       "            title=\"Suggest charts\"\n",
       "            style=\"display:none;\">\n",
       "\n",
       "<svg xmlns=\"http://www.w3.org/2000/svg\" height=\"24px\"viewBox=\"0 0 24 24\"\n",
       "     width=\"24px\">\n",
       "    <g>\n",
       "        <path d=\"M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zM9 17H7v-7h2v7zm4 0h-2V7h2v10zm4 0h-2v-4h2v4z\"/>\n",
       "    </g>\n",
       "</svg>\n",
       "  </button>\n",
       "\n",
       "<style>\n",
       "  .colab-df-quickchart {\n",
       "      --bg-color: #E8F0FE;\n",
       "      --fill-color: #1967D2;\n",
       "      --hover-bg-color: #E2EBFA;\n",
       "      --hover-fill-color: #174EA6;\n",
       "      --disabled-fill-color: #AAA;\n",
       "      --disabled-bg-color: #DDD;\n",
       "  }\n",
       "\n",
       "  [theme=dark] .colab-df-quickchart {\n",
       "      --bg-color: #3B4455;\n",
       "      --fill-color: #D2E3FC;\n",
       "      --hover-bg-color: #434B5C;\n",
       "      --hover-fill-color: #FFFFFF;\n",
       "      --disabled-bg-color: #3B4455;\n",
       "      --disabled-fill-color: #666;\n",
       "  }\n",
       "\n",
       "  .colab-df-quickchart {\n",
       "    background-color: var(--bg-color);\n",
       "    border: none;\n",
       "    border-radius: 50%;\n",
       "    cursor: pointer;\n",
       "    display: none;\n",
       "    fill: var(--fill-color);\n",
       "    height: 32px;\n",
       "    padding: 0;\n",
       "    width: 32px;\n",
       "  }\n",
       "\n",
       "  .colab-df-quickchart:hover {\n",
       "    background-color: var(--hover-bg-color);\n",
       "    box-shadow: 0 1px 2px rgba(60, 64, 67, 0.3), 0 1px 3px 1px rgba(60, 64, 67, 0.15);\n",
       "    fill: var(--button-hover-fill-color);\n",
       "  }\n",
       "\n",
       "  .colab-df-quickchart-complete:disabled,\n",
       "  .colab-df-quickchart-complete:disabled:hover {\n",
       "    background-color: var(--disabled-bg-color);\n",
       "    fill: var(--disabled-fill-color);\n",
       "    box-shadow: none;\n",
       "  }\n",
       "\n",
       "  .colab-df-spinner {\n",
       "    border: 2px solid var(--fill-color);\n",
       "    border-color: transparent;\n",
       "    border-bottom-color: var(--fill-color);\n",
       "    animation:\n",
       "      spin 1s steps(1) infinite;\n",
       "  }\n",
       "\n",
       "  @keyframes spin {\n",
       "    0% {\n",
       "      border-color: transparent;\n",
       "      border-bottom-color: var(--fill-color);\n",
       "      border-left-color: var(--fill-color);\n",
       "    }\n",
       "    20% {\n",
       "      border-color: transparent;\n",
       "      border-left-color: var(--fill-color);\n",
       "      border-top-color: var(--fill-color);\n",
       "    }\n",
       "    30% {\n",
       "      border-color: transparent;\n",
       "      border-left-color: var(--fill-color);\n",
       "      border-top-color: var(--fill-color);\n",
       "      border-right-color: var(--fill-color);\n",
       "    }\n",
       "    40% {\n",
       "      border-color: transparent;\n",
       "      border-right-color: var(--fill-color);\n",
       "      border-top-color: var(--fill-color);\n",
       "    }\n",
       "    60% {\n",
       "      border-color: transparent;\n",
       "      border-right-color: var(--fill-color);\n",
       "    }\n",
       "    80% {\n",
       "      border-color: transparent;\n",
       "      border-right-color: var(--fill-color);\n",
       "      border-bottom-color: var(--fill-color);\n",
       "    }\n",
       "    90% {\n",
       "      border-color: transparent;\n",
       "      border-bottom-color: var(--fill-color);\n",
       "    }\n",
       "  }\n",
       "</style>\n",
       "\n",
       "  <script>\n",
       "    async function quickchart(key) {\n",
       "      const quickchartButtonEl =\n",
       "        document.querySelector('#' + key + ' button');\n",
       "      quickchartButtonEl.disabled = true;  // To prevent multiple clicks.\n",
       "      quickchartButtonEl.classList.add('colab-df-spinner');\n",
       "      try {\n",
       "        const charts = await google.colab.kernel.invokeFunction(\n",
       "            'suggestCharts', [key], {});\n",
       "      } catch (error) {\n",
       "        console.error('Error during call to suggestCharts:', error);\n",
       "      }\n",
       "      quickchartButtonEl.classList.remove('colab-df-spinner');\n",
       "      quickchartButtonEl.classList.add('colab-df-quickchart-complete');\n",
       "    }\n",
       "    (() => {\n",
       "      let quickchartButtonEl =\n",
       "        document.querySelector('#df-4abe840c-7d36-44a5-9d79-0ae4d832ae62 button');\n",
       "      quickchartButtonEl.style.display =\n",
       "        google.colab.kernel.accessAllowed ? 'block' : 'none';\n",
       "    })();\n",
       "  </script>\n",
       "</div>\n",
       "\n",
       "  <div id=\"id_d53297d3-063b-4f7f-aabb-8e56b146b49d\">\n",
       "    <style>\n",
       "      .colab-df-generate {\n",
       "        background-color: #E8F0FE;\n",
       "        border: none;\n",
       "        border-radius: 50%;\n",
       "        cursor: pointer;\n",
       "        display: none;\n",
       "        fill: #1967D2;\n",
       "        height: 32px;\n",
       "        padding: 0 0 0 0;\n",
       "        width: 32px;\n",
       "      }\n",
       "\n",
       "      .colab-df-generate:hover {\n",
       "        background-color: #E2EBFA;\n",
       "        box-shadow: 0px 1px 2px rgba(60, 64, 67, 0.3), 0px 1px 3px 1px rgba(60, 64, 67, 0.15);\n",
       "        fill: #174EA6;\n",
       "      }\n",
       "\n",
       "      [theme=dark] .colab-df-generate {\n",
       "        background-color: #3B4455;\n",
       "        fill: #D2E3FC;\n",
       "      }\n",
       "\n",
       "      [theme=dark] .colab-df-generate:hover {\n",
       "        background-color: #434B5C;\n",
       "        box-shadow: 0px 1px 3px 1px rgba(0, 0, 0, 0.15);\n",
       "        filter: drop-shadow(0px 1px 2px rgba(0, 0, 0, 0.3));\n",
       "        fill: #FFFFFF;\n",
       "      }\n",
       "    </style>\n",
       "    <button class=\"colab-df-generate\" onclick=\"generateWithVariable('df')\"\n",
       "            title=\"Generate code using this dataframe.\"\n",
       "            style=\"display:none;\">\n",
       "\n",
       "  <svg xmlns=\"http://www.w3.org/2000/svg\" height=\"24px\"viewBox=\"0 0 24 24\"\n",
       "       width=\"24px\">\n",
       "    <path d=\"M7,19H8.4L18.45,9,17,7.55,7,17.6ZM5,21V16.75L18.45,3.32a2,2,0,0,1,2.83,0l1.4,1.43a1.91,1.91,0,0,1,.58,1.4,1.91,1.91,0,0,1-.58,1.4L9.25,21ZM18.45,9,17,7.55Zm-12,3A5.31,5.31,0,0,0,4.9,8.1,5.31,5.31,0,0,0,1,6.5,5.31,5.31,0,0,0,4.9,4.9,5.31,5.31,0,0,0,6.5,1,5.31,5.31,0,0,0,8.1,4.9,5.31,5.31,0,0,0,12,6.5,5.46,5.46,0,0,0,6.5,12Z\"/>\n",
       "  </svg>\n",
       "    </button>\n",
       "    <script>\n",
       "      (() => {\n",
       "      const buttonEl =\n",
       "        document.querySelector('#id_d53297d3-063b-4f7f-aabb-8e56b146b49d button.colab-df-generate');\n",
       "      buttonEl.style.display =\n",
       "        google.colab.kernel.accessAllowed ? 'block' : 'none';\n",
       "\n",
       "      buttonEl.onclick = () => {\n",
       "        google.colab.notebook.generateWithVariable('df');\n",
       "      }\n",
       "      })();\n",
       "    </script>\n",
       "  </div>\n",
       "\n",
       "    </div>\n",
       "  </div>\n"
      ],
      "text/plain": [
       "        Museum ID                                        Museum Name  \\\n",
       "0      8400200098                    ALASKA AVIATION HERITAGE MUSEUM   \n",
       "1      8400200117                            ALASKA BOTANICAL GARDEN   \n",
       "2      8400200153  ALASKA CHALLENGER CENTER FOR SPACE SCIENCE TEC...   \n",
       "3      8400200143                ALASKA EDUCATORS HISTORICAL SOCIETY   \n",
       "4      8400200027                             ALASKA HERITAGE MUSEUM   \n",
       "...           ...                                                ...   \n",
       "33067  8405600184                   WYOMING STATE HISTORICAL SOCIETY   \n",
       "33068  8405600061                               WYOMING STATE MUSEUM   \n",
       "33069  8405600158      WYOMING TERRITORIAL PARK HISTORIC ASSOCIATION   \n",
       "33070  8405600137                      WYOMING TRANSPORTATION MUSEUM   \n",
       "33071  8405600199                          YELLOWSTONE NATIONAL PARK   \n",
       "\n",
       "                                              Legal Name Alternate Name  \\\n",
       "0                        ALASKA AVIATION HERITAGE MUSEUM            NaN   \n",
       "1                            ALASKA BOTANICAL GARDEN INC            NaN   \n",
       "2      ALASKA CHALLENGER CENTER FOR SPACE SCIENCE TEC...            NaN   \n",
       "3                    ALASKA EDUCATORS HISTORICAL SOCIETY            NaN   \n",
       "4                        ALASKA AVIATION HERITAGE MUSEUM            NaN   \n",
       "...                                                  ...            ...   \n",
       "33067                   WYOMING STATE HISTORICAL SOCIETY            NaN   \n",
       "33068                WYOMING STATE MUSEUM VOLUNTEERS INC            NaN   \n",
       "33069  WYOMING TERRITORIAL PARK HISTORIC ASSOCIATION INC            NaN   \n",
       "33070                 WYOMING TRANSPORTATION MUSEUM CORP            NaN   \n",
       "33071                  LITTLE PEOPLE LEARNING CENTER INC            NaN   \n",
       "\n",
       "                                         Museum Type Institution Name  \\\n",
       "0                                     HISTORY MUSEUM              NaN   \n",
       "1      ARBORETUM, BOTANICAL GARDEN, OR NATURE CENTER              NaN   \n",
       "2         SCIENCE & TECHNOLOGY MUSEUM OR PLANETARIUM              NaN   \n",
       "3                              HISTORIC PRESERVATION              NaN   \n",
       "4                                     HISTORY MUSEUM              NaN   \n",
       "...                                              ...              ...   \n",
       "33067                          HISTORIC PRESERVATION              NaN   \n",
       "33068                                 GENERAL MUSEUM              NaN   \n",
       "33069                          HISTORIC PRESERVATION              NaN   \n",
       "33070                                 HISTORY MUSEUM              NaN   \n",
       "33071                          HISTORIC PRESERVATION              NaN   \n",
       "\n",
       "      Street Address (Administrative Location)  \\\n",
       "0                             4721 AIRCRAFT DR   \n",
       "1                    4601 CAMPBELL AIRSTRIP RD   \n",
       "2                          9711 KENAI SPUR HWY   \n",
       "3                             214 BIRCH STREET   \n",
       "4                   301 W NORTHERN LIGHTS BLVD   \n",
       "...                                        ...   \n",
       "33067                                PO BOX 73   \n",
       "33068                      2301 CENTRAL AVENUE   \n",
       "33069                   1273 N 15TH ST STE 121   \n",
       "33070                               PO BOX 704   \n",
       "33071                    NATIONAL PARK SERVICE   \n",
       "\n",
       "       City (Administrative Location)  State (Administrative Location)  \\\n",
       "0                                 153                                0   \n",
       "1                                 153                                0   \n",
       "2                                3809                                0   \n",
       "3                                3809                                0   \n",
       "4                                 153                                0   \n",
       "...                               ...                              ...   \n",
       "33067                            7003                               50   \n",
       "33068                            1323                               50   \n",
       "33069                            4101                               50   \n",
       "33070                            1323                               50   \n",
       "33071                            8575                               50   \n",
       "\n",
       "      Zip Code (Administrative Location)  ...  Latitude  Longitude  \\\n",
       "0                                  99502  ...  61.17925 -149.97254   \n",
       "1                                  99507  ...  61.16890 -149.76708   \n",
       "2                                  99611  ...  60.56149 -151.21598   \n",
       "3                                  99611  ...  60.56280 -151.26597   \n",
       "4                                  99503  ...  61.17925 -149.97254   \n",
       "...                                  ...  ...       ...        ...   \n",
       "33067                              82801  ...  44.82345 -106.87592   \n",
       "33068                              82001  ...  41.13941 -104.81813   \n",
       "33069                              82072  ...  41.32276 -105.57686   \n",
       "33070                              82003  ...  41.13010 -104.81916   \n",
       "33071                              82190  ...  44.91303 -110.41584   \n",
       "\n",
       "      Locale Code (NCES)  County Code (FIPS) State Code (FIPS)  \\\n",
       "0                    1.0                20.0               2.0   \n",
       "1                    4.0                20.0               2.0   \n",
       "2                    3.0               122.0               2.0   \n",
       "3                    3.0               122.0               2.0   \n",
       "4                    1.0                20.0               2.0   \n",
       "...                  ...                 ...               ...   \n",
       "33067                4.0                33.0              56.0   \n",
       "33068                1.0                21.0              56.0   \n",
       "33069                3.0                 1.0              56.0   \n",
       "33070                1.0                21.0              56.0   \n",
       "33071                4.0                29.0              56.0   \n",
       "\n",
       "       Region Code (AAM)  Employer ID Number     Tax Period        Income  \\\n",
       "0                      6           920071852  201312.000000  6.029120e+05   \n",
       "1                      6           920115504  201312.000000  1.379576e+06   \n",
       "2                      6           921761906  201312.000000  7.400300e+05   \n",
       "3                      6           920165178  201412.000000  0.000000e+00   \n",
       "4                      6           920071852  201312.000000  6.029120e+05   \n",
       "...                  ...                 ...            ...           ...   \n",
       "33067                  5         836007540.0  201347.458548  1.069682e+08   \n",
       "33068                  5         237368629.0  201404.000000  0.000000e+00   \n",
       "33069                  5         830318392.0  201312.000000  2.085080e+05   \n",
       "33070                  5         830295570.0  201309.000000  0.000000e+00   \n",
       "33071                  5         830249072.0  201312.000000  1.274960e+05   \n",
       "\n",
       "            Revenue  \n",
       "0      5.502360e+05  \n",
       "1      1.323742e+06  \n",
       "2      7.290800e+05  \n",
       "3      0.000000e+00  \n",
       "4      5.502360e+05  \n",
       "...             ...  \n",
       "33067  2.097605e+07  \n",
       "33068  0.000000e+00  \n",
       "33069  8.398100e+04  \n",
       "33070  0.000000e+00  \n",
       "33071  1.267620e+05  \n",
       "\n",
       "[33072 rows x 25 columns]"
      ]
     },
     "execution_count": 31,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "# Final dataset"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {
    "id": "hFzaF_CMBrCd"
   },
   "outputs": [],
   "source": []
  }
 ],
 "metadata": {
  "colab": {
   "provenance": [],
   "toc_visible": true
  },
  "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.11.9"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 4
}
