# HG changeset patch # User davidvanzessen # Date 1389177898 18000 # Node ID a7fe6f068f8379a3713a56158ba3073a36d1999f # Parent a43100e5d0327ae577bd7a61a7292386b43fca21 Uploaded diff -r a43100e5d032 -r a7fe6f068f83 imgtconvert.py --- a/imgtconvert.py Tue Dec 10 07:55:34 2013 -0500 +++ b/imgtconvert.py Wed Jan 08 05:44:58 2014 -0500 @@ -132,7 +132,7 @@ tmp = tmp.replace("null", "Out-of-frame") tmp = tmp.replace("out-of-frame", "Out-of-frame") outFrame["VDJ Frame"] = tmp -outFrame["CDR3 Length"] = outFrame["CDR3 Seq DNA"].map(str).map(len) +outFrame["CDR3 Length DNA"] = outFrame["CDR3 Seq DNA"].map(str).map(len) safeLength = lambda x: len(x) if type(x) == str else 0 outFrame = outFrame[(outFrame["CDR3 Seq DNA"].map(safeLength) > 0) & (outFrame["Top V Gene"] != "NA") & (outFrame["Top D Gene"] != "NA") & (outFrame["Top J Gene"] != "NA")] #filter out weird rows? -outFrame.to_csv(outFile, sep="\t", index=False) \ No newline at end of file +outFrame.to_csv(outFile, sep="\t", index=False, index_label="index") \ No newline at end of file