Skip to content

Problemas estadistica descriptiva_hs #13

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
75 changes: 69 additions & 6 deletions notebook/problems.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -30,12 +30,61 @@
},
{
"cell_type": "code",
"execution_count": 1,
"execution_count": 5,
"id": "34720ab6",
"metadata": {},
"outputs": [],
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"El vector normal: [ 0.49671415 -0.1382643 0.64768854 1.52302986 -0.23415337 -0.23413696\n",
" 1.57921282 0.76743473 -0.46947439 0.54256004 -0.46341769 -0.46572975\n",
" 0.24196227 -1.91328024 -1.72491783 -0.56228753 -1.01283112 0.31424733\n",
" -0.90802408 -1.4123037 1.46564877 -0.2257763 0.0675282 -1.42474819\n",
" -0.54438272 0.11092259 -1.15099358 0.37569802 -0.60063869 -0.29169375\n",
" -0.60170661 1.85227818 -0.01349722 -1.05771093 0.82254491 -1.22084365\n",
" 0.2088636 -1.95967012 -1.32818605 0.19686124 0.73846658 0.17136828\n",
" -0.11564828 -0.3011037 -1.47852199 -0.71984421 -0.46063877 1.05712223\n",
" 0.34361829 -1.76304016 0.32408397 -0.38508228 -0.676922 0.61167629\n",
" 1.03099952 0.93128012 -0.83921752 -0.30921238 0.33126343 0.97554513\n",
" -0.47917424 -0.18565898 -1.10633497 -1.19620662 0.81252582 1.35624003\n",
" -0.07201012 1.0035329 0.36163603 -0.64511975 0.36139561 1.53803657\n",
" -0.03582604 1.56464366 -2.6197451 0.8219025 0.08704707 -0.29900735\n",
" 0.09176078 -1.98756891 -0.21967189 0.35711257 1.47789404 -0.51827022\n",
" -0.8084936 -0.50175704 0.91540212 0.32875111 -0.5297602 0.51326743\n",
" 0.09707755 0.96864499 -0.70205309 -0.32766215 -0.39210815 -1.46351495\n",
" 0.29612028 0.26105527 0.00511346 -0.23458713]\n",
"El vector chi cuadrado: [ 0.4168513 1.53749288 2.0019707 3.31954478 2.93509884 2.17617828\n",
" 0.15830407 2.27652419 2.46587889 12.72456265 1.94196651 3.04725102\n",
" 5.77516859 4.36378602 6.86491387 0.42618426 0.78098785 1.3113313\n",
" 0.33084683 2.48460231 0.85740894 7.53845363 1.01734997 1.7044591\n",
" 4.56886089 0.55649438 0.29858042 2.75534614 2.9409741 4.4625349\n",
" 3.65222252 3.03548985 1.15103525 2.87187902 3.02542952 1.10535719\n",
" 9.13003056 3.51390358 0.79761542 4.48007115 5.09450961 3.3434575\n",
" 1.84236463 1.05445618 2.17070629 3.15061854 2.36153348 7.09243827\n",
" 3.96269904 0.92828493 0.70025868 3.53848141 1.8831237 4.24057767\n",
" 3.51221427 2.17951444 0.94044813 0.35233451 2.82705909 0.54422803\n",
" 0.89743356 2.68142092 2.4613509 0.63275656 5.54211583 5.43039306\n",
" 3.63214678 3.62852305 3.63218282 5.06050325 4.04232775 1.03035801\n",
" 1.85822454 11.7557897 0.17754328 1.45511551 5.56483363 1.10410752\n",
" 4.1308596 2.43317078 1.18979801 2.75974204 1.00588199 2.09414701\n",
" 3.60307013 4.7477682 1.450369 1.18741582 0.531925 4.9308192\n",
" 10.57550712 5.34984734 6.2796709 1.11415225 3.42940531 4.43865013\n",
" 0.74626305 0.13247338 0.50086102 2.0667793 ]\n"
]
}
],
"source": [
"# TODO"
"import numpy as np\n",
"\n",
"np.random.seed(42)\n",
"\n",
"normal = np.random.normal(size = 100)\n",
"chi = np.random.chisquare(3, 100)\n",
"\n",
"print(f\"El vector normal:\", normal)\n",
"print(f\"El vector chi cuadrado:\", chi)"
]
},
{
Expand All @@ -54,12 +103,26 @@
},
{
"cell_type": "code",
"execution_count": 2,
"execution_count": 7,
"id": "d590308e",
"metadata": {},
"outputs": [],
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"Desviación estándar: 2.0\n"
]
}
],
"source": [
"# TODO"
"data = [4, 2, 5, 8, 6]\n",
"\n",
"# Calcular la desviación estándar\n",
"\n",
"std_deviation = np.std(data)\n",
"\n",
"print(\"Desviación estándar:\", std_deviation)"
]
}
],
Expand Down