Skip to content

Commit 3be6b1e

Browse files
committed
Update Lambda and Readme
1 parent 8301cbb commit 3be6b1e

File tree

2 files changed

+75
-10
lines changed

2 files changed

+75
-10
lines changed

1_Basics/17_Lambda.ipynb

Lines changed: 71 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -156,6 +156,76 @@
156156
"total_salary_list"
157157
]
158158
},
159+
{
160+
"cell_type": "markdown",
161+
"metadata": {},
162+
"source": [
163+
"Rewriting this to show that the salary variables are different"
164+
]
165+
},
166+
{
167+
"cell_type": "code",
168+
"execution_count": 3,
169+
"metadata": {},
170+
"outputs": [
171+
{
172+
"data": {
173+
"text/plain": [
174+
"[110000.00000000001,\n",
175+
" 220000.00000000003,\n",
176+
" 165000.0,\n",
177+
" 132000.0,\n",
178+
" 88000.0,\n",
179+
" 825000.0000000001]"
180+
]
181+
},
182+
"execution_count": 3,
183+
"metadata": {},
184+
"output_type": "execute_result"
185+
}
186+
],
187+
"source": [
188+
"total_salary_list = [(lambda salary: salary * (1.1))(item) for item in salary_list]\n",
189+
"\n",
190+
"total_salary_list"
191+
]
192+
},
193+
{
194+
"cell_type": "markdown",
195+
"metadata": {},
196+
"source": [
197+
"**NOTE: This example was for demonstration purposes for using lambda** \n",
198+
"\n",
199+
"Technically, you could just do this:"
200+
]
201+
},
202+
{
203+
"cell_type": "code",
204+
"execution_count": 4,
205+
"metadata": {},
206+
"outputs": [
207+
{
208+
"data": {
209+
"text/plain": [
210+
"[110000.00000000001,\n",
211+
" 220000.00000000003,\n",
212+
" 165000.0,\n",
213+
" 132000.0,\n",
214+
" 88000.0,\n",
215+
" 825000.0000000001]"
216+
]
217+
},
218+
"execution_count": 4,
219+
"metadata": {},
220+
"output_type": "execute_result"
221+
}
222+
],
223+
"source": [
224+
"total_salary_list = [item * 1.1 for item in salary_list]\n",
225+
"\n",
226+
"total_salary_list"
227+
]
228+
},
159229
{
160230
"cell_type": "markdown",
161231
"metadata": {},
@@ -327,7 +397,7 @@
327397
"name": "python",
328398
"nbconvert_exporter": "python",
329399
"pygments_lexer": "ipython3",
330-
"version": "3.9.19"
400+
"version": "3.11.9"
331401
}
332402
},
333403
"nbformat": 4,

README.md

Lines changed: 4 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,15 @@
11
# Python for Data Analytics - Full Course
22

3-
Data Nerds! This repo contains all the notebooks and code for my free course.
3+
Data Nerds! This repo contains all the notebooks needed to follow along my free course: [Python for Data Analytics]()
44

55
[![Python for Data Analytics](3_Project/images/Python_Data_Analytics_YT.png)](https://youtu.be/7mz73uXD9DA?si=kXWYSyaWdNKBAOyc)
6+
*Thanks to [Kelly Adams](https://www.linkedin.com/in/kellyjianadams) for help with producing this course*
67

78
## Table of Contents
89

910
### [Chapter 1: Python Basics](/1_Basics/)
1011

11-
*This chapter is meant to be executed on [Google Colab](https://colab.research.google.com/github/lukebarousse/Python_Data_Analytics_Course/blob/main/1_Basics/01_Getting_Started.ipynb).*
12+
*This chapter is meant for [Google Colab](https://colab.research.google.com/github/lukebarousse/Python_Data_Analytics_Course/blob/main/1_Basics/01_Getting_Started.ipynb).*
1213
- Introduction to Python
1314
- Variables
1415
- Data Types
@@ -26,8 +27,6 @@ Data Nerds! This repo contains all the notebooks and code for my free course.
2627

2728
### [Chapter 2: Advanced Python](/2_Advanced/)
2829

29-
*This chapter is meant to be executed locally on VS Code.*
30-
3130
- Advanced Pandas
3231
- Data Cleaning
3332
- Data Manipulation
@@ -39,21 +38,17 @@ Data Nerds! This repo contains all the notebooks and code for my free course.
3938

4039
### [Chapter 3: Project Build](/3_Project/)
4140

42-
*This chapter is meant to be executed locally on VS Code.*
43-
4441
- Investigating Top Skills in Data Science
4542
- Data Cleaning
4643
- Data Analysis
4744
- Data Visualization
4845
- Data Interpretation
4946

5047
## Found a Typo? Want to Contribute?
51-
- If you find a typo or error in the code, please feel free to make a pull request by:
48+
- If you find an error in this codebase, please feel free to make a pull request by:
5249
- Forking the repo
5350
- Making any changes
5451
- Submitting a pull request
5552

56-
5753
## TODO:
5854
- [ ] Update Link to Video
59-
- [ ] Fix [github issue](https://stackoverflow.com/questions/78501731/error-nbformat-when-uploading-to-github-from-google-colab/78503623#78503623)

0 commit comments

Comments
 (0)