INTRODUCTION TO PANDAS (SERIES,DATAFRAME,PANEL) - PYTHON PROGRAMMING

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
[Music] hello friends welcome back to our channel so in today's session we'll see a brief introduction about the pandas library right so coming to this pandas library why we are using these partners and what are the features of this pandas making the first and foremost feature is so it is a high performance data analysis tool so it is a high performance data analysis so this partners library is mainly used for data analysis okay so we can analyze the data so it will be used for working with working with large data sets okay so large data sets we can work in a simple way with an efficient way okay with an efficient way and the third one is so it will be accepting different file formats so the data will be accepted or loaded in different file formats so it supports supports or it can load files with different formats with the different formats okay that means excel csv so whatever it may be we can it will accept the different file formats okay and the next one is more flexible more flexible to use it was more flexible to use okay and one more thing so for for analyzing the data this pandas will represent the complete data in terms of rows and columns that means the data will be represented in tabular format okay so represents in tabular way in a tabular way so that means we can have different rows and columns so the data can be represented in both the rows and columns rows and columns okay and one more additional feature in this pandas is it is more efficient to work with the missing data okay the working on missing data so this pandas is suitable for working on missing data so we'll see one by one right so we'll see one by one in the further sessions don't worry so and the next one is similar to our data structures data types which you have seen in python so this pandas is used for indexing [Music] okay use it for indexing slicing so we can apply the slicing operations and also substituting subsetting large data okay the large data if you are working with large data we can index a data or we can slice extract some portion and or we can subset okay we can divide the complete data into different subsets and all these things can be done by using this partners that means it will it will supports the indexing slicing subsetting then on the large data sets okay on the large data sets and one more thing we can merge and join easily we can match our join two different data sets easily we can re we can merge and join two different data sets easily and the next one is we can reshape the data sets we can also reshape the data sets so we have seen this reshaping right so in numpy we have reshaped the complete arrays so according to our dimensions we have we can reshape it right so similarly here also we can reshape the data sets in partners so for everything there are different functions so in further sessions we are going to see all those uh functions built-in functions right so before going to that we are saying that it is a high performance data analysis tool it is high performance and efficient data analysis role and this happens with the three data structures this can be happened with the help of three data structures used in partners okay so this partners will use three data structures so what are those data structures the first one is series second one is data frame and the third one is panel third one is panel okay so first we'll go with these two and later we'll see this panel okay later we'll see this panel and coming to the series so this in this series series data structure the data will be represented in a one dimensional array so it will be represented in a one dimensional okay all the data will be represented in one dimensional and in the data frame data will be represented in two dimensional two dimensional okay so whatever the think either series or a data frame either series or a data frame the data will be represented in a tabular format tabular format okay so additional element will be included that is the index based upon the index the tabular format will be created even though we are using the series or a data frame right but mainly the data will be represented in one dimensional and the data will be represented in a two dimensional and here the panel is for the multi-dimensional multi-dimensional okay so if you are using the series if you are using the series we have to take a list as an example okay we can pass this list as an argument to the series function so we are having some series function data frame function and a panel function right so in the series function a list we can take the list as an argument list as an argument okay and coming to this data frame we can pass list or dictionary dictionary or series or another data okay another data frame another data frame so we can give anyone as a parameter to the data frame okay so we can pass a list or a dictionary or a series or any other data frame and coming to this panel coming to this panel we are having a syntax as see we will pass the data so the data can be any one among these things and major axis major axis minor axis that means nothing but columns rows columns and rows we have to represent the data in terms of this one right so coming to the series coming to the series the syntax for the series is so first we have to import the pandas before using all these things right so before importing the partners we have to make sure that pandas is installed in our system or not so if you are using any anaconda distribution software so implicitly the panda software will be available with the with that anaconda software so you need not explicitly install that pandas library and if you are using idle then implicit explicitly you have to install the library pandas library okay so before that we have to import the pandas so we can give an alias name or directly we can use the pandas that means library name similar to similar to our numpy okay so pandas dot pd pd or any identifier you can do so pd is not an um mandatory so we can give any any other alias name any other alias name we can also give some library okay so import pandas at pd and now the syntax for this one is pd dot series yes it should be captured so so far we have seen all the things in a lower case but here we are we have to use the capital s in the series so series followed by the data comma index comma index two parameters should be taken two parameters should be taken so here the data will be the list data will be the list or any one dimensional array any one dimensional array so that will be the thing and i will show you the implementation how to create a simple data by using the series okay by using that series and for this data frame again pd dot data frame d capital and f capital no space okay there is no space and go with the data go with the data okay go with the data so here there are different uh possibilities so we can give the index or we may not give the index so there are different cases so i will explain you one by one in the further sessions right so here the data will be either list or a dictionary or a series or any other data frame and coming to the panel so pd dot panel p must be capital x panel go with the data as i have said that the major axis minor axis okay we can go with the d type and copy etc etc etc right so this is the syntax for creating the panel okay panel so after creating the series after creating the series we can apply different functionalities different operations on those series and similarly the data frame so among these three the data frame is most efficient data structure most efficient data structure to do the analysis on data sets to do the analysis on data sets so there are a lot of options available in this data frame so working with the data frame right so we can slice we can index we can subset and we can access a lot of functions available in this data frame object so first we have to create a data frame object and then we have to apply the different operations so in the further sessions we'll go with one by one okay one by one so let us move on to the computer and i will show you just a syntax and executing all the these data structures okay so first we will go with these two things and later we will discuss about the panel so first we will discuss about the series and data frame okay so now we will create a simple series and a simple data frame object right so let us move on to the interpreter hello friends so just now we have seen the basic introduction to the pandas library and in that we have seen different features of pandas and we have already also seen the different data structures used in pandas so that is a data frame series and panel so in this session we will see how to create a series and how to create the data frame and uh we'll see in the next session we'll see the working of series and uh data frame right so first we will create one data frame on series so for before that we have to import the pandas so before importing the pandas we have to install the pandas library if it is not available so i have already made a session how to install the pandas so you can refer that and after that import the pandas by using some alias name so there is an optional thing if you are not using the alias name you have to call the objects or functions by using the library name so i am giving some alias name so that i will call each and every function or any everything with the help of the alias name right and here you can observe if if there is a star in between the subscript that implies the statement is still being executed right so whenever it turns into a numeric automatically see you can observe star turns to one so that means the statement has been executed successfully without any error now first we will create a list and we will pass the list into a series so that it will be forming a series some pd dot so we have to call with the help of a library so pd dot series s should be capital syntax we should follow this index and pass the okay data you can observe the representation in a tabular format rows and columns so here 0 1 2 3 are nothing but any index values so we are not specifying any index values but this series function will automatically display everything in form of table table and the index values by default it will be 0 1 2 3 and if you want to change the index values you can change by using the index attributes see series data and give the index is equal to we can give we can pass any index right so for example see i'll give some roman number 1 2 three four so i'm changing this index value so you can observe here so index values are changing from zero to uh in this format okay so we can change the index values with the our own format required format right so this is how we can use the series so working on series will go with the next session right so this is just a basic introduction so how to create a series and how to create a data frame now we'll create a data frame so before creating a data frame we have to pass the data to the data frame function so the data can be either list or a series or any other i mean dictionary so first we'll create a dictionary so then we'll go with this one so i will create a dictionary with a naming attributes so name i will give some names in this one see so i'm giving some three names yeah comma and the second one percentage and give the list in the percentage some 90 85 and 95 so here we have created a dictionary so we have to pass this dictionary to the data frame so pd dot data frame b and f capital so follow the syntax data frame pass the dictionary to the data frame function so automatically we'll get the result in the form of tabular format with the naming attributes right so column names so name is your first call first column and a percentage second column so here we got the complete data in terms of a table right so like this we can create the series and data and after creation of the series and data frame we can access the data and we can work on the data different columns individually with the columns right so all these things will see in the next session so let's stop here so hope you understood how to create a series in the data frame and if you are having any doubts regarding this creation so feel free to post your doubts in the comment section so that definitely will try to clarify all your doubts and if you really understood my session like my session share my session with your friends and don't forget to subscribe to our channel so thanks for watching thank you very much
Info
Channel: Sundeep Saradhi Kanthety
Views: 23,058
Rating: 4.938838 out of 5
Keywords: sundeep, saradhi, kanthety, python, programming, basics, fundamentals, programming concepts, date and time, modules, object, create object, strftime, now, import, programming fundamentals, oop concepts, PYTHON PROGRAMMING, PYTHON FUNDAMENTALS, interpreter, python libraries, libraries, numpy, pandas, matplotlib, numpy installation, libraries installation, python IDE, python IDLE, pip package, pip command, PANDAS, idle, anaconda, series, dataframe, panel, pandas datastructures, data analysis, data sets
Id: fAxjxoNqU9o
Channel Id: undefined
Length: 16min 20sec (980 seconds)
Published: Mon Oct 05 2020
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.