A DevDotCom x Coding Club JISCE initiative to Practice Numpy
Create a folder with your name then create a file within that folder with the name task1.py for the first task
.
├── Numpy-Practice
│ ├── Your Name
│ │ ├── task1.py
│ │ ├── task2.py
│ │ ├── task3.py
│ │ └── ...
│ ├── other files and folders
└── ...
See the tasks as below. Try to think how you can do it on your own. If you cannot do it refer to the guide.ipynb file in the guide folder. See the code and think what the code is doing. Copy and Run the code in your task file. Think about the output. Also don't forget to use comments to explain what the code is doing.
Task List
- Numpy version
- Create an empty array
- Check whether the array is empty
- Check elements count
- Arrange numpy between numbers
- Arrange numpy between numbers with intervals
- Array reshape
- Create a numpy with random integers
- Create a numpy with random integers and size
- Array of strings
- Numpy array with strings and explicit dtype
- Numpy array with strings and explicit dtype
- Print without truncation
- Save Numpy to CSV
- Dataframe to Numpy
- Get the nth column of an array
- Reshape with -1 (lazy option)
- Numpy with precision
- Argsort on Numpy array
- Numpy view
- Using Flipud
- Numpy inverse
- Numpy Inverse
- Numpy compare
- Numpy compare with nonzero count
- Flip a numpy array by using flipud
- Flip a numpy array by using flipud without sharing the memory
- Flip a numpy array by using fliplr (horizontally)
- Flip a numpy array by using flip (both horizontally and vertically)
- Flipping the numpy array using slices
- Convert numpy array to list
- Numpy Where
- Numpy where with multiple conditions
- Numpy where with multiple conditions - apply only on matching conditions
- Process with where
- List to numpy array
- List to numpy array with explicit dtype
- 2D list to numpy array
- Convert list to float numpy array
- Convert list to numpy array with explicit datatype
- Find common values between two numpy array
- Get today in numpy and deltas
- Between two Dates
- Random array and sorting
- Random int array and sorting
- String to numpy array
- Find the nearest element in the array
- Swap rows
- Shuffle
- Get specific element
- Repeat an array
- Min, Max, Sum
- Get min of axis = 1
- Using amin function
- Using amax function
- Get min of axis = 0
- Calculate 90th percentile of an axis
- Find median
- Covariance matrix
- Pearson product-moment correlation
- Cross correlation
- Count the number of occurrences
- Create random int numpy array with specific shape
- Create 4 different integers from 0, 40.
- Create 4 different integers from 0, 4.
- Shuffle
- Shuffling by permutation
- Seed for random
- Get unique elements
- Create a boolean array with a shape of x
- Find unique intersection
- Find the diff
- Trying to inverse a singular matrix
- Find the union
- Element Sum
- Pretty print - suppress the scientific notation
- Print with decimal format
- Convert flot array to int array
- array vs asarray
- Numpy Datetime
- Numpy Datetime with arange
- Compare Numpy datetime
- Numpy 2D array flat list
- Numpy 2D array to flat list
- Numpy array to Pandas Dataframe
- Numpy to Dataframe by using from_records
- Append with hstack
- Ravel vs. Flatten
- Ravel and Flatten with assignment
- Numpy Concatenate
- Reverse 1D array
- Reverse 2D Array
- Reverse 2D array with elements
- Image as an array
- Array with prefilled values
- Delete specific indices
- Deleting specific elements
- Boolean Numpy Array
- Array of NaN
- Replace values with specific condition
- Selecting specific columns
- Vectorize
- If condition on Numpy array on the fly
- If condition and sum on Numpy colum
- Using Vectorize function on Numpy
- Apply Along Axis on Numpy Matrix
- Sort the arry by using
- Numpy Roll
- Roll elements
- Array Append on Axis 0 and Axis 1
- Rearrange array with specified index
- Serialize array with pickle
- Transpose
- Continguous Array
- Numpy Reshape with Order
- Element-wise math
- Where with multiple condition
- Subtract Outer
- Multiply Outer
- Immutable Array
- Float anomalies in Numpy Arange
- Complex number and absolute value
- Set Error in Numpy
- Convert List of List String to Numpy Array
- Resize a list with rounds
- Print columns by index
- Initalize array with tuples
- Rearrange with permutation