dna-sequence

Python-script, which should translate 1000 DNA-Sequences to proteins by 1152 different codontables, don't work

怎甘沉沦 提交于 2019-12-11 04:33:05
问题 Now I'm working on bioinformatics project for my diploma work. I have written Python-script, which should translate the list of strings of 1000 DNA-Sequences to proteins by 1152 different codontables (genetics codes). This codontables are contained in a list of dictionaries, which were received by shuffling of keys and values (codons and amino acids). I want, what this script translates 1000 Sequences in 1152 ways in one go mileage in IPython console or just in Python-3.6 IDLE. This script

DNA to RNA and Getting Proteins with Perl

二次信任 提交于 2019-12-10 20:33:11
问题 I am working on a project(I have to implement it in Perl but I am not good at it) that reads DNA and finds its RNA. Divide that RNA's into triplets to get the equivalent protein name of it. I will explain the steps: 1) Transcribe the following DNA to RNA, then use the genetic code to translate it to a sequence of amino acids Example: TCATAATACGTTTTGTATTCGCCAGCGCTTCGGTGT 2) To transcribe the DNA, first substitute each DNA for it’s counterpart (i.e., G for C, C for G, T for A and A for T):

How to do sub-sorting in python?

丶灬走出姿态 提交于 2019-12-10 11:42:50
问题 Many thanks to the SO community for helping me with the previous problems I had encountered. Love the help here! I have yet another problem now. I have a flat list of DNA sequences that have associated "Construct Number" and "Part Number. As things stand right now, from my previous code, I have it as a csv file which I open up, read in, and import as a list of dictionary objects. Everything is sorted by "Construct Number" already, but I need to then sort by "Part Number". (It's sort of like

Converting nucleotides to amino acids using JavaScript

最后都变了- 提交于 2019-12-10 09:25:15
问题 I'm creating a Chrome Extension that converts a string of nucleotides of length nlen into the corresponding amino acids. I've done something similar to this before in Python but as I'm still very new to JavaScript I'm struggling to translate that same logic from Python to JavaScript. The code I have so far is the below: function translateInput(n_seq) { // code to translate goes here // length of input nucleotide sequence var nlen = n_seq.length // declare initially empty amino acids string

Translation DNA to Protein

瘦欲@ 提交于 2019-12-09 06:47:41
问题 I am a biology graduate student and I taught myself a very limited amount of python in the past few months to deal with some data I have. I am not asking for homework help, this is for a research project. With this code I intend to take a portion of a string called sequence, between: find the start site of "protein translation," or the first occurrence of ATG (biological term is start codon), then the first occurrence of TAA (stop codon). Then the function translate_dna() should, for every

I need search a pattern in a header line of my file and concatenates the next line with Perl

主宰稳场 提交于 2019-12-08 08:43:11
问题 My multi-fasta archive is in this format: >miRNA65 dvex2345 CGATGCTAGATGCTATGACAACGATGCCTCG-G >miRNA60 dvex1234 T-TAA-ACTCATCATCATCATACTCATCATCATCATCAGCATATTAACAAG >miRNA65 dvex2345 T-TAA-ACTTATCATCATCATACTCATCATCATCATCAGCATATTAACAAG I am new in Perl and I need to search the equals '> lines' and concatenate the next line to join the sequence. I'm expecting the following output for the above file: >miRNA60 dvex1234 T-TAA-ACTCATCATCATCATACTCATCATCATCATCAGCATATTAACAAG >miRNA65 dvex2345 T-TAA

Use Python to extract Branch Lengths from Newick Format

妖精的绣舞 提交于 2019-12-07 05:04:10
问题 I have a list in python consisting of one item which is a tree written in Newick Format, as below: ['(BMNH833953:0.16529463651919140688,(((BMNH833883:0.22945757727367316336,(BMNH724182a:0.18028180766761139897,(BMNH724182b:0.21469677818346077913,BMNH724082:0.54350916483644962085):0.00654573856803835914):0.04530853441176059537):0.02416511342888815264,(((BMNH794142:0.21236619242575086042,(BMNH743008:0.13421900772403019819,BMNH724591:0.14957653992840658219):0.02592135486124686958):0

Optimal way to cluster set of strings with hamming distance [duplicate]

隐身守侯 提交于 2019-12-06 16:46:29
问题 This question already has answers here : Fast computation of pairs with least hamming distance (1 answer) Finding Minimum hamming distance of a set of strings in python (4 answers) Closed 4 years ago . I have a database with n strings (n > 1 million), each string has 100 chars, each char is either a , b , c or d . I would like to find the closest strings for each one , closest defines as having the smallest hamming distance . I would like to find the k-nearest strings for each one (k < 5).

Processing a sub-list of variable size within a larger list

不羁的心 提交于 2019-12-06 16:07:52
I'm a biological engineering PhD student here trying to self-learn Python programming for use in automating a part of my research, but I've ran into a problem with processing sub-lists within a bigger list that I can't seem to solve. Basically, the goal of what I'm trying to do is write a small script that will process a CSV file containing a list of plasmid sequences that I'm building using various DNA assembly methods, and then spit out the primer sequences that I need to order in order to build the plasmid. Here's the scenario that I'm dealing with: When I want to build a plasmid, I have to

Converting nucleotides to amino acids using JavaScript

旧巷老猫 提交于 2019-12-05 18:01:48
I'm creating a Chrome Extension that converts a string of nucleotides of length nlen into the corresponding amino acids. I've done something similar to this before in Python but as I'm still very new to JavaScript I'm struggling to translate that same logic from Python to JavaScript. The code I have so far is the below: function translateInput(n_seq) { // code to translate goes here // length of input nucleotide sequence var nlen = n_seq.length // declare initially empty amino acids string var aa_seq = "" // iterate over each chunk of three characters/nucleotides // to match it with the