Skip to content

Commit 119f66d

Browse files
committed
docu
1 parent b69376c commit 119f66d

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

toolkit/plot.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,13 +51,15 @@ def plot_ngrams(df, target:str, text:str, n_gram:int):
5151
'''
5252
This function allows visualizing the frequency of occurrence of words and n-grams (sets of a number of consecutive words) based on the target variable.
5353
54-
Parameters:
54+
Parameters
55+
----------
5556
- df: Dataframe with a text variable.
5657
- target: Column of the dataframe where the target variable is located.
5758
- text: Column of the dataframe where the text is located.
5859
- n_gram: Number of consecutive words whose frequency we want to visualize.
5960
60-
Returns:
61+
Returns
62+
----------
6163
- Bar chart representing the frequency of words, sorted from highest to lowest, divided by target variable.
6264
'''
6365

0 commit comments

Comments
 (0)