In [ ]:
import numpy as np

index


In [ ]:
x = np.array([[1,2,3],[4,5,6]],np.int32)
print(x.shape)
x[0,2]

slicing


In [ ]:
print(x[:,2])

changing y has impact on x


In [ ]:
y = x[:,2]
print(y)
y[0]=9
print(y)
print(x)

attributes


In [ ]:
x.flags

In [ ]:
x.shape

In [ ]:
x.strides

In [ ]:
x.data

In [ ]:
x.size

In [ ]:
x.ndim

In [ ]:
x.itemsize

In [ ]:
x.nbytes

In [ ]:
x.min()

In [ ]:
x.argmin()

In [ ]:
x.sum()

In [ ]:
x.mean()