Pandas is the most popular python library that is used for data analysis. It provides highly optimized performance with back-end source code is purely written in C or Python.
We can analyze data in pandas with:
Series is one dimensional(1-D) array defined in pandas that can be used to store any data type.
Code #1: Creating Series
Here, Data can be:
- A Scalar value which can be integerValue, string
- A Python Dictionary which can be Key, Value pair
- A Ndarray
Note: Index by default is from 0, 1, 2, …(n-1) where n is length of data.
Code #2: When Data contains scalar values
Code #3: When Data contains Dictionary
Code #4:When Data contains Ndarray
DataFrames is two-dimensional(2-D) data structure defined in pandas which consists of rows and columns.
Code #1: Creation of DataFrame
Here, Data can be:
- One or more dictionaries
- One or more Series
- 2D-numpy Ndarray
Code #2: When Data is Dictionaries
Code #3: When Data is Series
Code #4: When Data is 2D-numpy ndarray
Note: One constraint has to be maintained while creating DataFrame of 2D arrays – Dimensions of 2D array must be same.
- Data Analysis and Visualization with Python | Set 2
- Exploratory Data Analysis in Python | Set 2
- Exploratory Data Analysis in Python
- Data analysis and Visualization with Python
- Multidimensional data analysis in Python
- Exploratory Data Analysis in Python | Set 1
- Python | Math operations for Data analysis
- Replacing strings with numbers in Python for Data Analysis
- Analysis of test data using K-Means Clustering in Python
- Data Manipulattion in Python using Pandas
- Python | Pandas Index.data
- Python | Pandas Series.data
- Data profiling in Pandas using Python
- Python | Data Comparison and Selection in Pandas
- Python | Filtering data with Pandas .query() method
- Data Analysis with SciPy
- Violin Plot for Data Analysis
- Data Analysis in Financial Market – Where to Begin?
- Python | Pandas Series.astype() to convert Data type of series
- Using csv module to read the data in Pandas
If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to email@example.com. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.