diff --git a/Schrick-Noah_CS-6643_Lab-9.R b/Schrick-Noah_CS-6643_Lab-9.R index e69de29..f1cb545 100644 --- a/Schrick-Noah_CS-6643_Lab-9.R +++ b/Schrick-Noah_CS-6643_Lab-9.R @@ -0,0 +1,33 @@ +# Lab 9 for the University of Tulsa's CS-6643 Bioinformatics Course +# Pairwise Sequence Alignment with Dynamic Programming +# Professor: Dr. McKinney, Fall 2022 +# Noah L. Schrick - 1492657 + +## Set Working Directory to file directory - RStudio approach +setwd(dirname(rstudioapi::getActiveDocumentContext()$path)) + + +#### Part A: Specifying the Input +## Score Rules and Seqs +x_str <- "ATAC" # side sequence +y_str <- "GTGTAC" # top sequence +match_score <- 3 +mismatch_score <- -1 +gap_penalty <- -4 + +## Substitution Matrix +dna.letters<-c("A","C","G","T") +num.letters <- length(dna.letters) +S<-data.frame(matrix(0,nrow=num.letters,ncol=num.letters)) # data frame +rownames(S)<-dna.letters; colnames(S)<-dna.letters +for (i in 1:4){ + for (j in 1:4){ + if(dna.letters[i]==dna.letters[j]){ + S[i,j]<- match_score + } + else{ + S[i,j]<- mismatch_score + } + } +} + diff --git a/Schrick-Noah_CS-6643_Lab-9.docx b/Schrick-Noah_CS-6643_Lab-9.docx index 6d107ca..8c8a173 100644 Binary files a/Schrick-Noah_CS-6643_Lab-9.docx and b/Schrick-Noah_CS-6643_Lab-9.docx differ