Frequent k-mer problem

Assignment Help Database Management System
Reference no: EM131268851

Problem 1:

We return to the DNA class from Assignment 3. The most frequent k-mer problem seeks the set of substrings of length k (where integer k is an input) that occur most frequently. We add to the DNA class a most_frequent_kmers method that gets called with integer k and returns an array whose first element is the set of k-mers that occur most frequently in this DNA and whose second element is the number of times each one appears.

>> dna1 = DNA.new('ATTGATTCCG')
=> ATTGATTCCG
>> dna1.most_frequent_kmers(1)
=> [#<Set: {"T"}>, 4]
>> dna1.most_frequent_kmers(2)
=> [#<Set: {"AT", "TT"}>, 2]
>> dna1.most_frequent_kmers(3)
=> [#<Set: {"ATT"}>, 2]
>> dna1.most_frequent_kmers(4)
=> [#<set: {"ATTG", "TTGA", "TGAT", "GATT", "ATTC", "TTCC", "TCCG"}>,
1]

Attachment:- Assignment 3 problem.rar

Verified Expert

This assignment deals with the use of hashMap, set and the array in ruby. This program returns the maximum substituting occurring in the string whose length is equal to the supplied to the function.

Reference no: EM131268851

Questions Cloud

Billing function of a company : A bank has recently taken over the billing function of a company. An agreement stipulates that the bank should process 99.2% of the bills within 4 hours.
How language and literacy development is fostered : Imagine that you are asked by a new parent or family member to explain how language and literacy development is fostered in a preschool setting.
Determine the floating exchange rate : With the heavy focus on trade with China, it may be surprising to discover that Canada is the USA’s largest trading partner. Perhaps it is not the amount of trade between the US and China that is such a great concern as much as the growth of the trad..
Managing diversity and inclusion and diversity training : Explain the relationship between “managing diversity and inclusion” and “diversity training.” Which is most effective? Why
Frequent k-mer problem : The most frequent k-mer problem seeks the set of substrings of length k (where integer k is an input) that occur most frequently
Calculate the amount that amy would pay : Amy Koy met Pat Quin on September 8 at Queen Bank. After talking with Pat, Amy decided she would like to consider a $9,000 loan at 10 1/2% to be repaid on February 17 of the next year on exact interest. Calculate the amount that Amy would pay at m..
Create powerpoint presentation describing : Write an MS Word document or create a PowerPoint presentation describing:
Net income will go to federal and state taxes : US Airways has a net income before taxes of $60,000. It's expected the t45% of the net income will go to federal and state taxes. How much will US Airways have left?
Legacy system replacement baseline project plan : You are a systems analyst working for Laggard, Inc. (Laggard), a wholesale distributor of bulk vitamins and fine chemical food additives. Laggard has stayed way behind the IT industry evolutionary curve. Produce a legacy system replacement Baseline P..

Reviews

len1268851

11/7/2016 4:36:04 AM

I NEED THIS PROBLEM BY TOMORROW CAN YOU DO THAT. IF YES THEN GIVE ME THE PRICING THEN I WILL PAY. IF CANNOT BY TOMORROW THAN THANK YOU. IAM HAVING DUE BY TOMORROW EVENING SO.

Write a Review

Database Management System Questions & Answers

  Knowledge and data warehousing

Design a dimensional model for analysing Purchases for Adventure Works Cycles and implement it as cubes using SQL Server Analysis Services. The AdventureWorks OLTP sample database is the data source for you BI analysis.

  Design a database schema

Design a Database schema

  Entity-relationship diagram

Create an entity-relationship diagram and design accompanying table layout using sound relational modeling practices and concepts.

  Implement a database of courses and students for a school

Implement a database of courses and students for a school.

  Prepare the e-r diagram for the movie database

Energy in the home, personal energy use and home energy efficiency and Efficient use of ‘waste' heat and renewable heat sources

  Design relation schemas for the entire database

Design relation schemas for the entire database.

  Prepare the relational schema for database

Prepare the relational schema for database

  Data modeling and normalization

Data Modeling and Normalization

  Use cases perform a requirements analysis for the case study

Use Cases Perform a requirements analysis for the Case Study

  Knowledge and data warehousing

Knowledge and Data Warehousing

  Stack and queue data structure

Identify and explain the differences between a stack and a queue data structure

  Practice on topic of normalization

Practice on topic of Normalization

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd