Skip to content

Commit

Permalink
lec 2 more 1D hist
Browse files Browse the repository at this point in the history
  • Loading branch information
shenvitor committed Nov 17, 2023
1 parent f41e863 commit 5479975
Showing 1 changed file with 48 additions and 0 deletions.
48 changes: 48 additions & 0 deletions docs/lecture02.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -2271,6 +2271,30 @@
"plt.show()"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
"fig, (ax1, ax2, ax3) = plt.subplots(figsize=(12, 4), ncols=3)\n",
"fig.suptitle(\"1D histogram of $s_{12}, s_{23}$, and $s_{31}$\")\n",
"ax1.hist(s12, bins=100)\n",
"ax1.set_xlabel(R\"$s_{12}$\")\n",
"ax1.set_ylabel(\"counts\")\n",
"\n",
"ax2.hist(s23, bins=100)\n",
"ax2.set_xlabel(R\"$s_{23}$\")\n",
"ax2.set_ylabel(\"counts\")\n",
"\n",
"ax3.hist(s31, bins=100)\n",
"ax3.set_xlabel(R\"$s_{31}$\")\n",
"ax3.set_ylabel(\"counts\")\n",
"\n",
"fig.tight_layout()\n",
"plt.show()"
]
},
{
"cell_type": "markdown",
"metadata": {},
Expand Down Expand Up @@ -2556,6 +2580,30 @@
"fig.tight_layout()\n",
"plt.show()"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
"fig, (ax1, ax2, ax3) = plt.subplots(figsize=(12, 4), ncols=3)\n",
"fig.suptitle(\"1D histogram of $s_{12}, s_{23}$, and $s_{31}$\")\n",
"ax1.hist(s12, bins=100)\n",
"ax1.set_xlabel(R\"$s_{12}$\")\n",
"ax1.set_ylabel(\"counts\")\n",
"\n",
"ax2.hist(s23, bins=100)\n",
"ax2.set_xlabel(R\"$s_{23}$\")\n",
"ax2.set_ylabel(\"counts\")\n",
"\n",
"ax3.hist(s31, bins=100)\n",
"ax3.set_xlabel(R\"$s_{31}$\")\n",
"ax3.set_ylabel(\"counts\")\n",
"\n",
"fig.tight_layout()\n",
"plt.show()"
]
}
],
"metadata": {
Expand Down

0 comments on commit 5479975

Please sign in to comment.