Skip to content

Commit 7662f9e

Browse files
committed
Switch link to bivariate Gaussian widget
1 parent 1db488f commit 7662f9e

File tree

1 file changed

+17
-17
lines changed

1 file changed

+17
-17
lines changed

13-multidim-dependence/joint-rvs.ipynb

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -400,8 +400,8 @@
400400
"fig.colorbar(surf, shrink=0.3, aspect=5, pad=0.1)\n",
401401
"\n",
402402
"ax.view_init(35, azim = -80)\n",
403-
"ax.set_xlabel('$x$');\n",
404-
"ax.set_ylabel('$y$');\n",
403+
"ax.set_xlabel('x');\n",
404+
"ax.set_ylabel('y');\n",
405405
"\n",
406406
"ax=axs['B']\n",
407407
"# #G = stats.multivariate_normal(mean=[0,0],cov=K1)\n",
@@ -410,8 +410,8 @@
410410
"ax.contour(X,Y,N.pdf(pos), extent=[-3,3,-3,3],cmap=cm.coolwarm);\n",
411411
"ax.set_ylim(-4,4)\n",
412412
"ax.set_xlim(-4,4);\n",
413-
"ax.set_xlabel('$x$');\n",
414-
"ax.set_ylabel('$y$');\n",
413+
"ax.set_xlabel('x');\n",
414+
"ax.set_ylabel('y');\n",
415415
"# ax.spines['bottom'].set_position('zero')\n",
416416
"# ax.spines['left'].set_position('zero')\n",
417417
"plt.subplots_adjust(wspace=0.7)"
@@ -438,15 +438,15 @@
438438
" <iframe\n",
439439
" width=\"800\"\n",
440440
" height=\"1600\"\n",
441-
" src=\"https://jmshea.github.io/Foundations-of-Data-Science-with-Python/bivariate-gaussian.html\"\n",
441+
" src=\"https://fdsp.net/bivariate-gaussian.html\"\n",
442442
" frameborder=\"0\"\n",
443443
" allowfullscreen\n",
444444
" \n",
445445
" ></iframe>\n",
446446
" "
447447
],
448448
"text/plain": [
449-
"<IPython.lib.display.IFrame at 0x324d2ca50>"
449+
"<IPython.lib.display.IFrame at 0x32407e050>"
450450
]
451451
},
452452
"execution_count": 13,
@@ -457,8 +457,8 @@
457457
"source": [
458458
"# Display the associated webpage in a new window\n",
459459
"import IPython\n",
460-
"#url = 'https://fdsp.net/bivariate-gaussian.html'\n",
461-
"url = 'https://jmshea.github.io/Foundations-of-Data-Science-with-Python/bivariate-gaussian.html'\n",
460+
"url = 'https://fdsp.net/bivariate-gaussian.html'\n",
461+
"#url = 'https://jmshea.github.io/Foundations-of-Data-Science-with-Python/bivariate-gaussian.html'\n",
462462
"iframe = '<iframe src=' + url + ' width=800 height=1500></iframe>'\n",
463463
"#IPython.display.HTML(iframe)\n",
464464
"IPython.display.IFrame(url, 800, 1600)"
@@ -480,7 +480,7 @@
480480
},
481481
{
482482
"cell_type": "code",
483-
"execution_count": 18,
483+
"execution_count": 15,
484484
"id": "da3da055-392d-4067-9014-d530317f5465",
485485
"metadata": {
486486
"tags": [
@@ -765,7 +765,7 @@
765765
{
766766
"data": {
767767
"text/html": [
768-
"<div style=\"height:40px\"></div><div class=\"flip-container\" id=\"RDnTdaJDEbTg\" tabindex=\"0\" style=\"outline:none;\"></div><div style=\"height:40px\"></div><div class=\"next\" id=\"RDnTdaJDEbTg-next\" onclick=\"window.checkFlip('RDnTdaJDEbTg')\"> </div> <div style=\"height:40px\"></div>"
768+
"<div style=\"height:40px\"></div><div class=\"flip-container\" id=\"YolwiyyCJRrM\" tabindex=\"0\" style=\"outline:none;\"></div><div style=\"height:40px\"></div><div class=\"next\" id=\"YolwiyyCJRrM-next\" onclick=\"window.checkFlip('YolwiyyCJRrM')\"> </div> <div style=\"height:40px\"></div>"
769769
],
770770
"text/plain": [
771771
"<IPython.core.display.HTML object>"
@@ -1251,14 +1251,14 @@
12511251
"\n",
12521252
"\n",
12531253
" function try_create() {\n",
1254-
" if(document.getElementById(\"RDnTdaJDEbTg\")) {\n",
1255-
" createCards(\"RDnTdaJDEbTg\", \"True\", \"False\", \"False\", \"\", \"\");\n",
1254+
" if(document.getElementById(\"YolwiyyCJRrM\")) {\n",
1255+
" createCards(\"YolwiyyCJRrM\", \"True\", \"False\", \"False\", \"\", \"\");\n",
12561256
" } else {\n",
12571257
" setTimeout(try_create, 200);\n",
12581258
" }\n",
12591259
" };\n",
12601260
" \n",
1261-
"var cardsRDnTdaJDEbTg=[\n",
1261+
"var cardsYolwiyyCJRrM=[\n",
12621262
" {\n",
12631263
" \"front\": \"joint probability mass function<br>(pair of random variables)\",\n",
12641264
" \"back\": \"For a pair of random variables $(X,Y)$, the joint <i>probability mass function</i> (PMF) defines the probability that $(X,Y)$ takes on each value $(x,y) \\\\in \\\\mathbb{R}^2$, \\\\begin{align*} P_{X,Y} (x,y) &= P\\\\left[ \\\\left\\\\{ s \\\\left| X(s) = x, Y(s) =y \\\\right. \\\\right\\\\} \\\\right] \\\\\\\\ &= P \\\\left[ X=x, Y=y \\\\right]. \\\\end{align*}\"\n",
@@ -1309,9 +1309,9 @@
13091309
"}\n",
13101310
"]\n",
13111311
";\n",
1312-
"var frontColorsRDnTdaJDEbTg= [\"var(--asparagus)\", \"var(--terra-cotta)\", \"var(--cyan-process)\" ];\n",
1313-
"var backColorsRDnTdaJDEbTg= [\"var(--dark-blue-gray)\" ];\n",
1314-
"var textColorsRDnTdaJDEbTg= [\"var(--snow)\" ];\n",
1312+
"var frontColorsYolwiyyCJRrM= [\"var(--asparagus)\", \"var(--terra-cotta)\", \"var(--cyan-process)\" ];\n",
1313+
"var backColorsYolwiyyCJRrM= [\"var(--dark-blue-gray)\" ];\n",
1314+
"var textColorsYolwiyyCJRrM= [\"var(--snow)\" ];\n",
13151315
"\n",
13161316
"\n",
13171317
" {\n",
@@ -1322,7 +1322,7 @@
13221322
"\n",
13231323
" fetch(\"https://raw.githubusercontent.com/jmshea/Foundations-of-Data-Science-with-Python/main/13-multidim-dependence/flashcards/joint-rvs.json\", {signal})\n",
13241324
" .then(response => response.json())\n",
1325-
" .then(json => createCards(\"RDnTdaJDEbTg\", \"True\", \"False\", \"False\", \"\", \"\"))\n",
1325+
" .then(json => createCards(\"YolwiyyCJRrM\", \"True\", \"False\", \"False\", \"\", \"\"))\n",
13261326
" .catch(err => {\n",
13271327
" console.log(\"Fetch error or timeout\");\n",
13281328
" try_create(); \n",

0 commit comments

Comments
 (0)