Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

MATLAB, please help! DNA N-Gram Distribution (string scalar) In DNA analysis unique sequences of three bases need to be identified any point in the gene

MATLAB, please help!

image text in transcribed

image text in transcribed

image text in transcribed

DNA N-Gram Distribution (string scalar) In DNA analysis unique sequences of three bases need to be identified any point in the gene sequence. The bases could be combinations of either T, C, A or G. Write a function nGramFrequency to identify the unique n-grams (n letter sequence) in a given string scalar stringln and the number of times an n-gram occurs. In addition to the input stringln, the number n speficies the length of the n-gram. The identified unique n-gram sequences should be sorted alphabetically. The outputs should be empty if i) there are no n-grams, i) the input is not a string scalar, or ii) the length of the ngram is not a positive integer. Restriction: The nGramFrequency function should use the internal function extractBetween For example "AACTGAACG";lengthnGram-3; >>uniquegrams, count] uniquegrams- nGramFrequency (s,lengthnGram) 1x6 string array "AAC" "ACG""ACT""CTG" "GAA" TGA count 1 The unique 3-grams are "AAC" "ACG" "ACT" "CTG" "GAA" "TGA". The sequence AAC that appears twice, and all appear once >>s"AACTGAACG";lengthnGram-10; [uniquegrams, count] uniquegrams- nGramFrequency (s, lengthnGram) count Il

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_2

Step: 3

blur-text-image_3

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

Practical Issues In Database Management A Refernce For The Thinking Practitioner

Authors: Fabian Pascal

1st Edition

0201485559, 978-0201485554

More Books

Students also viewed these Databases questions

Question

LO1 Understand risk management and identify its components.

Answered: 1 week ago