What is a vector in Data Science?
The word “vector” in physics refers to a quantity with a direction. A vector in data science is no different than a vector in physics. Each object or a data point of a tabular data is sometimes referred to as a vector.
That is, In data science,
a point in the space=an object of the data table=a vector
Why do we call an object a vector? Before answering this question, we need to know what an origin is.
The origin
Regardless of the data points in the space, there is an origin in every data table. The origin is the coordinate where the value in every axis is zero. That is, the origin in a two-dimensional space is (0, 0). The origin in a three-dimensional space is (0, 0, 0). The origin of a four-dimensional space is (0, 0, 0, 0). So and so forth. There might not be an exact row in the table that contains all zeros, but there is one virtually in the space that is formed by the dataset.
What is a vector in data science?
A data point or an object is called a vector because it resembles the concept of direction and magnitude in physics or mathematics. The vector formed by a data point has the direction pointing from the origin toward the data point. The magnitude of the vector is considered to be the distance between the origin and the point.
Consider that we have the following two-dimensional data table.
Feature 1 | Feature 2 |
20 | 90000 |
30 | 85000 |
28 | 40000 |
40 | 95000 |
35 | 42000 |
We have five objects or five data points. Each of these five data points is a vector. All five vectors are drawn in the following figure. Notice that the vectors have a direction from the origin toward the data points.
In practice, we do not have to worry much about the directions of the vectors in data science. Consider each vector as a one-dimensional array.
In computer science, an array is frequently called a vector because the array content forms a vector in the space. In data science, sometimes we use vector-based math, many times we don’t. For simplicity, you can consider that “vector” is another name of a data point or an object.
14 Comments
Hi! I’m Aniwari from Eswatini, l’m happy to join you and I find this lecture interesting indeed
So good interesting ssession, am very happy to interact
great
I am glad to hear that you liked it!
so much interesting class
Thank you!
Very interesting classes. Keep it up, Sir.
It looks like i am a bit late to start seeing the other people comment dated back July 2020. It is better late than never. Thanks so much for the good work you are doing
I cant stop but to make sure i complete all the course and watch the videos also i will recommend it to all my colleagues
Thank you for visiting, commenting, and sharing the page with your colleagues. I am currently running a workshop series. The videos of the workshop series are available in this YouTube playlist: https://www.youtube.com/playlist?list=PLJXHwy-4vGRbLixeEJ8dQsOAeVZdBAFUz.
I hope you will enjoy.
Thanks for making it so easy to understand
I am glad to know that you liked it. I will be making more of the videos in the coming months. Thank you for visiting and your comment. Have a wonderful week.
Hi, I’m Azadeh from Iran, working as an industrial engineer and interested in data analysis. Although I have some background about mathematics, but the lectures are so smooth, understandable and attractive that I really like to continue the course nonstop. It’s really appreciated.
Thank you for your kind words. I am planning to make more data science-related videos in the coming months. Please stay tuned.
Have a wonderful week.
ok sir , Keep it up . We prey for ur success in achieving ur task with hopeful wishes.