Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

A k-mer is a string of length k. We define Count(Text, Pattern) as the number of times that a k-mer Pattern appears as a substring

image text in transcribed
A k-mer is a string of length k. We define Count(Text, Pattern) as the number of times that a k-mer Pattern appears as a substring of Text. For example, Count'ACAACTATGCATACTATCGGGAACTATCCT", "ACTAT') = 3. We note that count(CGATATATCCATAGCGATATATACCATAG, "ATATA") is equal to 3 (not 2) since we should account for overlapping occurrences of Pattern in Text. To compute Count(Text, Pattern), our plan is to "slide a window" down Text, checking whether each k-mer substring of Text matches Pattern. We will therefore refer to the k-mer starting at position i of Text as Texti, k). Throughout this example, we will often use 1-based indexing, meaning that we count starting at 1 instead of 0. In this case, Text begins at position 1 and ends at position Text (Text denotes the number of symbols in Text). Note that the last k- mer of Text begins at position (Text-k+1, eg.. the last 3-mer of GACCATACTG starts at position 10 - 3+1 -8. Please implement the Count (Text,Pattern) function. Hint: You can use the stremp(str1, str2) function of Matlab. Fonksiyonunuzun rnek kullanm aada verilmitir. Ltfen yazl ilevinizi bir m dosyas olarak ykleyin (m dos olarak ykleyin). Ilevinizi test etmek iin aadaki Metinleri kullanabilirsiniz: Test = 'CGATATATCCATAGCGATATATACCATAG: Test = 'ACAACTATGCATACTATCGGGAACTATCCT": rnek kullanm: >>> Count('CONTATATOCNTAGCGATATNIACCATAG TATATA')

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Oracle Autonomous Database In Enterprise Architecture

Authors: Bal Mukund Sharma, Krishnakumar KM, Rashmi Panda

1st Edition

1801072248, 978-1801072243

More Books

Students also viewed these Databases questions