Skip to content

Instantly share code, notes, and snippets.

View wei2912's full-sized avatar

Ng Wei En wei2912

View GitHub Profile
@wei2912
wei2912 / plotgraph.py
Last active January 3, 2017 10:44 — forked from fishnsotong/plotgraph.py
Making a scatter plot in python by importing data from a csv file.
import numpy as np
import matplotlib.pyplot as plt
# importing data from csv file
xs, ys, zs = np.loadtxt("data.txt", unpack=True, delimiter=",", dtype=float, skiprows=0)
# labels
plt.xlabel("No. of PT-CT Pairs per Distinguisher")
plt.ylabel("lg2(T(N))")
plt.title("Lower Bound on Time Complexity of Single and Double Distinguisher Attack")