Удалил Untitled.ipynb
This commit is contained in:
8
src-numpy/random_walk_numpy.py
Normal file
8
src-numpy/random_walk_numpy.py
Normal file
@@ -0,0 +1,8 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
import numpy as np
|
||||
|
||||
nsteps = 1000
|
||||
draws = np.random.randint(0, 2, size=nsteps)
|
||||
steps = np.where(draws > 0, 1, -1)
|
||||
walk = steps.cumsum()
|
||||
Reference in New Issue
Block a user