Counting user interventions

Counting the user interventions can give relevant insights on which users “dominate” the conversation, even more in a group chat. To this end, object FigureBuilder has the method user_interventions_count_linechart, which generates a plotly figure with the count of user interventions.

First of all, we load a chat and create an instance of FigureBuilder.

>>> from whatstk import WhatsAppChat, FigureBuilder
>>> from whatstk.graph import plot
>>> from import whatsapp_urls
>>> chat = WhatsAppChat.from_source(filepath=whatsapp_urls.LOREM_2000)
>>> fb = FigureBuilder(chat=chat)

Count of user interventions

Default call of the aforementioned method displays the number of interventions sent by each user per day.

>>> fig = fb.user_interventions_count_linechart()
>>> plot(fig)