MATLAB Answers

Dna encoding rule1

1 view (last 30 days)
lilly lord
lilly lord on 17 Jun 2020
Commented: lilly lord on 18 Jun 2020
Hi I have an issue storing the DNA sequenc using for loop. If some one can help me.
x=[2 34 50 21];
[m n]=size(x);
mn=m*n;
P= [];
for i=1:length(x)
Q= convert_to_dna2(x(i));
P=Q(i);
end
output is 'GGGA'%error
requirment CAAACACACATAGGGA
  2 Comments
lilly lord
lilly lord on 18 Jun 2020
The problem has resolved.
for i=1:length(x)
Q= convert_to_dna2(x(i));
Q= [Q convert_to_dna2(x(i))];%concatinate the sequence
end
Thanks for your reply

Sign in to comment.

Answers (0)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!