Here you can see the basics of Python programming with the provided codes to be executed. Note to use the codes you need to have a Gmail account and be logged into it.
In this lab, basics of the variables are explained. By clicking on the colab link you can see small codes that you can use to experiment working with variables, which include
String
Integer numbers
Floating numbers
Boolean numbers
Then in the continuation, you will be able to work with basic data structures that include
String
List
Tuple
Dictionary
In this lab, we will learn about the following subjects
Conditions, or it is usually known as 'if...elif...else', is a set of conditions under which the program is running and verifying them. If they hold the associated task is executed, otherwise it will move to the next condition
Loops
For loop: This type of loop is repeating a task while covering members of a data set, like a list of a range
While loop: This type of loop will repeat a task while it is still true
Function: A function is a unit of code to complete a task by a given input and returning an output
In this lab, you will see about the following topics
Numpy Array Functions
Mathematics
Array Mathematics: Addition, Division, Multiplication, Exponentiation, Square, sines, cosine, natural logarithm, Dot product, etc
Comparison
Aggregate Functions: min, max, the cumulative sum
Subsetting, slicing, indexing
Array Manipulation
Transposing Array
Changing Array Shape
Adding/Removing Elements
Combining Arrays
Splitting Arrays
In this lab, you will see about the following topics
The Pandas library is built on NumPy and provides easy-to-use data structures and data analysis tools for the Python programming language.
Pandas Data Structures
Series
Data frame
Selection
Slicing
Merging
Concatenation
The first assignment is about the Markowitz portfolio management model. You will need to write a program based on the description to find the optimal portfolio and plot the efficient frontier for a given portfolio.
This library is used for plotting numerical data.
It is very useful for data analysis.
It can complete tasks that include pie charts, histograms, scatterplots, graphs, etc.
The name “SciPy” is a combination of ‘Scientific’ ‘Python’.
It is an advanced library to complete high-level scientific computations.
This library is based on Numpy to handle complex computations.
SciPy includes modules for optimization, linear algebra, integration, interpolation, special functions, FFT, signal and image processing, ODE solvers and other tasks common in science and engineering.
In this part, we will see how to do
summary statistics
linear regression
logistic regression
In this code you will see:
How to simulate geometric Brownian motion
How to use it to obtain option prices by simulation
How to obtain option prices by Black-Scholes formula
The final assignment is about regression and factor models. You will need to write a program based on the description to find the factor model specifications as asked inside the assignment description.