this repository contains all brief information about pandas (Series/DataFrame) contains all functions and methods like groupby(),merge and many more.
π Ώπ °ππ 1 π ²π Ύπ ½ππ °π Έπ ½π
1.What is Pandas.
2.Series from lists
3.Series from dict
4.Series Attributes(size/dtype/name/is_unique/index/values)
5.Series using read_csv
6.Series methods
7.series.head()/series.tail()
8.series.sample()
9.value_counts()
10.sort_values()
11.sort_index()
12.Series Maths Methods
13.count()
14.series.sum/product
15.mean/median/mode
16.min/max
17.Describe
18.Series Indexing
19.Editing Series
20.astype
21.between
22.clip
23.drop_duplicates
24.duplicated
25.isnull
26.dropna
27.fillna
28.isin
29.apply
30.copy
π Ώπ °ππ 2 π ²π Ύπ ½ππ °π Έπ ½π
Creating DataFrame
1.using lists
2.using dicts
3.using read_csv
4.DataFrame Attributes and Methods shape dtypes index columns values
head and tail() sample() info() describe() isnull() duplicated() rename()
5.Mathematical Methods
6.Selecting cols from a DataFrame -- single cols
7.Selecting cols from a DataFrame -- multiple cols
8.Selecting rows from a DataFrame
9.iloc - searches using index positions
10.loc - searches using index labels
11.Selecting both rows and cols
12.Filtering a DataFrame
13.Adding new cols - completely new
14.Adding new cols - from existing ones
Dataframe IMPORTANT function
1.value_counts
-
Toss decision plot
-
No of matches each team has played
-
sort_values
-
Sort values on nan values
-
Sorting on multiple columns
-
rank
-
sort index
-
set index
-
reset index
-
How to replace existing index without loosing
-
Series to dataframe using reset_index
-
rename index & rename
-
unique & nunique
-
isnull/notnull
-
dropna
-
fillna
-
drop_duplicates
-
find the last match played by virat kohli in Delhi
-
drop
-
apply
π Ώπ °ππ 3 π ²π Ύπ ½ππ °π Έπ ½π
GroupBy
Applying builtin aggregation fuctions on groupby objects
find the top 3 genres by total earning
find the genre with highest avg IMDB rating
find director with most popularity
find the highest rated movie of each genre
find number of movies done by each actor
find total number of groups -- len
find items in each group -- size
first()/last() / nth item
get_group / vs filtering
groups attribute
describe / # sample / # nunique
looping on groups find the highest rated movie of each genre
apply -- builtin function
find number of movies starting with A for each group
find ranking of each movie in the group according to IMDB score
find normalized IMDB rating group wise
groupby on multiple cols
find the most earning actor -- director combo
find the best(in-terms of metascore(avg)) actor -- genre combo
agg on multiple groupby
π Ώπ °ππ 4 π ²π Ύπ ½ππ °π Έπ ½π
IPL Dataset
π Ώπ °ππ 5 π ²π Ύπ ½ππ °π Έπ ½π
#pd.concat
#df.append
#Concat as mullitindex df
#concat dataframes horizontally
#Merge
#inner_join
#left_join
#right_join
#outer_join
π Ώπ °ππ 6 π ²π Ύπ ½ππ °π Έπ ½π
MultiIndex Session Start
Having Multiple Index
how to create multiindex object
creating a series with multiindex object
Fetching Items from multindex series
Dimension of multi Index series?
#unstack
#stack
Why to use Multi Index series?
#MultiIndex DataFrame
#MultiIndex Data Frame from columns perspective
#MultiIndex on row and column both
#Stacking and #Unstacking
Working with #multiIndex DataFrames
#Transpose Dataframe
#swaplevel
#LongVsWide Data
#Pandas-melt -- simple example branch
π Ώπ °ππ 7 π ²π Ύπ ½ππ °π Έπ ½π
pivot_table
#aggfunc
#multidimensional pivot_table
#pivot_table margin
#plotting_graph
π Ώπ °ππ 8 π ²π Ύπ ½ππ °π Έπ ½π
#pandas_string
lower/upper/capitalize/title
#len/strip
#split -- get
#replace
π Ώπ °ππ 9 π ²π Ύπ ½ππ °π Έπ ½π
#pandas date_time
Creating Timestamp objects
# using datetime.datetime object
# fetching attributes - year/month/day/
#why separate objects to handle data and time when python already has datetime functionality?
#DatetimeIndex Object
#date_range function
#to_datetime function
#date time accessor
#plotting