diff --git "a/data_01_027/cluster_entropy_analysis.ipynb" "b/data_01_027/cluster_entropy_analysis.ipynb"
new file mode 100644--- /dev/null
+++ "b/data_01_027/cluster_entropy_analysis.ipynb"
@@ -0,0 +1,4012 @@
+{
+ "cells": [
+ {
+ "cell_type": "code",
+ "execution_count": 40,
+ "id": "3d93276e-d83e-48b7-95be-aaaa89244ef9",
+ "metadata": {},
+ "outputs": [],
+ "source": [
+ "import numpy as np\n",
+ "import pandas as pd\n",
+ "import json\n",
+ "import scipy\n",
+ "from itertools import chain"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 2,
+ "id": "f57c50ca-3581-4412-a160-774f998ce9df",
+ "metadata": {},
+ "outputs": [],
+ "source": [
+ "with open(\"./id_all_blip_clusters_12.json\") as f:\n",
+ " d_12 = json.load(f)\n",
+ "\n",
+ "with open(\"./id_all_blip_clusters_24.json\") as f:\n",
+ " d_24 = json.load(f)\n",
+ "\n",
+ "with open(\"./id_all_blip_clusters_48.json\") as f:\n",
+ " d_48 = json.load(f)"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": null,
+ "id": "dcab249b-8c66-464f-a41c-a9ae5ab3ad71",
+ "metadata": {},
+ "outputs": [],
+ "source": [
+ "# p(cluster | ethnicity, model)\n",
+ "# p(cluster | gender, model)\n",
+ "# p(cluster | gender, ethnicity, model) DONE\n",
+ "# p(cluster | ethnicity) DONE\n",
+ "# p(cluster | gender) DONE\n",
+ "# p(cluster | gender, ethnicity)\n",
+ "# p(cluster | model) ADDED, DONE"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "id": "aff706c7-acb0-460a-bc09-4ce673f8a641",
+ "metadata": {},
+ "source": [
+ "# Ethnicities"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 74,
+ "id": "84e4a4d4-d79b-4666-a7bf-a7532f143019",
+ "metadata": {},
+ "outputs": [],
+ "source": [
+ "entropies = []\n",
+ "random_entropies = []\n",
+ "for cluster_dicts in [d_12, d_24, d_48]:\n",
+ " entropy = dict()\n",
+ " random_entropy = dict()\n",
+ " n_clusters = len(cluster_dicts)\n",
+ " all_ethnicities = [list(dict(d['labels_ethnicity']).keys()) for d in cluster_dicts]\n",
+ " all_ethnicities = list(set(chain(*all_ethnicities)))\n",
+ " for ethnicity in all_ethnicities:\n",
+ " h = []\n",
+ " for i in cluster_dicts:\n",
+ " h.append(dict(i['labels_ethnicity']).get(ethnicity, 0))\n",
+ " h = np.array(h)\n",
+ " r = np.ones_like(h)\n",
+ " entropy[ethnicity] = scipy.stats.entropy(h / sum(h), base=2)\n",
+ " random_entropy[ethnicity] = scipy.stats.entropy(r, base=2)\n",
+ " entropies.append(entropy)\n",
+ " random_entropies.append(random_entropy)"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 79,
+ "id": "0abbdcb0-b06a-4905-8d8e-c3340f8b7e05",
+ "metadata": {},
+ "outputs": [
+ {
+ "data": {
+ "text/plain": [
+ "5.584962500721156"
+ ]
+ },
+ "execution_count": 79,
+ "metadata": {},
+ "output_type": "execute_result"
+ }
+ ],
+ "source": [
+ "np.log2(48)"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 75,
+ "id": "fd938629-c0bf-48c2-b585-5e6a53b8c52d",
+ "metadata": {},
+ "outputs": [
+ {
+ "data": {
+ "text/plain": [
+ "{'': 5.584962500721156,\n",
+ " 'Latinx': 5.584962500721156,\n",
+ " 'African-American': 5.584962500721156,\n",
+ " 'Hispanic': 5.584962500721156,\n",
+ " 'Indigenous American': 5.584962500721156,\n",
+ " 'First Nations': 5.584962500721156,\n",
+ " 'Black': 5.584962500721156,\n",
+ " 'Multiracial': 5.584962500721156,\n",
+ " 'Latino': 5.584962500721156,\n",
+ " 'Southeast Asian': 5.584962500721156,\n",
+ " 'American Indian': 5.584962500721156,\n",
+ " 'South Asian': 5.584962500721156,\n",
+ " 'Caucasian': 5.584962500721156,\n",
+ " 'Native American': 5.584962500721156,\n",
+ " 'East Asian': 5.584962500721156,\n",
+ " 'Pacific Islander': 5.584962500721156,\n",
+ " 'White': 5.584962500721156}"
+ ]
+ },
+ "execution_count": 75,
+ "metadata": {},
+ "output_type": "execute_result"
+ }
+ ],
+ "source": [
+ "random_entropy"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 53,
+ "id": "0bfc516f-53e0-4f41-bd46-7375913840d6",
+ "metadata": {},
+ "outputs": [
+ {
+ "data": {
+ "text/html": [
+ "\n",
+ "
\n",
+ " \n",
+ " \n",
+ " | \n",
+ " entropy | \n",
+ "
\n",
+ " \n",
+ " \n",
+ " \n",
+ " Pacific Islander | \n",
+ " 3.05 | \n",
+ "
\n",
+ " \n",
+ " Latino | \n",
+ " 2.75 | \n",
+ "
\n",
+ " \n",
+ " Latinx | \n",
+ " 2.70 | \n",
+ "
\n",
+ " \n",
+ " Hispanic | \n",
+ " 2.61 | \n",
+ "
\n",
+ " \n",
+ " Multiracial | \n",
+ " 2.50 | \n",
+ "
\n",
+ " \n",
+ " Southeast Asian | \n",
+ " 2.42 | \n",
+ "
\n",
+ " \n",
+ " First Nations | \n",
+ " 2.38 | \n",
+ "
\n",
+ " \n",
+ " Indigenous American | \n",
+ " 2.19 | \n",
+ "
\n",
+ " \n",
+ " Caucasian | \n",
+ " 2.08 | \n",
+ "
\n",
+ " \n",
+ " White | \n",
+ " 2.04 | \n",
+ "
\n",
+ " \n",
+ " Native American | \n",
+ " 1.91 | \n",
+ "
\n",
+ " \n",
+ " American Indian | \n",
+ " 1.88 | \n",
+ "
\n",
+ " \n",
+ " | \n",
+ " 1.69 | \n",
+ "
\n",
+ " \n",
+ " East Asian | \n",
+ " 1.62 | \n",
+ "
\n",
+ " \n",
+ " Black | \n",
+ " 1.54 | \n",
+ "
\n",
+ " \n",
+ " African-American | \n",
+ " 1.49 | \n",
+ "
\n",
+ " \n",
+ " South Asian | \n",
+ " 1.32 | \n",
+ "
\n",
+ " \n",
+ "
\n"
+ ],
+ "text/plain": [
+ ""
+ ]
+ },
+ "metadata": {},
+ "output_type": "display_data"
+ },
+ {
+ "data": {
+ "text/html": [
+ "\n",
+ "\n",
+ " \n",
+ " \n",
+ " | \n",
+ " entropy | \n",
+ "
\n",
+ " \n",
+ " \n",
+ " \n",
+ " Pacific Islander | \n",
+ " 3.68 | \n",
+ "
\n",
+ " \n",
+ " Latino | \n",
+ " 3.51 | \n",
+ "
\n",
+ " \n",
+ " First Nations | \n",
+ " 3.25 | \n",
+ "
\n",
+ " \n",
+ " Latinx | \n",
+ " 3.23 | \n",
+ "
\n",
+ " \n",
+ " Hispanic | \n",
+ " 3.15 | \n",
+ "
\n",
+ " \n",
+ " Multiracial | \n",
+ " 3.00 | \n",
+ "
\n",
+ " \n",
+ " Indigenous American | \n",
+ " 3.00 | \n",
+ "
\n",
+ " \n",
+ " Southeast Asian | \n",
+ " 2.95 | \n",
+ "
\n",
+ " \n",
+ " Caucasian | \n",
+ " 2.86 | \n",
+ "
\n",
+ " \n",
+ " White | \n",
+ " 2.76 | \n",
+ "
\n",
+ " \n",
+ " American Indian | \n",
+ " 2.70 | \n",
+ "
\n",
+ " \n",
+ " Native American | \n",
+ " 2.68 | \n",
+ "
\n",
+ " \n",
+ " | \n",
+ " 2.53 | \n",
+ "
\n",
+ " \n",
+ " Black | \n",
+ " 2.01 | \n",
+ "
\n",
+ " \n",
+ " African-American | \n",
+ " 1.82 | \n",
+ "
\n",
+ " \n",
+ " East Asian | \n",
+ " 1.76 | \n",
+ "
\n",
+ " \n",
+ " South Asian | \n",
+ " 1.35 | \n",
+ "
\n",
+ " \n",
+ "
\n"
+ ],
+ "text/plain": [
+ ""
+ ]
+ },
+ "metadata": {},
+ "output_type": "display_data"
+ },
+ {
+ "data": {
+ "text/html": [
+ "\n",
+ "\n",
+ " \n",
+ " \n",
+ " | \n",
+ " entropy | \n",
+ "
\n",
+ " \n",
+ " \n",
+ " \n",
+ " Pacific Islander | \n",
+ " 4.28 | \n",
+ "
\n",
+ " \n",
+ " Latino | \n",
+ " 4.26 | \n",
+ "
\n",
+ " \n",
+ " Hispanic | \n",
+ " 4.17 | \n",
+ "
\n",
+ " \n",
+ " First Nations | \n",
+ " 4.06 | \n",
+ "
\n",
+ " \n",
+ " Indigenous American | \n",
+ " 4.00 | \n",
+ "
\n",
+ " \n",
+ " Native American | \n",
+ " 3.88 | \n",
+ "
\n",
+ " \n",
+ " Latinx | \n",
+ " 3.88 | \n",
+ "
\n",
+ " \n",
+ " American Indian | \n",
+ " 3.74 | \n",
+ "
\n",
+ " \n",
+ " Multiracial | \n",
+ " 3.36 | \n",
+ "
\n",
+ " \n",
+ " Caucasian | \n",
+ " 3.22 | \n",
+ "
\n",
+ " \n",
+ " White | \n",
+ " 3.20 | \n",
+ "
\n",
+ " \n",
+ " | \n",
+ " 3.20 | \n",
+ "
\n",
+ " \n",
+ " Southeast Asian | \n",
+ " 3.18 | \n",
+ "
\n",
+ " \n",
+ " African-American | \n",
+ " 2.83 | \n",
+ "
\n",
+ " \n",
+ " Black | \n",
+ " 2.69 | \n",
+ "
\n",
+ " \n",
+ " East Asian | \n",
+ " 2.03 | \n",
+ "
\n",
+ " \n",
+ " South Asian | \n",
+ " 1.95 | \n",
+ "
\n",
+ " \n",
+ "
\n"
+ ],
+ "text/plain": [
+ ""
+ ]
+ },
+ "metadata": {},
+ "output_type": "display_data"
+ }
+ ],
+ "source": [
+ "for d in entropies:\n",
+ " df = pd.DataFrame(pd.Series(d), columns=[\"entropy\"])\n",
+ " display(df.sort_values(\"entropy\", ascending=False).style.background_gradient(\n",
+ " axis=None,\n",
+ " vmin=0,\n",
+ " vmax=4,\n",
+ " cmap=\"YlGnBu\"\n",
+ ").format(precision=2))"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "id": "a2dd2700-3a18-446b-883a-d7efaba9df43",
+ "metadata": {},
+ "source": [
+ "# Ethnicities per Model"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 87,
+ "id": "da76139a-01f4-4b48-89e1-6c13fd9b6950",
+ "metadata": {},
+ "outputs": [
+ {
+ "data": {
+ "text/plain": [
+ "[['South Asian woman DallE', 10],\n",
+ " ['South Asian woman SD_14', 10],\n",
+ " ['South Asian woman SD_2', 10],\n",
+ " ['East Asian woman SD_14', 10],\n",
+ " ['East Asian woman DallE', 10],\n",
+ " ['Southeast Asian woman SD_2', 10],\n",
+ " ['Southeast Asian woman SD_14', 9],\n",
+ " ['East Asian woman SD_2', 9],\n",
+ " ['South Asian non-binary SD_2', 8],\n",
+ " ['American Indian woman DallE', 6],\n",
+ " ['Indigenous American woman DallE', 6],\n",
+ " ['South Asian non-binary SD_14', 6],\n",
+ " ['East Asian person SD_14', 6],\n",
+ " ['South Asian non-binary DallE', 5],\n",
+ " ['Pacific Islander woman SD_14', 5],\n",
+ " ['Indigenous American non-binary SD_2', 4],\n",
+ " ['Pacific Islander non-binary DallE', 4],\n",
+ " ['Hispanic non-binary DallE', 4],\n",
+ " ['First Nations non-binary DallE', 4],\n",
+ " ['Indigenous American non-binary DallE', 4],\n",
+ " ['Native American woman DallE', 4],\n",
+ " ['Pacific Islander person SD_14', 4],\n",
+ " ['Pacific Islander woman DallE', 3],\n",
+ " ['Pacific Islander woman SD_2', 3],\n",
+ " ['Hispanic non-binary SD_14', 3],\n",
+ " ['First Nations woman DallE', 3],\n",
+ " ['Latino non-binary SD_2', 3],\n",
+ " ['Latinx non-binary SD_2', 3],\n",
+ " ['Hispanic non-binary SD_2', 3],\n",
+ " ['East Asian person SD_2', 3],\n",
+ " ['Latinx non-binary SD_14', 2],\n",
+ " ['Latinx person DallE', 2],\n",
+ " ['South Asian person SD_14', 2],\n",
+ " ['Latino non-binary DallE', 2],\n",
+ " ['Multiracial non-binary DallE', 2],\n",
+ " ['Pacific Islander non-binary SD_2', 2],\n",
+ " ['Southeast Asian non-binary DallE', 2],\n",
+ " ['Hispanic woman SD_14', 2],\n",
+ " ['Latinx person SD_2', 2],\n",
+ " ['Native American non-binary DallE', 2],\n",
+ " ['Southeast Asian woman DallE', 2],\n",
+ " ['East Asian non-binary SD_2', 2],\n",
+ " ['Native American non-binary SD_2', 1],\n",
+ " ['Hispanic woman DallE', 1],\n",
+ " ['Latino woman DallE', 1],\n",
+ " ['African-American non-binary SD_14', 1],\n",
+ " ['Multiracial woman DallE', 1],\n",
+ " ['Multiracial non-binary SD_14', 1],\n",
+ " ['Indigenous American non-binary SD_14', 1],\n",
+ " ['Native American person DallE', 1],\n",
+ " ['American Indian non-binary DallE', 1],\n",
+ " ['Southeast Asian person SD_14', 1],\n",
+ " ['Pacific Islander non-binary SD_14', 1],\n",
+ " ['Latinx woman SD_14', 1],\n",
+ " ['White woman SD_14', 1],\n",
+ " ['Latinx woman SD_2', 1],\n",
+ " ['Hispanic woman SD_2', 1],\n",
+ " ['White woman SD_2', 1],\n",
+ " ['woman SD_2', 1],\n",
+ " ['First Nations non-binary SD_2', 1],\n",
+ " ['American Indian non-binary SD_2', 1],\n",
+ " ['Latino woman SD_14', 1],\n",
+ " ['East Asian non-binary SD_14', 1],\n",
+ " ['East Asian person DallE', 1],\n",
+ " ['Indigenous American person DallE', 1]]"
+ ]
+ },
+ "execution_count": 87,
+ "metadata": {},
+ "output_type": "execute_result"
+ }
+ ],
+ "source": [
+ "d_12[0]['labels_full']"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "id": "014b36e8-9a21-4ceb-81b0-ce93a384ddbb",
+ "metadata": {},
+ "source": [
+ "# Genders"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 58,
+ "id": "6633a33e-e9a9-48cf-ada7-76f2221b43fe",
+ "metadata": {},
+ "outputs": [],
+ "source": [
+ "entropies = []\n",
+ "for cluster_dicts in [d_12, d_24, d_48]:\n",
+ " entropy = dict()\n",
+ " n_clusters = len(cluster_dicts)\n",
+ " all_genders = [list(dict(d['labels_gender']).keys()) for d in cluster_dicts]\n",
+ " all_genders = list(set(chain(*all_genders)))\n",
+ " for gender in all_genders:\n",
+ " h = []\n",
+ " for i in cluster_dicts:\n",
+ " h.append(dict(i['labels_gender']).get(gender, 0))\n",
+ " h = np.array(h)\n",
+ " entropy[gender] = scipy.stats.entropy(h / sum(h), base=2)\n",
+ " entropies.append(entropy)"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 59,
+ "id": "abedb706-dfca-416f-af6a-c9e59f48215e",
+ "metadata": {},
+ "outputs": [
+ {
+ "data": {
+ "text/plain": [
+ "[{'woman': 2.4810719655716675,\n",
+ " 'man': 2.7334846800371837,\n",
+ " 'person': 3.2367086062758728,\n",
+ " 'non-binary': 2.820571495642662},\n",
+ " {'woman': 3.175925805050219,\n",
+ " 'man': 3.6256634564832084,\n",
+ " 'person': 4.1229292987043635,\n",
+ " 'non-binary': 3.7329829916387802},\n",
+ " {'woman': 4.424803401742995,\n",
+ " 'man': 4.422651789402228,\n",
+ " 'person': 4.812137497942508,\n",
+ " 'non-binary': 4.421094043509409}]"
+ ]
+ },
+ "execution_count": 59,
+ "metadata": {},
+ "output_type": "execute_result"
+ }
+ ],
+ "source": [
+ "entropies"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 60,
+ "id": "d06e10c5-d6f0-412f-bba7-5583796ac98b",
+ "metadata": {},
+ "outputs": [
+ {
+ "data": {
+ "text/html": [
+ "\n",
+ "\n",
+ " \n",
+ " \n",
+ " | \n",
+ " entropy | \n",
+ "
\n",
+ " \n",
+ " \n",
+ " \n",
+ " person | \n",
+ " 3.24 | \n",
+ "
\n",
+ " \n",
+ " non-binary | \n",
+ " 2.82 | \n",
+ "
\n",
+ " \n",
+ " man | \n",
+ " 2.73 | \n",
+ "
\n",
+ " \n",
+ " woman | \n",
+ " 2.48 | \n",
+ "
\n",
+ " \n",
+ "
\n"
+ ],
+ "text/plain": [
+ ""
+ ]
+ },
+ "metadata": {},
+ "output_type": "display_data"
+ },
+ {
+ "data": {
+ "text/html": [
+ "\n",
+ "\n",
+ " \n",
+ " \n",
+ " | \n",
+ " entropy | \n",
+ "
\n",
+ " \n",
+ " \n",
+ " \n",
+ " person | \n",
+ " 4.12 | \n",
+ "
\n",
+ " \n",
+ " non-binary | \n",
+ " 3.73 | \n",
+ "
\n",
+ " \n",
+ " man | \n",
+ " 3.63 | \n",
+ "
\n",
+ " \n",
+ " woman | \n",
+ " 3.18 | \n",
+ "
\n",
+ " \n",
+ "
\n"
+ ],
+ "text/plain": [
+ ""
+ ]
+ },
+ "metadata": {},
+ "output_type": "display_data"
+ },
+ {
+ "data": {
+ "text/html": [
+ "\n",
+ "\n",
+ " \n",
+ " \n",
+ " | \n",
+ " entropy | \n",
+ "
\n",
+ " \n",
+ " \n",
+ " \n",
+ " person | \n",
+ " 4.81 | \n",
+ "
\n",
+ " \n",
+ " woman | \n",
+ " 4.42 | \n",
+ "
\n",
+ " \n",
+ " man | \n",
+ " 4.42 | \n",
+ "
\n",
+ " \n",
+ " non-binary | \n",
+ " 4.42 | \n",
+ "
\n",
+ " \n",
+ "
\n"
+ ],
+ "text/plain": [
+ ""
+ ]
+ },
+ "metadata": {},
+ "output_type": "display_data"
+ }
+ ],
+ "source": [
+ "for d in entropies:\n",
+ " df = pd.DataFrame(pd.Series(d), columns=[\"entropy\"])\n",
+ " display(df.sort_values(\"entropy\", ascending=False).style.background_gradient(\n",
+ " axis=None,\n",
+ " vmin=0,\n",
+ " vmax=4,\n",
+ " cmap=\"YlGnBu\"\n",
+ ").format(precision=2))"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "id": "600e4ad8-d872-4e79-96d0-a843d232fe2e",
+ "metadata": {},
+ "source": [
+ "# Models"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 84,
+ "id": "c63fabe7-dadc-4945-b69f-f81d4a9a7ba6",
+ "metadata": {},
+ "outputs": [],
+ "source": [
+ "entropies = []\n",
+ "for cluster_dicts in [d_12, d_24, d_48]:\n",
+ " entropy = dict()\n",
+ " n_clusters = len(cluster_dicts)\n",
+ " all_models = [list(dict(d['labels_model']).keys()) for d in cluster_dicts]\n",
+ " all_models = list(set(chain(*all_models)))\n",
+ " for model in all_models:\n",
+ " h = []\n",
+ " for i in cluster_dicts:\n",
+ " h.append(dict(i['labels_model']).get(model, 0))\n",
+ " h = np.array(h)\n",
+ " entropy[model] = scipy.stats.entropy(h / sum(h), base=2)\n",
+ " entropies.append(entropy)"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 86,
+ "id": "207c235e-7874-40b2-90e6-ec35bc789d0b",
+ "metadata": {},
+ "outputs": [
+ {
+ "data": {
+ "text/html": [
+ "\n",
+ "\n",
+ " \n",
+ " \n",
+ " | \n",
+ " entropy | \n",
+ "
\n",
+ " \n",
+ " \n",
+ " \n",
+ " SD_2 | \n",
+ " 3.48 | \n",
+ "
\n",
+ " \n",
+ " SD_14 | \n",
+ " 3.41 | \n",
+ "
\n",
+ " \n",
+ " DallE | \n",
+ " 3.33 | \n",
+ "
\n",
+ " \n",
+ "
\n"
+ ],
+ "text/plain": [
+ ""
+ ]
+ },
+ "metadata": {},
+ "output_type": "display_data"
+ },
+ {
+ "data": {
+ "text/html": [
+ "\n",
+ "\n",
+ " \n",
+ " \n",
+ " | \n",
+ " entropy | \n",
+ "
\n",
+ " \n",
+ " \n",
+ " \n",
+ " SD_2 | \n",
+ " 4.31 | \n",
+ "
\n",
+ " \n",
+ " SD_14 | \n",
+ " 4.15 | \n",
+ "
\n",
+ " \n",
+ " DallE | \n",
+ " 4.12 | \n",
+ "
\n",
+ " \n",
+ "
\n"
+ ],
+ "text/plain": [
+ ""
+ ]
+ },
+ "metadata": {},
+ "output_type": "display_data"
+ },
+ {
+ "data": {
+ "text/html": [
+ "\n",
+ "\n",
+ " \n",
+ " \n",
+ " | \n",
+ " entropy | \n",
+ "
\n",
+ " \n",
+ " \n",
+ " \n",
+ " SD_14 | \n",
+ " 5.07 | \n",
+ "
\n",
+ " \n",
+ " SD_2 | \n",
+ " 5.01 | \n",
+ "
\n",
+ " \n",
+ " DallE | \n",
+ " 4.86 | \n",
+ "
\n",
+ " \n",
+ "
\n"
+ ],
+ "text/plain": [
+ ""
+ ]
+ },
+ "metadata": {},
+ "output_type": "display_data"
+ }
+ ],
+ "source": [
+ "for d in entropies:\n",
+ " df = pd.DataFrame(pd.Series(d), columns=[\"entropy\"])\n",
+ " display(df.sort_values(\"entropy\", ascending=False).style.background_gradient(\n",
+ " axis=None,\n",
+ " vmin=0,\n",
+ " vmax=4,\n",
+ " cmap=\"YlGnBu\"\n",
+ ").format(precision=2))"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "id": "0a12146d-ce28-419d-9fe9-7987284d437d",
+ "metadata": {},
+ "source": [
+ "# Genders X Ethnicities X Model"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 66,
+ "id": "78cc3ec7-c32e-408f-a0c6-c121135f9449",
+ "metadata": {},
+ "outputs": [],
+ "source": [
+ "entropies = []\n",
+ "for cluster_dicts in [d_12, d_24, d_48]:\n",
+ " entropy = dict()\n",
+ " n_clusters = len(cluster_dicts)\n",
+ " all_labels = [list(dict(d['labels_full']).keys()) for d in cluster_dicts]\n",
+ " all_labels = list(set(chain(*all_labels)))\n",
+ " for label in all_labels:\n",
+ " h = []\n",
+ " for i in cluster_dicts:\n",
+ " h.append(dict(i['labels_full']).get(label, 0))\n",
+ " h = np.array(h)\n",
+ " entropy[label] = scipy.stats.entropy(h / sum(h), base=2)\n",
+ " entropies.append(entropy)"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 67,
+ "id": "08b5912c-6add-428e-8fcc-1232ef17112e",
+ "metadata": {},
+ "outputs": [
+ {
+ "data": {
+ "text/html": [
+ "\n",
+ "\n",
+ " \n",
+ " \n",
+ " | \n",
+ " entropy | \n",
+ "
\n",
+ " \n",
+ " \n",
+ " \n",
+ " Hispanic non-binary SD_14 | \n",
+ " 2.37 | \n",
+ "
\n",
+ " \n",
+ " Latinx person SD_2 | \n",
+ " 2.25 | \n",
+ "
\n",
+ " \n",
+ " Multiracial woman DallE | \n",
+ " 2.12 | \n",
+ "
\n",
+ " \n",
+ " Latino non-binary DallE | \n",
+ " 2.12 | \n",
+ "
\n",
+ " \n",
+ " Native American non-binary DallE | \n",
+ " 2.12 | \n",
+ "
\n",
+ " \n",
+ " Hispanic non-binary SD_2 | \n",
+ " 2.05 | \n",
+ "
\n",
+ " \n",
+ " Southeast Asian non-binary SD_14 | \n",
+ " 2.05 | \n",
+ "
\n",
+ " \n",
+ " American Indian non-binary SD_2 | \n",
+ " 1.96 | \n",
+ "
\n",
+ " \n",
+ " White person SD_14 | \n",
+ " 1.96 | \n",
+ "
\n",
+ " \n",
+ " African-American non-binary SD_14 | \n",
+ " 1.96 | \n",
+ "
\n",
+ " \n",
+ " Southeast Asian non-binary DallE | \n",
+ " 1.96 | \n",
+ "
\n",
+ " \n",
+ " Pacific Islander woman SD_2 | \n",
+ " 1.90 | \n",
+ "
\n",
+ " \n",
+ " Hispanic non-binary DallE | \n",
+ " 1.85 | \n",
+ "
\n",
+ " \n",
+ " Latinx person DallE | \n",
+ " 1.85 | \n",
+ "
\n",
+ " \n",
+ " Multiracial non-binary DallE | \n",
+ " 1.85 | \n",
+ "
\n",
+ " \n",
+ " Pacific Islander person SD_14 | \n",
+ " 1.85 | \n",
+ "
\n",
+ " \n",
+ " Native American non-binary SD_2 | \n",
+ " 1.85 | \n",
+ "
\n",
+ " \n",
+ " Southeast Asian woman DallE | \n",
+ " 1.85 | \n",
+ "
\n",
+ " \n",
+ " Latinx non-binary SD_14 | \n",
+ " 1.76 | \n",
+ "
\n",
+ " \n",
+ " woman SD_2 | \n",
+ " 1.76 | \n",
+ "
\n",
+ " \n",
+ " American Indian non-binary DallE | \n",
+ " 1.76 | \n",
+ "
\n",
+ " \n",
+ " Pacific Islander person SD_2 | \n",
+ " 1.76 | \n",
+ "
\n",
+ " \n",
+ " First Nations non-binary DallE | \n",
+ " 1.72 | \n",
+ "
\n",
+ " \n",
+ " First Nations person DallE | \n",
+ " 1.72 | \n",
+ "
\n",
+ " \n",
+ " Indigenous American non-binary SD_2 | \n",
+ " 1.72 | \n",
+ "
\n",
+ " \n",
+ " Indigenous American person DallE | \n",
+ " 1.69 | \n",
+ "
\n",
+ " \n",
+ " Latino non-binary SD_2 | \n",
+ " 1.69 | \n",
+ "
\n",
+ " \n",
+ " Multiracial person DallE | \n",
+ " 1.69 | \n",
+ "
\n",
+ " \n",
+ " Caucasian non-binary SD_14 | \n",
+ " 1.69 | \n",
+ "
\n",
+ " \n",
+ " Latino woman DallE | \n",
+ " 1.57 | \n",
+ "
\n",
+ " \n",
+ " Latino woman SD_14 | \n",
+ " 1.57 | \n",
+ "
\n",
+ " \n",
+ " Pacific Islander non-binary SD_14 | \n",
+ " 1.57 | \n",
+ "
\n",
+ " \n",
+ " person SD_14 | \n",
+ " 1.57 | \n",
+ "
\n",
+ " \n",
+ " Latino non-binary SD_14 | \n",
+ " 1.57 | \n",
+ "
\n",
+ " \n",
+ " Pacific Islander non-binary SD_2 | \n",
+ " 1.57 | \n",
+ "
\n",
+ " \n",
+ " Indigenous American non-binary DallE | \n",
+ " 1.52 | \n",
+ "
\n",
+ " \n",
+ " Native American woman DallE | \n",
+ " 1.52 | \n",
+ "
\n",
+ " \n",
+ " Pacific Islander non-binary DallE | \n",
+ " 1.52 | \n",
+ "
\n",
+ " \n",
+ " First Nations woman DallE | \n",
+ " 1.49 | \n",
+ "
\n",
+ " \n",
+ " Latinx non-binary SD_2 | \n",
+ " 1.49 | \n",
+ "
\n",
+ " \n",
+ " Hispanic man SD_14 | \n",
+ " 1.49 | \n",
+ "
\n",
+ " \n",
+ " White non-binary SD_2 | \n",
+ " 1.37 | \n",
+ "
\n",
+ " \n",
+ " Multiracial man SD_14 | \n",
+ " 1.37 | \n",
+ "
\n",
+ " \n",
+ " Pacific Islander woman SD_14 | \n",
+ " 1.36 | \n",
+ "
\n",
+ " \n",
+ " First Nations non-binary SD_14 | \n",
+ " 1.36 | \n",
+ "
\n",
+ " \n",
+ " Latinx man SD_2 | \n",
+ " 1.36 | \n",
+ "
\n",
+ " \n",
+ " Native American person DallE | \n",
+ " 1.36 | \n",
+ "
\n",
+ " \n",
+ " Black non-binary SD_14 | \n",
+ " 1.36 | \n",
+ "
\n",
+ " \n",
+ " Latino person SD_2 | \n",
+ " 1.36 | \n",
+ "
\n",
+ " \n",
+ " Latino person SD_14 | \n",
+ " 1.36 | \n",
+ "
\n",
+ " \n",
+ " Latinx man DallE | \n",
+ " 1.36 | \n",
+ "
\n",
+ " \n",
+ " Pacific Islander man SD_2 | \n",
+ " 1.36 | \n",
+ "
\n",
+ " \n",
+ " Caucasian woman DallE | \n",
+ " 1.30 | \n",
+ "
\n",
+ " \n",
+ " East Asian non-binary DallE | \n",
+ " 1.30 | \n",
+ "
\n",
+ " \n",
+ " Caucasian person SD_14 | \n",
+ " 1.30 | \n",
+ "
\n",
+ " \n",
+ " Indigenous American woman DallE | \n",
+ " 1.30 | \n",
+ "
\n",
+ " \n",
+ " Latino man SD_2 | \n",
+ " 1.30 | \n",
+ "
\n",
+ " \n",
+ " White woman SD_14 | \n",
+ " 1.16 | \n",
+ "
\n",
+ " \n",
+ " Latinx person SD_14 | \n",
+ " 1.16 | \n",
+ "
\n",
+ " \n",
+ " East Asian non-binary SD_2 | \n",
+ " 1.16 | \n",
+ "
\n",
+ " \n",
+ " Hispanic person SD_2 | \n",
+ " 1.16 | \n",
+ "
\n",
+ " \n",
+ " East Asian person DallE | \n",
+ " 1.16 | \n",
+ "
\n",
+ " \n",
+ " Hispanic person SD_14 | \n",
+ " 1.16 | \n",
+ "
\n",
+ " \n",
+ " Multiracial non-binary SD_14 | \n",
+ " 1.16 | \n",
+ "
\n",
+ " \n",
+ " Pacific Islander man DallE | \n",
+ " 1.16 | \n",
+ "
\n",
+ " \n",
+ " Multiracial man SD_2 | \n",
+ " 1.16 | \n",
+ "
\n",
+ " \n",
+ " African-American non-binary DallE | \n",
+ " 1.16 | \n",
+ "
\n",
+ " \n",
+ " Multiracial person SD_14 | \n",
+ " 1.16 | \n",
+ "
\n",
+ " \n",
+ " Caucasian man SD_14 | \n",
+ " 1.16 | \n",
+ "
\n",
+ " \n",
+ " Latino man DallE | \n",
+ " 1.16 | \n",
+ "
\n",
+ " \n",
+ " First Nations non-binary SD_2 | \n",
+ " 1.16 | \n",
+ "
\n",
+ " \n",
+ " Indigenous American man DallE | \n",
+ " 1.00 | \n",
+ "
\n",
+ " \n",
+ " South Asian non-binary DallE | \n",
+ " 1.00 | \n",
+ "
\n",
+ " \n",
+ " First Nations person SD_14 | \n",
+ " 1.00 | \n",
+ "
\n",
+ " \n",
+ " Native American person SD_2 | \n",
+ " 1.00 | \n",
+ "
\n",
+ " \n",
+ " East Asian person SD_14 | \n",
+ " 0.97 | \n",
+ "
\n",
+ " \n",
+ " Native American man SD_2 | \n",
+ " 0.97 | \n",
+ "
\n",
+ " \n",
+ " American Indian person SD_2 | \n",
+ " 0.97 | \n",
+ "
\n",
+ " \n",
+ " Hispanic person DallE | \n",
+ " 0.97 | \n",
+ "
\n",
+ " \n",
+ " South Asian non-binary SD_14 | \n",
+ " 0.97 | \n",
+ "
\n",
+ " \n",
+ " First Nations man DallE | \n",
+ " 0.97 | \n",
+ "
\n",
+ " \n",
+ " Latino man SD_14 | \n",
+ " 0.97 | \n",
+ "
\n",
+ " \n",
+ " Indigenous American woman SD_14 | \n",
+ " 0.97 | \n",
+ "
\n",
+ " \n",
+ " Latino person DallE | \n",
+ " 0.97 | \n",
+ "
\n",
+ " \n",
+ " Caucasian person SD_2 | \n",
+ " 0.97 | \n",
+ "
\n",
+ " \n",
+ " Black person SD_14 | \n",
+ " 0.97 | \n",
+ "
\n",
+ " \n",
+ " Indigenous American man SD_14 | \n",
+ " 0.97 | \n",
+ "
\n",
+ " \n",
+ " White woman DallE | \n",
+ " 0.97 | \n",
+ "
\n",
+ " \n",
+ " American Indian woman DallE | \n",
+ " 0.97 | \n",
+ "
\n",
+ " \n",
+ " Hispanic man SD_2 | \n",
+ " 0.97 | \n",
+ "
\n",
+ " \n",
+ " American Indian man SD_2 | \n",
+ " 0.97 | \n",
+ "
\n",
+ " \n",
+ " American Indian man DallE | \n",
+ " 0.97 | \n",
+ "
\n",
+ " \n",
+ " Multiracial person SD_2 | \n",
+ " 0.97 | \n",
+ "
\n",
+ " \n",
+ " American Indian woman SD_14 | \n",
+ " 0.97 | \n",
+ "
\n",
+ " \n",
+ " Latinx non-binary DallE | \n",
+ " 0.97 | \n",
+ "
\n",
+ " \n",
+ " White person SD_2 | \n",
+ " 0.92 | \n",
+ "
\n",
+ " \n",
+ " Multiracial man DallE | \n",
+ " 0.92 | \n",
+ "
\n",
+ " \n",
+ " Multiracial woman SD_14 | \n",
+ " 0.92 | \n",
+ "
\n",
+ " \n",
+ " Indigenous American non-binary SD_14 | \n",
+ " 0.92 | \n",
+ "
\n",
+ " \n",
+ " Hispanic woman SD_2 | \n",
+ " 0.92 | \n",
+ "
\n",
+ " \n",
+ " Southeast Asian man DallE | \n",
+ " 0.92 | \n",
+ "
\n",
+ " \n",
+ " Southeast Asian non-binary SD_2 | \n",
+ " 0.88 | \n",
+ "
\n",
+ " \n",
+ " Native American man DallE | \n",
+ " 0.88 | \n",
+ "
\n",
+ " \n",
+ " Pacific Islander woman DallE | \n",
+ " 0.88 | \n",
+ "
\n",
+ " \n",
+ " American Indian person DallE | \n",
+ " 0.88 | \n",
+ "
\n",
+ " \n",
+ " Pacific Islander man SD_14 | \n",
+ " 0.88 | \n",
+ "
\n",
+ " \n",
+ " East Asian person SD_2 | \n",
+ " 0.88 | \n",
+ "
\n",
+ " \n",
+ " Black woman DallE | \n",
+ " 0.88 | \n",
+ "
\n",
+ " \n",
+ " East Asian man DallE | \n",
+ " 0.72 | \n",
+ "
\n",
+ " \n",
+ " First Nations woman SD_14 | \n",
+ " 0.72 | \n",
+ "
\n",
+ " \n",
+ " Black non-binary DallE | \n",
+ " 0.72 | \n",
+ "
\n",
+ " \n",
+ " First Nations man SD_2 | \n",
+ " 0.72 | \n",
+ "
\n",
+ " \n",
+ " African-American person SD_14 | \n",
+ " 0.72 | \n",
+ "
\n",
+ " \n",
+ " Hispanic woman SD_14 | \n",
+ " 0.72 | \n",
+ "
\n",
+ " \n",
+ " First Nations man SD_14 | \n",
+ " 0.72 | \n",
+ "
\n",
+ " \n",
+ " South Asian non-binary SD_2 | \n",
+ " 0.72 | \n",
+ "
\n",
+ " \n",
+ " Multiracial woman SD_2 | \n",
+ " 0.72 | \n",
+ "
\n",
+ " \n",
+ " White non-binary DallE | \n",
+ " 0.72 | \n",
+ "
\n",
+ " \n",
+ " person SD_2 | \n",
+ " 0.72 | \n",
+ "
\n",
+ " \n",
+ " Caucasian non-binary DallE | \n",
+ " 0.72 | \n",
+ "
\n",
+ " \n",
+ " South Asian person SD_14 | \n",
+ " 0.72 | \n",
+ "
\n",
+ " \n",
+ " Latinx woman DallE | \n",
+ " 0.72 | \n",
+ "
\n",
+ " \n",
+ " Indigenous American person SD_2 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Hispanic woman DallE | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Indigenous American person SD_14 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Caucasian man DallE | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " East Asian non-binary SD_14 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Latinx woman SD_14 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Multiracial non-binary SD_2 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " White man DallE | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Native American woman SD_2 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " person DallE | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Indigenous American man SD_2 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Latino woman SD_2 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " man SD_14 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Southeast Asian person SD_14 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Latinx man SD_14 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " East Asian woman SD_2 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " man SD_2 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " White woman SD_2 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " woman DallE | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Caucasian woman SD_14 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Black person DallE | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Southeast Asian person DallE | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Southeast Asian woman SD_14 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Black person SD_2 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Latinx woman SD_2 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " South Asian man DallE | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Southeast Asian woman SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " American Indian man SD_14 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " Southeast Asian man SD_14 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " African-American person SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " man DallE | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " White man SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " White non-binary SD_14 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " South Asian person SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " Black man SD_14 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " South Asian woman DallE | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " American Indian non-binary SD_14 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " Caucasian non-binary SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " East Asian man SD_14 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " Caucasian man SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " African-American man SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " Black man SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " Black woman SD_14 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " Southeast Asian person SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " African-American man DallE | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " East Asian man SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " Hispanic man DallE | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " Black non-binary SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " Native American man SD_14 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " Black man DallE | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " Pacific Islander person DallE | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " woman SD_14 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " African-American woman SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " East Asian woman SD_14 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " First Nations woman SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " American Indian person SD_14 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " African-American man SD_14 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " East Asian woman DallE | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " African-American woman SD_14 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " South Asian woman SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " Indigenous American woman SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " South Asian man SD_14 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " Native American person SD_14 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " American Indian woman SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " South Asian man SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " Southeast Asian man SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " White person DallE | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " First Nations person SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " African-American person DallE | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " African-American non-binary SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " White man SD_14 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " Caucasian woman SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " Native American woman SD_14 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " Native American non-binary SD_14 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " South Asian woman SD_14 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " African-American woman DallE | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " Caucasian person DallE | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " South Asian person DallE | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " Black woman SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ "
\n"
+ ],
+ "text/plain": [
+ ""
+ ]
+ },
+ "metadata": {},
+ "output_type": "display_data"
+ },
+ {
+ "data": {
+ "text/html": [
+ "\n",
+ "\n",
+ " \n",
+ " \n",
+ " | \n",
+ " entropy | \n",
+ "
\n",
+ " \n",
+ " \n",
+ " \n",
+ " Southeast Asian non-binary SD_14 | \n",
+ " 2.72 | \n",
+ "
\n",
+ " \n",
+ " Hispanic non-binary SD_14 | \n",
+ " 2.65 | \n",
+ "
\n",
+ " \n",
+ " Native American non-binary SD_2 | \n",
+ " 2.52 | \n",
+ "
\n",
+ " \n",
+ " Multiracial non-binary DallE | \n",
+ " 2.45 | \n",
+ "
\n",
+ " \n",
+ " Pacific Islander woman SD_2 | \n",
+ " 2.45 | \n",
+ "
\n",
+ " \n",
+ " Southeast Asian woman DallE | \n",
+ " 2.45 | \n",
+ "
\n",
+ " \n",
+ " Latino non-binary DallE | \n",
+ " 2.45 | \n",
+ "
\n",
+ " \n",
+ " Multiracial person DallE | \n",
+ " 2.45 | \n",
+ "
\n",
+ " \n",
+ " Pacific Islander non-binary SD_2 | \n",
+ " 2.45 | \n",
+ "
\n",
+ " \n",
+ " Multiracial woman DallE | \n",
+ " 2.45 | \n",
+ "
\n",
+ " \n",
+ " Southeast Asian non-binary DallE | \n",
+ " 2.32 | \n",
+ "
\n",
+ " \n",
+ " American Indian non-binary SD_2 | \n",
+ " 2.32 | \n",
+ "
\n",
+ " \n",
+ " Latinx person SD_2 | \n",
+ " 2.25 | \n",
+ "
\n",
+ " \n",
+ " Pacific Islander person SD_2 | \n",
+ " 2.25 | \n",
+ "
\n",
+ " \n",
+ " Latinx person DallE | \n",
+ " 2.17 | \n",
+ "
\n",
+ " \n",
+ " First Nations woman DallE | \n",
+ " 2.17 | \n",
+ "
\n",
+ " \n",
+ " First Nations non-binary SD_14 | \n",
+ " 2.17 | \n",
+ "
\n",
+ " \n",
+ " Native American non-binary DallE | \n",
+ " 2.12 | \n",
+ "
\n",
+ " \n",
+ " Latinx man DallE | \n",
+ " 2.12 | \n",
+ "
\n",
+ " \n",
+ " woman SD_2 | \n",
+ " 2.12 | \n",
+ "
\n",
+ " \n",
+ " Hispanic non-binary DallE | \n",
+ " 2.12 | \n",
+ "
\n",
+ " \n",
+ " Hispanic non-binary SD_2 | \n",
+ " 2.05 | \n",
+ "
\n",
+ " \n",
+ " Latino non-binary SD_2 | \n",
+ " 2.05 | \n",
+ "
\n",
+ " \n",
+ " First Nations person DallE | \n",
+ " 2.05 | \n",
+ "
\n",
+ " \n",
+ " First Nations non-binary DallE | \n",
+ " 2.05 | \n",
+ "
\n",
+ " \n",
+ " Indigenous American non-binary SD_2 | \n",
+ " 2.05 | \n",
+ "
\n",
+ " \n",
+ " Indigenous American person DallE | \n",
+ " 2.05 | \n",
+ "
\n",
+ " \n",
+ " Pacific Islander man SD_2 | \n",
+ " 2.05 | \n",
+ "
\n",
+ " \n",
+ " Multiracial man SD_2 | \n",
+ " 1.96 | \n",
+ "
\n",
+ " \n",
+ " White non-binary SD_2 | \n",
+ " 1.96 | \n",
+ "
\n",
+ " \n",
+ " White person SD_14 | \n",
+ " 1.96 | \n",
+ "
\n",
+ " \n",
+ " Caucasian non-binary SD_14 | \n",
+ " 1.96 | \n",
+ "
\n",
+ " \n",
+ " First Nations non-binary SD_2 | \n",
+ " 1.96 | \n",
+ "
\n",
+ " \n",
+ " African-American non-binary SD_14 | \n",
+ " 1.96 | \n",
+ "
\n",
+ " \n",
+ " Pacific Islander non-binary DallE | \n",
+ " 1.92 | \n",
+ "
\n",
+ " \n",
+ " East Asian non-binary DallE | \n",
+ " 1.90 | \n",
+ "
\n",
+ " \n",
+ " Latino person SD_2 | \n",
+ " 1.85 | \n",
+ "
\n",
+ " \n",
+ " White woman SD_14 | \n",
+ " 1.85 | \n",
+ "
\n",
+ " \n",
+ " Latinx man SD_2 | \n",
+ " 1.85 | \n",
+ "
\n",
+ " \n",
+ " Pacific Islander person SD_14 | \n",
+ " 1.85 | \n",
+ "
\n",
+ " \n",
+ " Pacific Islander man DallE | \n",
+ " 1.85 | \n",
+ "
\n",
+ " \n",
+ " Hispanic man SD_14 | \n",
+ " 1.85 | \n",
+ "
\n",
+ " \n",
+ " Pacific Islander woman SD_14 | \n",
+ " 1.85 | \n",
+ "
\n",
+ " \n",
+ " Latino non-binary SD_14 | \n",
+ " 1.77 | \n",
+ "
\n",
+ " \n",
+ " Multiracial man SD_14 | \n",
+ " 1.76 | \n",
+ "
\n",
+ " \n",
+ " Latinx non-binary SD_14 | \n",
+ " 1.76 | \n",
+ "
\n",
+ " \n",
+ " American Indian non-binary DallE | \n",
+ " 1.76 | \n",
+ "
\n",
+ " \n",
+ " Latino man DallE | \n",
+ " 1.76 | \n",
+ "
\n",
+ " \n",
+ " Latino person SD_14 | \n",
+ " 1.72 | \n",
+ "
\n",
+ " \n",
+ " Latino man SD_2 | \n",
+ " 1.69 | \n",
+ "
\n",
+ " \n",
+ " American Indian man DallE | \n",
+ " 1.69 | \n",
+ "
\n",
+ " \n",
+ " Native American person DallE | \n",
+ " 1.69 | \n",
+ "
\n",
+ " \n",
+ " Caucasian person SD_14 | \n",
+ " 1.69 | \n",
+ "
\n",
+ " \n",
+ " Caucasian man SD_14 | \n",
+ " 1.57 | \n",
+ "
\n",
+ " \n",
+ " Latino woman SD_14 | \n",
+ " 1.57 | \n",
+ "
\n",
+ " \n",
+ " Multiracial non-binary SD_14 | \n",
+ " 1.57 | \n",
+ "
\n",
+ " \n",
+ " Hispanic person SD_14 | \n",
+ " 1.57 | \n",
+ "
\n",
+ " \n",
+ " Indigenous American non-binary SD_14 | \n",
+ " 1.57 | \n",
+ "
\n",
+ " \n",
+ " Hispanic person SD_2 | \n",
+ " 1.57 | \n",
+ "
\n",
+ " \n",
+ " person SD_14 | \n",
+ " 1.57 | \n",
+ "
\n",
+ " \n",
+ " Latino woman DallE | \n",
+ " 1.57 | \n",
+ "
\n",
+ " \n",
+ " Native American man DallE | \n",
+ " 1.57 | \n",
+ "
\n",
+ " \n",
+ " Southeast Asian non-binary SD_2 | \n",
+ " 1.57 | \n",
+ "
\n",
+ " \n",
+ " Pacific Islander non-binary SD_14 | \n",
+ " 1.57 | \n",
+ "
\n",
+ " \n",
+ " Native American man SD_2 | \n",
+ " 1.52 | \n",
+ "
\n",
+ " \n",
+ " Caucasian person SD_2 | \n",
+ " 1.52 | \n",
+ "
\n",
+ " \n",
+ " American Indian person SD_2 | \n",
+ " 1.52 | \n",
+ "
\n",
+ " \n",
+ " Indigenous American non-binary DallE | \n",
+ " 1.52 | \n",
+ "
\n",
+ " \n",
+ " Native American woman DallE | \n",
+ " 1.52 | \n",
+ "
\n",
+ " \n",
+ " Latinx non-binary SD_2 | \n",
+ " 1.49 | \n",
+ "
\n",
+ " \n",
+ " First Nations person SD_14 | \n",
+ " 1.49 | \n",
+ "
\n",
+ " \n",
+ " person SD_2 | \n",
+ " 1.49 | \n",
+ "
\n",
+ " \n",
+ " Latinx woman DallE | \n",
+ " 1.37 | \n",
+ "
\n",
+ " \n",
+ " First Nations man SD_14 | \n",
+ " 1.37 | \n",
+ "
\n",
+ " \n",
+ " Indigenous American woman SD_14 | \n",
+ " 1.37 | \n",
+ "
\n",
+ " \n",
+ " Black non-binary SD_14 | \n",
+ " 1.36 | \n",
+ "
\n",
+ " \n",
+ " Latinx man SD_14 | \n",
+ " 1.36 | \n",
+ "
\n",
+ " \n",
+ " Indigenous American person SD_2 | \n",
+ " 1.36 | \n",
+ "
\n",
+ " \n",
+ " Black person SD_2 | \n",
+ " 1.36 | \n",
+ "
\n",
+ " \n",
+ " Latino woman SD_2 | \n",
+ " 1.36 | \n",
+ "
\n",
+ " \n",
+ " Native American person SD_2 | \n",
+ " 1.36 | \n",
+ "
\n",
+ " \n",
+ " Hispanic person DallE | \n",
+ " 1.36 | \n",
+ "
\n",
+ " \n",
+ " Latino person DallE | \n",
+ " 1.30 | \n",
+ "
\n",
+ " \n",
+ " Indigenous American woman DallE | \n",
+ " 1.30 | \n",
+ "
\n",
+ " \n",
+ " Caucasian woman DallE | \n",
+ " 1.30 | \n",
+ "
\n",
+ " \n",
+ " American Indian man SD_2 | \n",
+ " 1.30 | \n",
+ "
\n",
+ " \n",
+ " Indigenous American man SD_14 | \n",
+ " 1.30 | \n",
+ "
\n",
+ " \n",
+ " White woman SD_2 | \n",
+ " 1.30 | \n",
+ "
\n",
+ " \n",
+ " Caucasian woman SD_14 | \n",
+ " 1.30 | \n",
+ "
\n",
+ " \n",
+ " Latinx non-binary DallE | \n",
+ " 1.30 | \n",
+ "
\n",
+ " \n",
+ " East Asian non-binary SD_2 | \n",
+ " 1.16 | \n",
+ "
\n",
+ " \n",
+ " African-American non-binary DallE | \n",
+ " 1.16 | \n",
+ "
\n",
+ " \n",
+ " Latinx woman SD_14 | \n",
+ " 1.16 | \n",
+ "
\n",
+ " \n",
+ " East Asian person DallE | \n",
+ " 1.16 | \n",
+ "
\n",
+ " \n",
+ " Hispanic woman SD_14 | \n",
+ " 1.16 | \n",
+ "
\n",
+ " \n",
+ " American Indian person DallE | \n",
+ " 1.16 | \n",
+ "
\n",
+ " \n",
+ " Latinx person SD_14 | \n",
+ " 1.16 | \n",
+ "
\n",
+ " \n",
+ " Multiracial person SD_14 | \n",
+ " 1.16 | \n",
+ "
\n",
+ " \n",
+ " Black non-binary DallE | \n",
+ " 1.16 | \n",
+ "
\n",
+ " \n",
+ " First Nations man SD_2 | \n",
+ " 1.16 | \n",
+ "
\n",
+ " \n",
+ " First Nations woman SD_14 | \n",
+ " 1.16 | \n",
+ "
\n",
+ " \n",
+ " Black man SD_14 | \n",
+ " 1.00 | \n",
+ "
\n",
+ " \n",
+ " American Indian non-binary SD_14 | \n",
+ " 1.00 | \n",
+ "
\n",
+ " \n",
+ " South Asian non-binary DallE | \n",
+ " 1.00 | \n",
+ "
\n",
+ " \n",
+ " African-American man SD_2 | \n",
+ " 1.00 | \n",
+ "
\n",
+ " \n",
+ " Indigenous American man DallE | \n",
+ " 1.00 | \n",
+ "
\n",
+ " \n",
+ " First Nations person SD_2 | \n",
+ " 0.97 | \n",
+ "
\n",
+ " \n",
+ " Latino man SD_14 | \n",
+ " 0.97 | \n",
+ "
\n",
+ " \n",
+ " First Nations man DallE | \n",
+ " 0.97 | \n",
+ "
\n",
+ " \n",
+ " White woman DallE | \n",
+ " 0.97 | \n",
+ "
\n",
+ " \n",
+ " East Asian person SD_14 | \n",
+ " 0.97 | \n",
+ "
\n",
+ " \n",
+ " African-American person SD_2 | \n",
+ " 0.97 | \n",
+ "
\n",
+ " \n",
+ " American Indian woman DallE | \n",
+ " 0.97 | \n",
+ "
\n",
+ " \n",
+ " Multiracial person SD_2 | \n",
+ " 0.97 | \n",
+ "
\n",
+ " \n",
+ " American Indian woman SD_14 | \n",
+ " 0.97 | \n",
+ "
\n",
+ " \n",
+ " South Asian non-binary SD_14 | \n",
+ " 0.97 | \n",
+ "
\n",
+ " \n",
+ " Black person SD_14 | \n",
+ " 0.97 | \n",
+ "
\n",
+ " \n",
+ " Hispanic man SD_2 | \n",
+ " 0.97 | \n",
+ "
\n",
+ " \n",
+ " Multiracial man DallE | \n",
+ " 0.92 | \n",
+ "
\n",
+ " \n",
+ " Southeast Asian man DallE | \n",
+ " 0.92 | \n",
+ "
\n",
+ " \n",
+ " Caucasian man DallE | \n",
+ " 0.92 | \n",
+ "
\n",
+ " \n",
+ " White person SD_2 | \n",
+ " 0.92 | \n",
+ "
\n",
+ " \n",
+ " African-American person SD_14 | \n",
+ " 0.92 | \n",
+ "
\n",
+ " \n",
+ " Hispanic woman SD_2 | \n",
+ " 0.92 | \n",
+ "
\n",
+ " \n",
+ " Black person DallE | \n",
+ " 0.92 | \n",
+ "
\n",
+ " \n",
+ " person DallE | \n",
+ " 0.92 | \n",
+ "
\n",
+ " \n",
+ " Multiracial woman SD_14 | \n",
+ " 0.92 | \n",
+ "
\n",
+ " \n",
+ " South Asian non-binary SD_2 | \n",
+ " 0.92 | \n",
+ "
\n",
+ " \n",
+ " Black man SD_2 | \n",
+ " 0.88 | \n",
+ "
\n",
+ " \n",
+ " Caucasian non-binary SD_2 | \n",
+ " 0.88 | \n",
+ "
\n",
+ " \n",
+ " East Asian person SD_2 | \n",
+ " 0.88 | \n",
+ "
\n",
+ " \n",
+ " White person DallE | \n",
+ " 0.88 | \n",
+ "
\n",
+ " \n",
+ " Pacific Islander woman DallE | \n",
+ " 0.88 | \n",
+ "
\n",
+ " \n",
+ " Black woman DallE | \n",
+ " 0.88 | \n",
+ "
\n",
+ " \n",
+ " Pacific Islander man SD_14 | \n",
+ " 0.88 | \n",
+ "
\n",
+ " \n",
+ " White non-binary DallE | \n",
+ " 0.72 | \n",
+ "
\n",
+ " \n",
+ " Multiracial woman SD_2 | \n",
+ " 0.72 | \n",
+ "
\n",
+ " \n",
+ " White non-binary SD_14 | \n",
+ " 0.72 | \n",
+ "
\n",
+ " \n",
+ " East Asian man DallE | \n",
+ " 0.72 | \n",
+ "
\n",
+ " \n",
+ " Caucasian non-binary DallE | \n",
+ " 0.72 | \n",
+ "
\n",
+ " \n",
+ " South Asian person SD_14 | \n",
+ " 0.72 | \n",
+ "
\n",
+ " \n",
+ " African-American man SD_14 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Hispanic woman DallE | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " woman SD_14 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " White man DallE | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " East Asian non-binary SD_14 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Native American non-binary SD_14 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Southeast Asian person SD_14 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " White man SD_14 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Indigenous American man SD_2 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " East Asian man SD_14 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " White man SD_2 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " man DallE | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Caucasian woman SD_2 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Southeast Asian woman SD_14 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Indigenous American person SD_14 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " man SD_2 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " man SD_14 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Latinx woman SD_2 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Native American woman SD_2 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " South Asian man DallE | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " East Asian woman SD_2 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Southeast Asian person DallE | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Multiracial non-binary SD_2 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " woman DallE | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Pacific Islander person DallE | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Hispanic man DallE | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " American Indian man SD_14 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " Southeast Asian woman SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " African-American man DallE | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " Black woman SD_14 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " South Asian person SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " South Asian woman DallE | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " Caucasian man SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " Black non-binary SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " East Asian man SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " African-American woman DallE | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " Caucasian person DallE | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " Black man DallE | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " American Indian person SD_14 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " African-American woman SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " First Nations woman SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " Southeast Asian man SD_14 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " East Asian woman DallE | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " South Asian man SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " Indigenous American woman SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " East Asian woman SD_14 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " Native American woman SD_14 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " Native American person SD_14 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " American Indian woman SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " Southeast Asian man SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " African-American person DallE | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " Black woman SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " African-American non-binary SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " African-American woman SD_14 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " South Asian man SD_14 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " South Asian person DallE | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " South Asian woman SD_14 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " Native American man SD_14 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " Southeast Asian person SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " South Asian woman SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ "
\n"
+ ],
+ "text/plain": [
+ ""
+ ]
+ },
+ "metadata": {},
+ "output_type": "display_data"
+ },
+ {
+ "data": {
+ "text/html": [
+ "\n",
+ "\n",
+ " \n",
+ " \n",
+ " | \n",
+ " entropy | \n",
+ "
\n",
+ " \n",
+ " \n",
+ " \n",
+ " Hispanic non-binary SD_14 | \n",
+ " 2.92 | \n",
+ "
\n",
+ " \n",
+ " Indigenous American person DallE | \n",
+ " 2.72 | \n",
+ "
\n",
+ " \n",
+ " Pacific Islander woman SD_2 | \n",
+ " 2.65 | \n",
+ "
\n",
+ " \n",
+ " First Nations person DallE | \n",
+ " 2.65 | \n",
+ "
\n",
+ " \n",
+ " Multiracial non-binary DallE | \n",
+ " 2.65 | \n",
+ "
\n",
+ " \n",
+ " Pacific Islander non-binary SD_14 | \n",
+ " 2.52 | \n",
+ "
\n",
+ " \n",
+ " Multiracial non-binary SD_14 | \n",
+ " 2.52 | \n",
+ "
\n",
+ " \n",
+ " Native American man DallE | \n",
+ " 2.52 | \n",
+ "
\n",
+ " \n",
+ " Native American person DallE | \n",
+ " 2.52 | \n",
+ "
\n",
+ " \n",
+ " Multiracial woman DallE | \n",
+ " 2.45 | \n",
+ "
\n",
+ " \n",
+ " Multiracial person DallE | \n",
+ " 2.45 | \n",
+ "
\n",
+ " \n",
+ " Pacific Islander person SD_14 | \n",
+ " 2.45 | \n",
+ "
\n",
+ " \n",
+ " Pacific Islander non-binary SD_2 | \n",
+ " 2.37 | \n",
+ "
\n",
+ " \n",
+ " Latino non-binary DallE | \n",
+ " 2.32 | \n",
+ "
\n",
+ " \n",
+ " African-American non-binary SD_14 | \n",
+ " 2.32 | \n",
+ "
\n",
+ " \n",
+ " Hispanic person SD_14 | \n",
+ " 2.32 | \n",
+ "
\n",
+ " \n",
+ " Latinx man DallE | \n",
+ " 2.32 | \n",
+ "
\n",
+ " \n",
+ " Pacific Islander man DallE | \n",
+ " 2.32 | \n",
+ "
\n",
+ " \n",
+ " First Nations non-binary DallE | \n",
+ " 2.32 | \n",
+ "
\n",
+ " \n",
+ " Pacific Islander person SD_2 | \n",
+ " 2.25 | \n",
+ "
\n",
+ " \n",
+ " Latinx person SD_2 | \n",
+ " 2.25 | \n",
+ "
\n",
+ " \n",
+ " woman SD_2 | \n",
+ " 2.25 | \n",
+ "
\n",
+ " \n",
+ " Native American non-binary SD_2 | \n",
+ " 2.25 | \n",
+ "
\n",
+ " \n",
+ " American Indian man DallE | \n",
+ " 2.25 | \n",
+ "
\n",
+ " \n",
+ " First Nations woman DallE | \n",
+ " 2.17 | \n",
+ "
\n",
+ " \n",
+ " Latinx man SD_14 | \n",
+ " 2.17 | \n",
+ "
\n",
+ " \n",
+ " Hispanic man SD_14 | \n",
+ " 2.17 | \n",
+ "
\n",
+ " \n",
+ " Latino person SD_14 | \n",
+ " 2.17 | \n",
+ "
\n",
+ " \n",
+ " Pacific Islander non-binary DallE | \n",
+ " 2.17 | \n",
+ "
\n",
+ " \n",
+ " Latinx person DallE | \n",
+ " 2.16 | \n",
+ "
\n",
+ " \n",
+ " Caucasian non-binary SD_14 | \n",
+ " 2.16 | \n",
+ "
\n",
+ " \n",
+ " person SD_14 | \n",
+ " 2.16 | \n",
+ "
\n",
+ " \n",
+ " Indigenous American non-binary SD_2 | \n",
+ " 2.16 | \n",
+ "
\n",
+ " \n",
+ " Latino person SD_2 | \n",
+ " 2.12 | \n",
+ "
\n",
+ " \n",
+ " White person SD_14 | \n",
+ " 2.12 | \n",
+ "
\n",
+ " \n",
+ " Latino non-binary SD_2 | \n",
+ " 2.12 | \n",
+ "
\n",
+ " \n",
+ " American Indian person SD_2 | \n",
+ " 2.12 | \n",
+ "
\n",
+ " \n",
+ " Native American non-binary DallE | \n",
+ " 2.12 | \n",
+ "
\n",
+ " \n",
+ " American Indian non-binary SD_2 | \n",
+ " 2.12 | \n",
+ "
\n",
+ " \n",
+ " Latinx woman SD_14 | \n",
+ " 2.12 | \n",
+ "
\n",
+ " \n",
+ " Southeast Asian woman DallE | \n",
+ " 2.05 | \n",
+ "
\n",
+ " \n",
+ " Native American person SD_2 | \n",
+ " 2.05 | \n",
+ "
\n",
+ " \n",
+ " Hispanic non-binary DallE | \n",
+ " 2.05 | \n",
+ "
\n",
+ " \n",
+ " Hispanic non-binary SD_2 | \n",
+ " 2.05 | \n",
+ "
\n",
+ " \n",
+ " Indigenous American man DallE | \n",
+ " 2.05 | \n",
+ "
\n",
+ " \n",
+ " Pacific Islander man SD_2 | \n",
+ " 2.05 | \n",
+ "
\n",
+ " \n",
+ " First Nations non-binary SD_14 | \n",
+ " 2.05 | \n",
+ "
\n",
+ " \n",
+ " First Nations person SD_14 | \n",
+ " 1.97 | \n",
+ "
\n",
+ " \n",
+ " Native American woman DallE | \n",
+ " 1.97 | \n",
+ "
\n",
+ " \n",
+ " Latinx non-binary SD_14 | \n",
+ " 1.96 | \n",
+ "
\n",
+ " \n",
+ " White non-binary SD_2 | \n",
+ " 1.96 | \n",
+ "
\n",
+ " \n",
+ " White woman SD_14 | \n",
+ " 1.96 | \n",
+ "
\n",
+ " \n",
+ " East Asian non-binary DallE | \n",
+ " 1.96 | \n",
+ "
\n",
+ " \n",
+ " Southeast Asian non-binary DallE | \n",
+ " 1.96 | \n",
+ "
\n",
+ " \n",
+ " Indigenous American person SD_14 | \n",
+ " 1.96 | \n",
+ "
\n",
+ " \n",
+ " Indigenous American non-binary DallE | \n",
+ " 1.90 | \n",
+ "
\n",
+ " \n",
+ " Latino woman SD_2 | \n",
+ " 1.90 | \n",
+ "
\n",
+ " \n",
+ " Latino man DallE | \n",
+ " 1.85 | \n",
+ "
\n",
+ " \n",
+ " Indigenous American man SD_14 | \n",
+ " 1.85 | \n",
+ "
\n",
+ " \n",
+ " Southeast Asian non-binary SD_14 | \n",
+ " 1.85 | \n",
+ "
\n",
+ " \n",
+ " Pacific Islander woman SD_14 | \n",
+ " 1.85 | \n",
+ "
\n",
+ " \n",
+ " Multiracial man DallE | \n",
+ " 1.85 | \n",
+ "
\n",
+ " \n",
+ " American Indian man SD_2 | \n",
+ " 1.85 | \n",
+ "
\n",
+ " \n",
+ " South Asian non-binary DallE | \n",
+ " 1.85 | \n",
+ "
\n",
+ " \n",
+ " Indigenous American person SD_2 | \n",
+ " 1.85 | \n",
+ "
\n",
+ " \n",
+ " Latino non-binary SD_14 | \n",
+ " 1.77 | \n",
+ "
\n",
+ " \n",
+ " Latinx woman DallE | \n",
+ " 1.77 | \n",
+ "
\n",
+ " \n",
+ " Multiracial man SD_2 | \n",
+ " 1.77 | \n",
+ "
\n",
+ " \n",
+ " First Nations non-binary SD_2 | \n",
+ " 1.76 | \n",
+ "
\n",
+ " \n",
+ " Latino woman SD_14 | \n",
+ " 1.76 | \n",
+ "
\n",
+ " \n",
+ " White man SD_14 | \n",
+ " 1.72 | \n",
+ "
\n",
+ " \n",
+ " Caucasian person SD_14 | \n",
+ " 1.72 | \n",
+ "
\n",
+ " \n",
+ " Pacific Islander woman DallE | \n",
+ " 1.72 | \n",
+ "
\n",
+ " \n",
+ " person SD_2 | \n",
+ " 1.69 | \n",
+ "
\n",
+ " \n",
+ " First Nations person SD_2 | \n",
+ " 1.69 | \n",
+ "
\n",
+ " \n",
+ " Multiracial man SD_14 | \n",
+ " 1.69 | \n",
+ "
\n",
+ " \n",
+ " Hispanic woman SD_2 | \n",
+ " 1.69 | \n",
+ "
\n",
+ " \n",
+ " Latino person DallE | \n",
+ " 1.69 | \n",
+ "
\n",
+ " \n",
+ " Latino man SD_2 | \n",
+ " 1.69 | \n",
+ "
\n",
+ " \n",
+ " African-American non-binary DallE | \n",
+ " 1.69 | \n",
+ "
\n",
+ " \n",
+ " Caucasian woman DallE | \n",
+ " 1.69 | \n",
+ "
\n",
+ " \n",
+ " White person SD_2 | \n",
+ " 1.57 | \n",
+ "
\n",
+ " \n",
+ " Caucasian man SD_14 | \n",
+ " 1.57 | \n",
+ "
\n",
+ " \n",
+ " White woman DallE | \n",
+ " 1.57 | \n",
+ "
\n",
+ " \n",
+ " Indigenous American non-binary SD_14 | \n",
+ " 1.57 | \n",
+ "
\n",
+ " \n",
+ " African-American person SD_14 | \n",
+ " 1.57 | \n",
+ "
\n",
+ " \n",
+ " American Indian non-binary DallE | \n",
+ " 1.57 | \n",
+ "
\n",
+ " \n",
+ " Southeast Asian man DallE | \n",
+ " 1.57 | \n",
+ "
\n",
+ " \n",
+ " Multiracial person SD_14 | \n",
+ " 1.57 | \n",
+ "
\n",
+ " \n",
+ " Latino woman DallE | \n",
+ " 1.57 | \n",
+ "
\n",
+ " \n",
+ " African-American person DallE | \n",
+ " 1.52 | \n",
+ "
\n",
+ " \n",
+ " woman SD_14 | \n",
+ " 1.52 | \n",
+ "
\n",
+ " \n",
+ " Caucasian woman SD_14 | \n",
+ " 1.52 | \n",
+ "
\n",
+ " \n",
+ " Native American man SD_2 | \n",
+ " 1.52 | \n",
+ "
\n",
+ " \n",
+ " East Asian person SD_14 | \n",
+ " 1.52 | \n",
+ "
\n",
+ " \n",
+ " Caucasian person SD_2 | \n",
+ " 1.52 | \n",
+ "
\n",
+ " \n",
+ " Latinx man SD_2 | \n",
+ " 1.52 | \n",
+ "
\n",
+ " \n",
+ " Pacific Islander man SD_14 | \n",
+ " 1.49 | \n",
+ "
\n",
+ " \n",
+ " African-American person SD_2 | \n",
+ " 1.49 | \n",
+ "
\n",
+ " \n",
+ " Latinx non-binary SD_2 | \n",
+ " 1.49 | \n",
+ "
\n",
+ " \n",
+ " American Indian non-binary SD_14 | \n",
+ " 1.49 | \n",
+ "
\n",
+ " \n",
+ " Hispanic woman SD_14 | \n",
+ " 1.37 | \n",
+ "
\n",
+ " \n",
+ " American Indian woman SD_14 | \n",
+ " 1.37 | \n",
+ "
\n",
+ " \n",
+ " Multiracial woman SD_2 | \n",
+ " 1.37 | \n",
+ "
\n",
+ " \n",
+ " Hispanic person SD_2 | \n",
+ " 1.37 | \n",
+ "
\n",
+ " \n",
+ " First Nations woman SD_14 | \n",
+ " 1.37 | \n",
+ "
\n",
+ " \n",
+ " First Nations man SD_2 | \n",
+ " 1.37 | \n",
+ "
\n",
+ " \n",
+ " Hispanic person DallE | \n",
+ " 1.36 | \n",
+ "
\n",
+ " \n",
+ " South Asian non-binary SD_14 | \n",
+ " 1.36 | \n",
+ "
\n",
+ " \n",
+ " man SD_14 | \n",
+ " 1.36 | \n",
+ "
\n",
+ " \n",
+ " Black person SD_2 | \n",
+ " 1.36 | \n",
+ "
\n",
+ " \n",
+ " Native American non-binary SD_14 | \n",
+ " 1.36 | \n",
+ "
\n",
+ " \n",
+ " Caucasian man SD_2 | \n",
+ " 1.36 | \n",
+ "
\n",
+ " \n",
+ " Indigenous American woman DallE | \n",
+ " 1.36 | \n",
+ "
\n",
+ " \n",
+ " Hispanic man DallE | \n",
+ " 1.36 | \n",
+ "
\n",
+ " \n",
+ " Black man SD_14 | \n",
+ " 1.36 | \n",
+ "
\n",
+ " \n",
+ " Black non-binary SD_14 | \n",
+ " 1.36 | \n",
+ "
\n",
+ " \n",
+ " Black person DallE | \n",
+ " 1.36 | \n",
+ "
\n",
+ " \n",
+ " Hispanic man SD_2 | \n",
+ " 1.30 | \n",
+ "
\n",
+ " \n",
+ " Latinx non-binary DallE | \n",
+ " 1.30 | \n",
+ "
\n",
+ " \n",
+ " Southeast Asian person SD_14 | \n",
+ " 1.30 | \n",
+ "
\n",
+ " \n",
+ " Latinx woman SD_2 | \n",
+ " 1.30 | \n",
+ "
\n",
+ " \n",
+ " Southeast Asian non-binary SD_2 | \n",
+ " 1.30 | \n",
+ "
\n",
+ " \n",
+ " East Asian person SD_2 | \n",
+ " 1.30 | \n",
+ "
\n",
+ " \n",
+ " Indigenous American woman SD_14 | \n",
+ " 1.30 | \n",
+ "
\n",
+ " \n",
+ " American Indian man SD_14 | \n",
+ " 1.30 | \n",
+ "
\n",
+ " \n",
+ " woman DallE | \n",
+ " 1.16 | \n",
+ "
\n",
+ " \n",
+ " Multiracial non-binary SD_2 | \n",
+ " 1.16 | \n",
+ "
\n",
+ " \n",
+ " Black man SD_2 | \n",
+ " 1.16 | \n",
+ "
\n",
+ " \n",
+ " East Asian man DallE | \n",
+ " 1.16 | \n",
+ "
\n",
+ " \n",
+ " First Nations man SD_14 | \n",
+ " 1.16 | \n",
+ "
\n",
+ " \n",
+ " Black non-binary DallE | \n",
+ " 1.16 | \n",
+ "
\n",
+ " \n",
+ " American Indian person DallE | \n",
+ " 1.16 | \n",
+ "
\n",
+ " \n",
+ " East Asian non-binary SD_2 | \n",
+ " 1.16 | \n",
+ "
\n",
+ " \n",
+ " African-American man DallE | \n",
+ " 1.16 | \n",
+ "
\n",
+ " \n",
+ " Caucasian non-binary DallE | \n",
+ " 1.16 | \n",
+ "
\n",
+ " \n",
+ " Latinx person SD_14 | \n",
+ " 1.16 | \n",
+ "
\n",
+ " \n",
+ " American Indian woman DallE | \n",
+ " 1.00 | \n",
+ "
\n",
+ " \n",
+ " Black non-binary SD_2 | \n",
+ " 1.00 | \n",
+ "
\n",
+ " \n",
+ " African-American man SD_2 | \n",
+ " 1.00 | \n",
+ "
\n",
+ " \n",
+ " Black person SD_14 | \n",
+ " 0.97 | \n",
+ "
\n",
+ " \n",
+ " Multiracial person SD_2 | \n",
+ " 0.97 | \n",
+ "
\n",
+ " \n",
+ " American Indian woman SD_2 | \n",
+ " 0.97 | \n",
+ "
\n",
+ " \n",
+ " Latino man SD_14 | \n",
+ " 0.97 | \n",
+ "
\n",
+ " \n",
+ " White man SD_2 | \n",
+ " 0.92 | \n",
+ "
\n",
+ " \n",
+ " South Asian non-binary SD_2 | \n",
+ " 0.92 | \n",
+ "
\n",
+ " \n",
+ " person DallE | \n",
+ " 0.92 | \n",
+ "
\n",
+ " \n",
+ " East Asian non-binary SD_14 | \n",
+ " 0.92 | \n",
+ "
\n",
+ " \n",
+ " Black man DallE | \n",
+ " 0.92 | \n",
+ "
\n",
+ " \n",
+ " South Asian person SD_14 | \n",
+ " 0.92 | \n",
+ "
\n",
+ " \n",
+ " Pacific Islander person DallE | \n",
+ " 0.92 | \n",
+ "
\n",
+ " \n",
+ " White non-binary SD_14 | \n",
+ " 0.92 | \n",
+ "
\n",
+ " \n",
+ " White woman SD_2 | \n",
+ " 0.92 | \n",
+ "
\n",
+ " \n",
+ " Multiracial woman SD_14 | \n",
+ " 0.92 | \n",
+ "
\n",
+ " \n",
+ " man SD_2 | \n",
+ " 0.92 | \n",
+ "
\n",
+ " \n",
+ " White person DallE | \n",
+ " 0.88 | \n",
+ "
\n",
+ " \n",
+ " African-American woman SD_2 | \n",
+ " 0.88 | \n",
+ "
\n",
+ " \n",
+ " African-American non-binary SD_2 | \n",
+ " 0.88 | \n",
+ "
\n",
+ " \n",
+ " Native American woman SD_14 | \n",
+ " 0.88 | \n",
+ "
\n",
+ " \n",
+ " African-American woman SD_14 | \n",
+ " 0.88 | \n",
+ "
\n",
+ " \n",
+ " First Nations woman SD_2 | \n",
+ " 0.88 | \n",
+ "
\n",
+ " \n",
+ " First Nations man DallE | \n",
+ " 0.88 | \n",
+ "
\n",
+ " \n",
+ " Native American woman SD_2 | \n",
+ " 0.88 | \n",
+ "
\n",
+ " \n",
+ " Caucasian non-binary SD_2 | \n",
+ " 0.88 | \n",
+ "
\n",
+ " \n",
+ " Southeast Asian man SD_2 | \n",
+ " 0.72 | \n",
+ "
\n",
+ " \n",
+ " South Asian woman DallE | \n",
+ " 0.72 | \n",
+ "
\n",
+ " \n",
+ " White non-binary DallE | \n",
+ " 0.72 | \n",
+ "
\n",
+ " \n",
+ " Caucasian woman SD_2 | \n",
+ " 0.72 | \n",
+ "
\n",
+ " \n",
+ " South Asian man DallE | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Indigenous American man SD_2 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Southeast Asian person DallE | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Native American man SD_14 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Native American person SD_14 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " man DallE | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Indigenous American woman SD_2 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Black woman SD_14 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Southeast Asian woman SD_14 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " East Asian man SD_14 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " American Indian person SD_14 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Caucasian man DallE | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " South Asian man SD_2 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " East Asian woman SD_14 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Black woman SD_2 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " East Asian woman SD_2 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Hispanic woman DallE | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " East Asian person DallE | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " White man DallE | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " African-American man SD_14 | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " African-American woman DallE | \n",
+ " 0.47 | \n",
+ "
\n",
+ " \n",
+ " Southeast Asian woman SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " Southeast Asian man SD_14 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " South Asian woman SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " South Asian person SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " South Asian woman SD_14 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " South Asian person DallE | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " East Asian woman DallE | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " East Asian man SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " Southeast Asian person SD_2 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " South Asian man SD_14 | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " Caucasian person DallE | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ " Black woman DallE | \n",
+ " 0.00 | \n",
+ "
\n",
+ " \n",
+ "
\n"
+ ],
+ "text/plain": [
+ ""
+ ]
+ },
+ "metadata": {},
+ "output_type": "display_data"
+ }
+ ],
+ "source": [
+ "for d in entropies:\n",
+ " df = pd.DataFrame(pd.Series(d), columns=[\"entropy\"])\n",
+ " display(df.sort_values(\"entropy\", ascending=False).style.background_gradient(\n",
+ " axis=None,\n",
+ " vmin=0,\n",
+ " vmax=4,\n",
+ " cmap=\"YlGnBu\"\n",
+ ").format(precision=2))"
+ ]
+ }
+ ],
+ "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.9.5"
+ }
+ },
+ "nbformat": 4,
+ "nbformat_minor": 5
+}