public void TestIsMutationOneIgnoreDeamidated() { int site = -1; //N->D Assert.IsTrue(MutationUtils.IsMutationOne2("ABNDEIR", "ABDDEIR", ref site, false, false, false)); //N->D Assert.IsFalse(MutationUtils.IsMutationOne2("ABNDEIR", "ABDDEIR", ref site, false, true, false)); //Q->E Assert.IsTrue(MutationUtils.IsMutationOne2("ABQDEIR", "ABEDEIR", ref site, false, false, false)); //Q->E Assert.IsFalse(MutationUtils.IsMutationOne2("ABQDEIR", "ABEDEIR", ref site, false, true, false)); //N->D Assert.IsTrue(MutationUtils.IsMutationOneIL2("ABNDEIR", "ABDDELR", ref site, false, false, false)); //N->D Assert.IsFalse(MutationUtils.IsMutationOneIL2("ABNDEIR", "ABDDELR", ref site, false, true, false)); //Q->E Assert.IsTrue(MutationUtils.IsMutationOneIL2("ABQDEIR", "ABEDELR", ref site, false, false, false)); //Q->E Assert.IsFalse(MutationUtils.IsMutationOneIL2("ABQDEIR", "ABEDELR", ref site, false, true, false)); }
public void TestIsMutationOneIgnoreNTerminal() { int site = -1; Assert.IsTrue(MutationUtils.IsMutationOne2("ABCDEIR", "BBCDEIR", ref site, false, false, false)); Assert.IsFalse(MutationUtils.IsMutationOne2("ABCDEIR", "BBCDEIR", ref site, true, false, false)); Assert.IsTrue(MutationUtils.IsMutationOneIL2("ABCDEIR", "BBCDELR", ref site, false, false, false)); Assert.IsTrue(MutationUtils.IsMutationOneIL2("ABCDELR", "BBCDEIR", ref site, false, false, false)); Assert.IsFalse(MutationUtils.IsMutationOneIL2("ABCDELR", "BBCDEIR", ref site, true, false, false)); }
private bool FindMutationOneType1(string pnovoseq, ref string source, ref int site) { if (!miss0group.ContainsKey(pnovoseq.Length)) { return(false); } var lst = miss0group[pnovoseq.Length]; foreach (var m in lst) { if (MutationUtils.IsMutationOne2(m, pnovoseq, ref site, options.IgnoreNtermMutation, options.IgnoreDeamidatedMutation, options.IgnoreMultipleNucleotideMutation)) { source = miss0[m]; //Console.WriteLine("TYPE1 : {0} ==> {1}", m, pnovoseq); return(true); } } return(false); }