Gaurav Kumar has Published 49 Articles

Gaurav Kumar
293 Views
The scipy.interpolate.interp1d(x, y, kind, axis, copy, bounds_error, fill_value, assumesorted) class of SciPy library, as name implies, is used to interpolate a 1-Dimensional function. Here, x and y are the arrays of values which are used to approximate some function, say f; y=f(x). The output of this class is a function ...

Gaurav Kumar
1K+ Views
NumPy, stands for Numerical Python, is used for the manipulation of elements of numerical array data. SciPy, stands for Scientific Python, is used for numerical computations in Python. Both these packages provide extended functionality to work with Python. Let’s understand some basic differences between NumPy and SciPy −Functional differences − NumPy ...

Gaurav Kumar
191 Views
SciPy is built upon the following core packages −Python − Python, a general-purpose programming language, is dynamically typed and interpreted. It is well suited for interactive work and quick prototyping. It is also powerful to write AI and ML applications.NumPy − NumPy is a base N-dimensional array package for SciPy that allows ...

Gaurav Kumar
611 Views
We can install Python SciPy with the help of following methods −Scientific Python Distributions − There are various scientific Python distributions that provide the language itself along with the most used packages. The advantage of using these distributions is that they require little configuration and work on almost all the setups. ...

Gaurav Kumar
1K+ Views
To cover different scientific computing domains, SciPy library is organized into various sub-packages. These sub-packages are explained below −Clustering package (scipy.cluster) − This package contains clustering algorithms which are useful in information theory, target detection, compression, communications, and some other areas also. It has two modules namely scipy.cluster.vq and scipy.cluster.hierarchy. As ...

Gaurav Kumar
418 Views
SciPy, pronounced as “Sigh Pie”, is an ecosystem of Python open-source libraries for performing Mathematical, Scientific, and Engineering computations. SciPy stands for Scientific Python and is comprised of the following core packages, called SciPy ecosystem −NumPy − NumPy is a base N-dimensional array package for SciPy that allows us to efficiently ...

Gaurav Kumar
580 Views
The Minkowski distance, a generalized form of Euclidean and Manhattan distance, is the distance between two points. It is mostly used for distance similarity of vectors. Below is the generalized formula to calculate Minkowski distance in n-dimensional space −$$\mathrm{D= \big[\sum_{i=1}^{n}|r_i-s_i|^p\big]^{1/p}}$$Here, si and ri are data points.n denotes the n-space.p represents ...

Gaurav Kumar
1K+ Views
The Manhattan distance, also known as the City Block distance, is calculated as the sum of absolute differences between the two vectors. It is mostly used for the vectors that describe objects on a uniform grid such as a city block or chessboard. Below is the generalized formula to calculate ...

Gaurav Kumar
933 Views
Euclidean distance is the distance between two real-valued vectors. Mostly we use it to calculate the distance between two rows of data having numerical values (floating or integer values). Below is the formula to calculate Euclidean distance −$$\mathrm{d(r, s) =\sqrt{\sum_{i=1}^{n}(s_i-r_i)^2} }$$Here, r and s are the two points in Euclidean ...

Gaurav Kumar
823 Views
The Pima Indian Diabetes dataset, which we will be using here, is originally from the National Institute of Diabetes and Digestive and Kidney Diseases. Based on the following diagnostic factors, this dataset can be used to place a patient in ether diabetic cluster or non-diabetic cluster −PregnanciesGlucoseBlood PressureSkin ThicknessInsulinBMIDiabetes Pedigree ...