filmov
tv
Python Numpy Tutorial - 5 ... Random Array/Module || np.random( )
![preview_player](https://i.ytimg.com/vi/RORhrI-4OdA/maxresdefault.jpg)
Показать описание
-----------------------------------------
!! Numpy Random Module !!
The Random Module contain the functions which are used for generating random numbers.
1. Random Function - It returns random float number(s) between 0 and 1.
2. Randint Function
- It generates random integer number(s) between given range.
- By default, the range starts from 0.
- The numbers can repeat.
3. Rand Function - It returns random float number(s) between 0 and 1.
4. Randn Function - It returns random float numbers (postive and negative both) in the form of array.
5. Uniform Function
- It returns random float number(s) between the given range of values.
- The random numbers can't repeat.
- By default, the range starts from 0.
- If nothing is passed in (), it will return a float number between 0 and 1.
6. Choice Function
- It returns random integer number(s) from the given sequence.
- The range starts from 0 by default.
- If only 1 element is passed, then it will return a number between 0 and that element.
- By default, replace = True , which means the numbers can repeat.
* ndim - to check the dimension of the array
* shape - to check the shape of the array
* size - to check the size of the array
------------------------------------------
------------------------------------------------
-------------------------------------------
------------------------------------------
🇮🇳 DATA SCIENCE LOVERS 🧡💛💚
-------------------------------------------
You must check our projects videos :
#python #dataanalytics #numpy