필터 지우기
필터 지우기

gene contains only ATGC

조회 수: 2 (최근 30일)
Oded Scharf
Oded Scharf 2018년 6월 10일
답변: Rik 2018년 6월 10일
I have a list of genes (strings of letters) and I want delete the ones that has letters other than ATGC (N for example). how can I do it?
Thank you!

채택된 답변

Rik
Rik 2018년 6월 10일
You just want to remove the invalid letters? The code below will do that. If you want to check if a gene string is invalid you can check that with any(~L).
gene='ATTCAGN';
L=ismember(gene,'ATGC');
gene=gene(L);

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Import, Export, and Conversion에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by