I created a key logging program in python that records the time and date of every key I type into a text document. I want to create a bar graph using matplotlib that reads the text document and on the x-axis has every letter I typed and on the y-axis is the number of types I typed each letter. Here is my code:
import matplotlib.pyplot as plt
import pandas as pd
df = pd.read_csv('keylogtest.txt', delim_whitespace=True, names=('date', 'time', 'key'))
print(df.head())
The code prints out the following:
date time key
0 2020-06-16 20:47:46,054: 't'
1 2020-06-16 20:47:46,124: 'h'
2 2020-06-16 20:47:46,230: 'i'
3 2020-06-16 20:47:46,292: 's'
4 2020-06-16 20:47:46,434: Key.space
I'm not sure how to continue from here. Does anyone have any ideas on what I could do?