Skip to content

Commit 70c1c9f

Browse files
committed
add docstring
1 parent 3930f4d commit 70c1c9f

File tree

1 file changed

+29
-0
lines changed

1 file changed

+29
-0
lines changed

eda_utils_py/eda_utils_py.py

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,3 +26,32 @@ def cor_map(dataframe, num_col):
2626
cor_map(data, numerical_columns)
2727
2828
"""
29+
30+
31+
def outlier_identifier(dataframe, columns = None, method = "somefunction"):
32+
"""
33+
A function that identify and deal with outliers based on the method the user choose
34+
35+
Key arguments:
36+
dataframe [pandas.DataFrame]:
37+
The target dataframe where the function is performed.
38+
columns [list] : None
39+
The target columns where the function needed to be performed. Defualt is None, the function will check all columns
40+
method [string] : "somefunction"
41+
The method of dealing with outliers.
42+
43+
Returns:
44+
dataframe :
45+
The dataframe which the outlier has already process by the chosen method
46+
47+
Examples:
48+
data = pd.DataFrame({
49+
'SepalLengthCm':[5.1, 4.9, 4.7],
50+
'SepalWidthCm':[1.4, 1.4, 9999999.99],
51+
'PetalWidthCm:[0.2, 0.2, 0.2],
52+
'Species':['Iris-setosa','Iris-virginica']
53+
})
54+
55+
outlier_identifier(data)
56+
57+
"""

0 commit comments

Comments
 (0)