Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Leer Operating with Arrays using NumPy | Python Basics
Introduction to Finance with Python
course content

Cursusinhoud

Introduction to Finance with Python

Introduction to Finance with Python

1. Python Basics
2. Options Trading
3. Time Series Forecasting

book
Operating with Arrays using NumPy

1234567
import numpy as np # Creating list of integers called `lst` lst = [1, 2, 3] # Creating NumPy array `arr` from list `lst` arr = np.array(lst) print(arr) print(type(arr))
copy
1234
import numpy as np # Creating array, in which the first row is [0, 1] and the second is [2, 3] arr = np.array([[0, 1], [2, 3]]) print(arr)
copy
123456
import numpy as np # Initializing array `a` a = np.array([0, 1, 2, 3, -1]) # Getting minimum value from `a` min_ = a.min() print(min_)
copy
123456
import numpy as np # Initializing array `a` a = np.array([[1, 2, 3, 0], [4, 5, 6, 9]]) # Getting mean value for each column of `a` mean_ = a.mean(axis = 0) print(mean_)
copy
question mark

Select the correct answer

Was alles duidelijk?

Hoe kunnen we het verbeteren?

Bedankt voor je feedback!

Sectie 1. Hoofdstuk 4

Vraag AI

expand

Vraag AI

ChatGPT

Vraag wat u wilt of probeer een van de voorgestelde vragen om onze chat te starten.

course content

Cursusinhoud

Introduction to Finance with Python

Introduction to Finance with Python

1. Python Basics
2. Options Trading
3. Time Series Forecasting

book
Operating with Arrays using NumPy

1234567
import numpy as np # Creating list of integers called `lst` lst = [1, 2, 3] # Creating NumPy array `arr` from list `lst` arr = np.array(lst) print(arr) print(type(arr))
copy
1234
import numpy as np # Creating array, in which the first row is [0, 1] and the second is [2, 3] arr = np.array([[0, 1], [2, 3]]) print(arr)
copy
123456
import numpy as np # Initializing array `a` a = np.array([0, 1, 2, 3, -1]) # Getting minimum value from `a` min_ = a.min() print(min_)
copy
123456
import numpy as np # Initializing array `a` a = np.array([[1, 2, 3, 0], [4, 5, 6, 9]]) # Getting mean value for each column of `a` mean_ = a.mean(axis = 0) print(mean_)
copy
question mark

Select the correct answer

Was alles duidelijk?

Hoe kunnen we het verbeteren?

Bedankt voor je feedback!

Sectie 1. Hoofdstuk 4
some-alt