Skip to content

Commit 7a7cbea

Browse files
committed
more snippits
1 parent 546a3bc commit 7a7cbea

25 files changed

+1214
-682
lines changed

Untitled0.ipynb

+2-77
Original file line numberDiff line numberDiff line change
@@ -1,84 +1,9 @@
11
{
22
"metadata": {
33
"name": "",
4-
"signature": "sha256:cde834b4630abeb021db1dc03e98b143f55b68177957a95a558f61eb79bf28a7"
4+
"signature": "sha256:24d12ab64e5e93c82e0acf22e043d94d7006b033acc4160a5a99e702b6873929"
55
},
66
"nbformat": 3,
77
"nbformat_minor": 0,
8-
"worksheets": [
9-
{
10-
"cells": [
11-
{
12-
"cell_type": "code",
13-
"collapsed": false,
14-
"input": [
15-
"import pandas as pd\n",
16-
"\n",
17-
"raw_data = {'name': ['Miller', 'Jacobson', 'Ali', 'Milner', 'Cooze', 'Jacon', 'Ryaner', 'Sone', 'Sloan', 'Piger', 'Riani', 'Ali'], \n",
18-
" 'score': [25, 94, 57, 62, 70, 25, 94, 57, 62, 70, 62, 70]}\n",
19-
"df = pd.DataFrame(raw_data, columns = ['name', 'score'])\n",
20-
"\n",
21-
"bins = [0, 25, 50, 75, 100]\n",
22-
"group_names = ['Low', 'Okay', 'Good', 'Great']\n",
23-
"\n",
24-
"cat_obj = pd.cut(df['score'], bins, labels=group_names)\n",
25-
"df['cat'] = pd.cut(df['score'], bins, labels=group_names)"
26-
],
27-
"language": "python",
28-
"metadata": {},
29-
"outputs": [],
30-
"prompt_number": 4
31-
},
32-
{
33-
"cell_type": "code",
34-
"collapsed": false,
35-
"input": [
36-
"type(cat_obj)"
37-
],
38-
"language": "python",
39-
"metadata": {},
40-
"outputs": [
41-
{
42-
"metadata": {},
43-
"output_type": "pyout",
44-
"prompt_number": 7,
45-
"text": [
46-
"pandas.core.categorical.Categorical"
47-
]
48-
}
49-
],
50-
"prompt_number": 7
51-
},
52-
{
53-
"cell_type": "code",
54-
"collapsed": false,
55-
"input": [
56-
"type(df['cat'])"
57-
],
58-
"language": "python",
59-
"metadata": {},
60-
"outputs": [
61-
{
62-
"metadata": {},
63-
"output_type": "pyout",
64-
"prompt_number": 8,
65-
"text": [
66-
"pandas.core.series.Series"
67-
]
68-
}
69-
],
70-
"prompt_number": 8
71-
},
72-
{
73-
"cell_type": "code",
74-
"collapsed": false,
75-
"input": [],
76-
"language": "python",
77-
"metadata": {},
78-
"outputs": []
79-
}
80-
],
81-
"metadata": {}
82-
}
83-
]
8+
"worksheets": []
849
}

Untitled1.ipynb

-192
This file was deleted.

Untitled2.ipynb

-107
This file was deleted.

0 commit comments

Comments
 (0)