0% found this document useful (0 votes)
3 views

pandas_methods

The document provides a comprehensive overview of various data manipulation methods using pandas in Python. It includes categories for data loading, inspection, cleaning, selection, filtering, transformation, grouping, merging, visualizing, and exporting data. Each method is briefly described, highlighting its primary function.

Uploaded by

menilac972
Copyright
© © All Rights Reserved
Available Formats
Download as XLSX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
3 views

pandas_methods

The document provides a comprehensive overview of various data manipulation methods using pandas in Python. It includes categories for data loading, inspection, cleaning, selection, filtering, transformation, grouping, merging, visualizing, and exporting data. Each method is briefly described, highlighting its primary function.

Uploaded by

menilac972
Copyright
© © All Rights Reserved
Available Formats
Download as XLSX, PDF, TXT or read online on Scribd
You are on page 1/ 2

Category Method Description

Data Loadipd.read_csRead CSV files


Data Loadipd.read_exRead Excel files
Data Loadipd.read_jsRead JSON files
Data Loadipd.read_sqlRead SQL tables
Data Loadipd.read_htRead HTML tables
Data Inspedf.head(n) Display top n rows
Data Inspedf.tail(n) Display last n rows
Data Inspedf.info() Summary of DataFrame
Data Inspedf.describeStatistical summary
Data Inspedf.shape Number of rows and columns
Data Inspedf.columnsList of column names
Data Inspedf.dtypes Data types of each column
Data Cleandf.isnull() Check missing values
Data Cleandf.dropna(Remove missing values
Data Cleandf.fillna(vaReplace missing values
Data Cleandf.duplicatCheck duplicate rows
Data Cleandf.drop_dup Remove duplicate rows
Data Cleandf.rename(Rename columns
Data Selec df['column'Select single column
Data Selec df[['columnSelect multiple columns
Data Selec df.loc[] Select by labels
Data Selec df.iloc[] Select by index
Data Selec df.at[] Access single value by labels
Data Selec df.iat[] Access single value by index
Data Filter df[df['colu Filter rows based on condition
Data Filter df.query() Query method for filtering
Data Filter df[df['columFilter rows with specific values
Data Transdf.apply() Apply custom functions
Data Transdf.map() Apply functions to each element
Data Transdf.replace(Replace values
Data Transdf.astype()Change data type
Data Transdf.sort_valSort data by columns
Grouping adf.groupbyGroup data
Grouping adf.agg() Aggregate data
Grouping adf.pivot_taCreate pivot tables
Grouping adf.crosstabCross tabulation
Merging anpd.concat(Concatenate DataFrames
Merging anpd.merge()Merge DataFrames
Merging andf.join() Join DataFrames on index
Data Visualdf.plot() Simple plotting
Data Visualdf.hist() Histogram plotting
Data Visualdf.boxplot(Box plot
Exporting df.to_csv()Export to CSV
Exporting df.to_excelExport to Excel
Exporting df.to_json(Export to JSON
Exporting df.to_sql() Export to SQL

You might also like