Ejercicios

parent 00646378
...@@ -1220,7 +1220,7 @@ ...@@ -1220,7 +1220,7 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 7, "execution_count": 8,
"metadata": {}, "metadata": {},
"outputs": [ "outputs": [
{ {
...@@ -1269,8 +1269,9 @@ ...@@ -1269,8 +1269,9 @@
"plt.xticks(roulette_bet)\n", "plt.xticks(roulette_bet)\n",
"for i,j in zip(roulette_bet, np.array(roulette_prob)*100):\n", "for i,j in zip(roulette_bet, np.array(roulette_prob)*100):\n",
" plt.annotate(str(round(j,2))+'%', xy=(i,j+0.5) )\n", " plt.annotate(str(round(j,2))+'%', xy=(i,j+0.5) )\n",
"\n",
"plt.show()\n", "plt.show()\n",
"\n",
"plt.rcParams['figure.figsize']=[15, 5]\n",
"plt.subplot(1, 2, 1)\n", "plt.subplot(1, 2, 1)\n",
"plt.plot(roulette_num, custom_rand_var.pmf(roulette_num), 'go', ms=7, mec='g')\n", "plt.plot(roulette_num, custom_rand_var.pmf(roulette_num), 'go', ms=7, mec='g')\n",
"plt.vlines(roulette_num, 0, custom_rand_var.pmf(roulette_num), colors='g', lw=4)\n", "plt.vlines(roulette_num, 0, custom_rand_var.pmf(roulette_num), colors='g', lw=4)\n",
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment