Skip to content

Commit 22e44b0

Browse files
authored
Add files via upload
1 parent e5d5c0f commit 22e44b0

16 files changed

+12301
-0
lines changed

Basics of python.ipynb

+1,284
Large diffs are not rendered by default.

Data Structure Overview.ipynb

+103
Large diffs are not rendered by default.

Dictionary methods .ipynb

+404
Large diffs are not rendered by default.

Getting Started with Python.ipynb

+404
Large diffs are not rendered by default.

Mean Median & Mode.ipynb

+393
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,393 @@
1+
{
2+
"cells": [
3+
{
4+
"cell_type": "markdown",
5+
"id": "cd8aeb1d",
6+
"metadata": {},
7+
"source": [
8+
"________________________________________________________________________________________________________________________\n",
9+
"\n",
10+
"\n",
11+
"* Yuvraj Sutar \n",
12+
13+
"_ _________________________________________________________________________________________________________________________\n",
14+
"_ _________________________________________________________________________________________________________________________\n"
15+
]
16+
},
17+
{
18+
"cell_type": "code",
19+
"execution_count": 1,
20+
"id": "04ba84a1",
21+
"metadata": {},
22+
"outputs": [],
23+
"source": [
24+
"import pandas as pd\n",
25+
"import matplotlib.pyplot as plt\n",
26+
"import seaborn as sns\n",
27+
"from scipy import stats\n"
28+
]
29+
},
30+
{
31+
"cell_type": "code",
32+
"execution_count": 2,
33+
"id": "0738972a",
34+
"metadata": {},
35+
"outputs": [],
36+
"source": [
37+
"#Data \n",
38+
"a=[20,21,23,22,23,20,21,23,24,23,23,22,21,800,1]"
39+
]
40+
},
41+
{
42+
"cell_type": "code",
43+
"execution_count": 3,
44+
"id": "5830bf37",
45+
"metadata": {},
46+
"outputs": [
47+
{
48+
"name": "stdout",
49+
"output_type": "stream",
50+
"text": [
51+
"Q1: 21.0\n"
52+
]
53+
}
54+
],
55+
"source": [
56+
"#percentile...\n",
57+
"\n",
58+
"import numpy as np \n",
59+
"Q1 = np.percentile(a,22)\n",
60+
"print('Q1:',Q1)"
61+
]
62+
},
63+
{
64+
"cell_type": "code",
65+
"execution_count": 4,
66+
"id": "29371334",
67+
"metadata": {},
68+
"outputs": [
69+
{
70+
"name": "stdout",
71+
"output_type": "stream",
72+
"text": [
73+
"72.46666666666667\n"
74+
]
75+
}
76+
],
77+
"source": [
78+
"#mean.....\n",
79+
"\n",
80+
"import numpy\n",
81+
"x = numpy.mean(a)\n",
82+
"print(x)"
83+
]
84+
},
85+
{
86+
"cell_type": "code",
87+
"execution_count": 5,
88+
"id": "1344f0bd",
89+
"metadata": {},
90+
"outputs": [
91+
{
92+
"name": "stdout",
93+
"output_type": "stream",
94+
"text": [
95+
"ModeResult(mode=array([23]), count=array([5]))\n"
96+
]
97+
}
98+
],
99+
"source": [
100+
"#Mode.....\n",
101+
"\n",
102+
"x = stats.mode(a)\n",
103+
"print(x)"
104+
]
105+
},
106+
{
107+
"cell_type": "code",
108+
"execution_count": 6,
109+
"id": "81dcecc8",
110+
"metadata": {},
111+
"outputs": [
112+
{
113+
"name": "stdout",
114+
"output_type": "stream",
115+
"text": [
116+
"Q1: 22.0\n"
117+
]
118+
}
119+
],
120+
"source": [
121+
"#Median.....\n",
122+
"\n",
123+
"Q1 = np.median(a) \n",
124+
"print('Q1:',Q1)\n"
125+
]
126+
},
127+
{
128+
"cell_type": "code",
129+
"execution_count": 7,
130+
"id": "9e6ca76b",
131+
"metadata": {},
132+
"outputs": [
133+
{
134+
"name": "stdout",
135+
"output_type": "stream",
136+
"text": [
137+
"minimum 1\n"
138+
]
139+
}
140+
],
141+
"source": [
142+
"#minimum....\n",
143+
"\n",
144+
"m2=np.min(a)\n",
145+
"print(\"minimum \",m2)"
146+
]
147+
},
148+
{
149+
"cell_type": "code",
150+
"execution_count": 8,
151+
"id": "038bdbb6",
152+
"metadata": {},
153+
"outputs": [
154+
{
155+
"name": "stdout",
156+
"output_type": "stream",
157+
"text": [
158+
"maximum 800\n"
159+
]
160+
}
161+
],
162+
"source": [
163+
"#maximum....\n",
164+
"\n",
165+
"m1=np.max(a)\n",
166+
"print(\"maximum \",m1)"
167+
]
168+
},
169+
{
170+
"cell_type": "code",
171+
"execution_count": 9,
172+
"id": "e8896058",
173+
"metadata": {},
174+
"outputs": [
175+
{
176+
"name": "stdout",
177+
"output_type": "stream",
178+
"text": [
179+
"37836.11555555555\n"
180+
]
181+
}
182+
],
183+
"source": [
184+
"#variance...\n",
185+
"\n",
186+
"x = numpy.var(a)\n",
187+
"print(x)"
188+
]
189+
},
190+
{
191+
"cell_type": "code",
192+
"execution_count": 10,
193+
"id": "702e9526",
194+
"metadata": {},
195+
"outputs": [
196+
{
197+
"name": "stdout",
198+
"output_type": "stream",
199+
"text": [
200+
"799\n"
201+
]
202+
}
203+
],
204+
"source": [
205+
"#range...\n",
206+
"\n",
207+
"x = numpy.ptp(a)\n",
208+
"print(x)"
209+
]
210+
},
211+
{
212+
"cell_type": "code",
213+
"execution_count": 11,
214+
"id": "99f88cbc",
215+
"metadata": {},
216+
"outputs": [
217+
{
218+
"name": "stdout",
219+
"output_type": "stream",
220+
"text": [
221+
"[ 1. 21. 22. 23. 800.]\n"
222+
]
223+
}
224+
],
225+
"source": [
226+
"#quantile...\n",
227+
"\n",
228+
"import numpy\n",
229+
"x = numpy.quantile(a, [0,0.25,0.5,0.75,1])\n",
230+
"print(x)"
231+
]
232+
},
233+
{
234+
"cell_type": "code",
235+
"execution_count": 12,
236+
"id": "5778ca0c",
237+
"metadata": {},
238+
"outputs": [
239+
{
240+
"name": "stdout",
241+
"output_type": "stream",
242+
"text": [
243+
"2.0\n"
244+
]
245+
}
246+
],
247+
"source": [
248+
"#interquartile range...\n",
249+
"\n",
250+
"from scipy import stats\n",
251+
"a = [20,21,23,22,23,20,21,23,24,23,23,22,21,800,1]\n",
252+
"x = stats.iqr(a)\n",
253+
"print(x)"
254+
]
255+
},
256+
{
257+
"cell_type": "code",
258+
"execution_count": 13,
259+
"id": "7d271475",
260+
"metadata": {},
261+
"outputs": [
262+
{
263+
"name": "stdout",
264+
"output_type": "stream",
265+
"text": [
266+
"194.51507796455152\n"
267+
]
268+
}
269+
],
270+
"source": [
271+
"#Standard Deviation...\n",
272+
"\n",
273+
"import numpy\n",
274+
"a = [20,21,23,22,23,20,21,23,24,23,23,22,21,800,1]\n",
275+
"x = numpy.std(a)\n",
276+
"print(x)"
277+
]
278+
},
279+
{
280+
"cell_type": "markdown",
281+
"id": "486b0e0d",
282+
"metadata": {},
283+
"source": [
284+
".............................................................................................................................................................................................................................................................."
285+
]
286+
},
287+
{
288+
"cell_type": "code",
289+
"execution_count": 15,
290+
"id": "3fcedaa0",
291+
"metadata": {},
292+
"outputs": [],
293+
"source": [
294+
"#Data \n",
295+
"b=[20,21,23,22,23,20,21,23,24,23,23,22,21,1]"
296+
]
297+
},
298+
{
299+
"cell_type": "code",
300+
"execution_count": 16,
301+
"id": "f5bda976",
302+
"metadata": {},
303+
"outputs": [
304+
{
305+
"name": "stdout",
306+
"output_type": "stream",
307+
"text": [
308+
"20.5\n"
309+
]
310+
}
311+
],
312+
"source": [
313+
"#mean.....\n",
314+
"\n",
315+
"import numpy\n",
316+
"x = numpy.mean(b)\n",
317+
"print(x)"
318+
]
319+
},
320+
{
321+
"cell_type": "code",
322+
"execution_count": 17,
323+
"id": "9a1cecc1",
324+
"metadata": {},
325+
"outputs": [
326+
{
327+
"name": "stdout",
328+
"output_type": "stream",
329+
"text": [
330+
"ModeResult(mode=array([23]), count=array([5]))\n"
331+
]
332+
}
333+
],
334+
"source": [
335+
"#Mode.....\n",
336+
"\n",
337+
"x = stats.mode(b)\n",
338+
"print(x)"
339+
]
340+
},
341+
{
342+
"cell_type": "code",
343+
"execution_count": 18,
344+
"id": "a3c2fab0",
345+
"metadata": {},
346+
"outputs": [
347+
{
348+
"name": "stdout",
349+
"output_type": "stream",
350+
"text": [
351+
"Q1: 22.0\n"
352+
]
353+
}
354+
],
355+
"source": [
356+
"#Median.....\n",
357+
"\n",
358+
"Q1 = np.median(b) \n",
359+
"print('Q1:',Q1)"
360+
]
361+
},
362+
{
363+
"cell_type": "markdown",
364+
"id": "e72d5b5c",
365+
"metadata": {},
366+
"source": [
367+
"* Yuvraj Sutar \n",
368+
369+
]
370+
}
371+
],
372+
"metadata": {
373+
"kernelspec": {
374+
"display_name": "Python 3 (ipykernel)",
375+
"language": "python",
376+
"name": "python3"
377+
},
378+
"language_info": {
379+
"codemirror_mode": {
380+
"name": "ipython",
381+
"version": 3
382+
},
383+
"file_extension": ".py",
384+
"mimetype": "text/x-python",
385+
"name": "python",
386+
"nbconvert_exporter": "python",
387+
"pygments_lexer": "ipython3",
388+
"version": "3.9.7"
389+
}
390+
},
391+
"nbformat": 4,
392+
"nbformat_minor": 5
393+
}

0 commit comments

Comments
 (0)