You have been asked to examine a sample of network traffic to investigate suspicious activity on some of the company workstations. The company directors need to be able to understand this data.
### Load in the libraries and the data
import pandas as pd
import matplotlib.pyplot as plt
import seaborn as sns
def load_csv_data():
data = pd.read_csv('./example_data/example_pcap.csv')
return data
data = load_csv_data()
data
data['Time'] = pd.to_datetime(data['Time'])
data['Minutes'] = data['Time'].dt.minute
data
plt.figure(figsize=(20,10))
plt.plot( data['Minutes'].value_counts().sort_index() )
### INSERT YOUR CODE HERE
plt.figure(figsize=(20,10))
data['Protocol'].value_counts().plot.bar(x='Protocol')
plt.show()
plt.figure(figsize=(20,10))
plt.xticks(rotation=20)
plt.yticks(rotation=20)
plt.scatter(data['Source'], data['Destination'])
plt.show()