You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -53,13 +53,14 @@ Our only objective for this lecture is to give you some feel of what Python is,
53
53
54
54
Python is free and open source, with development coordinated through the [Python Software Foundation](https://www.python.org/psf/).
55
55
56
-
Python has experienced rapid adoption in the last decade and is now one of the [most popular programming languages](https://pythoncircle.com/post/763/the-rising-popularity-of-python/).
56
+
Python has experienced rapid adoption in the last decade and is now one of the [most popular programming languages](https://www.tiobe.com/tiobe-index/).
57
57
58
58
### Common Uses
59
59
60
60
{index}`Python <single: Python; common uses>` is a general-purpose language used in almost all application domains such as
61
61
62
-
* communications
62
+
* AI
63
+
* communication
63
64
* web development
64
65
* CGI and graphical user interfaces
65
66
* game development
@@ -75,16 +76,14 @@ Used and supported extensively by Internet services and high-tech companies incl
75
76
*[Amazon](https://www.amazon.com/)
76
77
*[Reddit](https://www.reddit.com/)
77
78
78
-
For reasons we will discuss, Python is particularly popular within the scientific community and behind many scientific achievements in
For reasons we will discuss, Python is particularly popular within the scientific community
82
80
83
-
and practically all branches of academia.
81
+
Meanwhile, Python is also very beginner-friendly and is found to be suitable for
82
+
students learning programming and recommended to introduce computational methods
83
+
to students in fields other than computer science.
84
84
85
-
Meanwhile, Python is also very beginner-friendly and is found to be suitable for students learning programming and recommended to introduce computational methods to students in [fields other than computer science](https://www.sciencedirect.com/science/article/pii/S1477388021000177).
85
+
Python is also replacing familiar tools like Excel as an essential skill in the fields of finance and banking.
86
86
87
-
Python is also [replacing familiar tools like Excel as an essential skill](https://www.efinancialcareers.com.au/news/2021/08/python-for-banking-jobs) in the fields of finance and banking.
88
87
89
88
### Relative Popularity
90
89
@@ -95,23 +94,8 @@ The following chart, produced using Stack Overflow Trends, shows one measure of
95
94
96
95
The figure indicates not only that Python is widely used but also that adoption of Python has accelerated significantly since 2012.
97
96
98
-
We suspect this is driven at least in part by uptake in the scientific
99
-
domain, particularly in rapidly growing fields like data science.
97
+
This is driven at least in part by uptake in the scientific domain, particularly in rapidly growing fields like data science and AI.
100
98
101
-
For example, the popularity of [pandas](http://pandas.pydata.org/), a library for data analysis with Python has exploded, as seen here.
102
-
103
-
(The corresponding time path for MATLAB is shown for comparison)
Note that pandas takes off in 2012, which is the same year that we see
109
-
Python's popularity begin to spike in the first figure.
110
-
111
-
Overall, it's clear that
112
-
113
-
* Python is [one of the most popular programming languages worldwide](https://spectrum.ieee.org/top-programming-languages-2021).
114
-
* Python is a major tool for scientific computing, accounting for a rapidly rising share of scientific work around the globe.
115
99
116
100
### Features
117
101
@@ -133,14 +117,13 @@ One nice feature of Python is its elegant syntax --- we'll see many examples lat
133
117
134
118
Elegant code might sound superfluous but in fact it's highly beneficial because it makes the syntax easy to read and easy to remember.
135
119
136
-
Remembering how to read from files, sort dictionaries and other such routine tasks means that you don't need to break your flow in order to hunt down correct syntax.
137
-
138
120
Closely related to elegant syntax is an elegant design.
139
121
140
122
Features like iterators, generators, decorators and list comprehensions make Python highly expressive, allowing you to get more done with less code.
141
123
142
124
[Namespaces](https://en.wikipedia.org/wiki/Namespace) improve productivity by cutting down on bugs and syntax errors.
143
125
126
+
144
127
## Scientific Programming
145
128
146
129
```{index} single: scientific programming
@@ -150,19 +133,19 @@ Python has become one of the core languages of scientific computing.
150
133
151
134
It's either the dominant player or a major player in
152
135
153
-
*[machine learning and data science](https://github.com/ml-tooling/best-of-ml-python)
#### Other Useful Statistics and Data Science Libraries
349
-
350
-
```{index} single: statsmodels
351
-
```
352
-
353
-
*[statsmodels](http://statsmodels.sourceforge.net/) --- various statistical routines
354
-
355
-
```{index} single: scikit-learn
356
-
```
357
-
358
-
*[scikit-learn](http://scikit-learn.org/) --- Machine Learning in Python
359
-
360
-
```{index} single: PyTorch
361
-
```
362
-
363
-
*[PyTorch](https://pytorch.org/) --- Deep learning framework in Python and other major competitors in the field including [TensorFlow](https://www.tensorflow.org/overview) and [Keras](https://keras.io/)
364
-
365
-
```{index} single: Pyro
366
-
```
367
-
368
-
*[Pyro](https://pyro.ai/) and [PyStan](https://pystan.readthedocs.org/en/latest/) --- for Bayesian data analysis building on [Pytorch](https://pytorch.org/) and [stan](http://mc-stan.org/) respectively
369
-
370
-
```{index} single: lifelines
371
-
```
372
-
373
-
*[lifelines](https://lifelines.readthedocs.io/en/latest/) --- for survival analysis
374
-
375
-
```{index} single: GeoPandas
376
-
```
377
-
378
-
*[GeoPandas](https://geopandas.org/en/stable/) --- for spatial data analysis
379
-
380
-
381
242
### Networks and Graphs
382
243
383
244
Python has many libraries for studying graphs.
@@ -423,128 +284,28 @@ nx.draw_networkx_nodes(g,
423
284
plt.show()
424
285
```
425
286
426
-
### Cloud Computing
427
-
428
-
```{index} single: cloud computing
429
-
```
430
-
431
-
Running your Python code on massive servers in the cloud is becoming easier and easier.
432
-
433
-
```{index} single: cloud computing; google colab
434
-
```
435
-
436
-
An excellent example of the portability of python in a cloud computing environment is [Google Colab](https://colab.research.google.com/). It hosts the Jupyter notebook on cloud servers with no pre-configuration necessary to run Python code using cloud servers.
437
-
438
-
439
-
There are also commercial applications of cloud computing using Python:
*[Amazon Web Services](https://aws.amazon.com/developer/language/python/?nc1=f_dr)
287
+
### Other Scientific Libraries
449
288
450
-
```{index} single: cloud computing; Google Cloud
451
-
```
452
-
453
-
*[Google Cloud](https://cloud.google.com/)
454
-
455
-
```{index} single: cloud computing; digital ocean
456
-
```
457
-
458
-
*[Digital Ocean](https://www.digitalocean.com/)
459
-
460
-
461
-
### Parallel Processing
462
-
463
-
```{index} single: parallel computing
464
-
```
465
-
466
-
Apart from the cloud computing options listed above, you might like to consider
467
-
468
-
```{index} single: parallel computing; ipython
469
-
```
470
-
471
-
*[Parallel computing through IPython clusters](https://ipyparallel.readthedocs.io/en/latest/).
472
-
473
-
474
-
```{index} single: parallel computing; Dask
475
-
```
476
-
477
-
*[Dask](https://docs.dask.org/en/stable/) parallelises PyData and Machine Learning in Python.
478
-
479
-
```{index} single: parallel computing; pycuda
480
-
```
289
+
Here's a short list of more important scientific libraries for Python.
481
290
482
-
* GPU programming through [JAX](https://jax.readthedocs.io/en/latest/notebooks/quickstart.html), [PyCuda](https://wiki.tiker.net/PyCuda), [PyOpenCL](https://documen.tician.de/pyopencl/), [Rapids](https://rapids.ai/), etc.
483
-
484
-
485
-
Here is more about [recent developments](https://pasc22.pasc-conference.org/program/papers/) in high-performance computing (HPC) in scientific computing and [how HPC helps researchers in different fields](https://pasc22.pasc-conference.org/program/keynote-presentations/).
486
-
487
-
(intfc)=
488
-
### Other Developments
489
-
490
-
There are many other interesting developments with scientific programming in Python.
*[PyInstaller](https://pyinstaller.org/en/stable/) --- create packaged app from python script.
537
-
538
-
## Learn More
539
-
540
-
* Browse some Python projects on [GitHub](https://github.com/trending?l=python).
541
-
* Read more about [Python's history and rise in popularity](https://www.welcometothejungle.com/en/articles/btc-python-popular) and [version history](https://www.python.org/doc/versions/).
542
-
* Have a look at [some of the Jupyter notebooks](http://nbviewer.jupyter.org/) people have shared on various scientific topics.
543
-
544
-
```{index} single: Python; PyPI
545
-
```
291
+
*[SymPy](http://www.sympy.org/) for symbolic algebra, including limits, derivatives and integrals
292
+
*[pandas](http://pandas.pydata.org/) for data maniputation
293
+
*[statsmodels](http://statsmodels.sourceforge.net/) for statistical routines
294
+
*[scikit-learn](http://scikit-learn.org/) for machine learning
295
+
*[JAX](https://github.com/google/jax) for automatic differentiation, accelerated linear algebra and GPU computing
296
+
*[PyTorch](https://pytorch.org/) for deep learning
297
+
*[Keras](https://keras.io/) for machine learning
298
+
*[Pyro](https://pyro.ai/) and [PyStan](https://pystan.readthedocs.org/en/latest/) for Bayesian data analysis
299
+
*[lifelines](https://lifelines.readthedocs.io/en/latest/) for survival analysis
300
+
*[GeoPandas](https://geopandas.org/en/stable/) for spatial data analysis
301
+
*[Dask](https://docs.dask.org/en/stable/) for parallelization
302
+
*[Numba](http://numba.pydata.org/) for making Python run at the same speed as native machine code
303
+
*[CVXPY](https://www.cvxpy.org/) for convex optimization
304
+
*[PyTables](http://www.pytables.org) for managing large data sets
305
+
*[scikit-image](https://scikit-image.org/) and [OpenCV](https://opencv.org/) for processing and analysing image data
306
+
*[FLAML](https://mlflow.org/docs/latest/index.html) for automated machine learning and hyperparameter tuning
307
+
*[BeautifulSoup](https://www.crummy.com/software/BeautifulSoup/bs4/doc/) for extracting data from HTML and XML files
546
308
547
-
* Visit the [Python Package Index](https://pypi.org/).
548
-
* View some of the questions people are asking about Python on [Stackoverflow](http://stackoverflow.com/questions/tagged/python).
549
-
* Keep up to date on what's happening in the Python community with the [Python subreddit](https://www.reddit.com:443/r/Python/).
550
309
310
+
In this lecture series we will learn how to use many of these libraries for
311
+
scientific computing tasks in economics and finance.
0 commit comments