Skip to content

Instantly share code, notes, and snippets.

@BenTenmann
Created December 21, 2022 12:10
Show Gist options
  • Save BenTenmann/1a9e23bc7ee671130b6e9b1ba7f0b0b5 to your computer and use it in GitHub Desktop.
Save BenTenmann/1a9e23bc7ee671130b6e9b1ba7f0b0b5 to your computer and use it in GitHub Desktop.
import pandas as pd
import setriq
df = pd.read_csv("vdjdb.csv", names=["cdr3", "epitope", "gene", "species"])
lev = setriq.Levenshtein(return_squareform=True)
# limit to 1000 to avoid explosion in time-taken
D = lev(df["cdr3"].iloc[:1000])
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment