-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMotif.java
More file actions
34 lines (25 loc) · 720 Bytes
/
Copy pathMotif.java
File metadata and controls
34 lines (25 loc) · 720 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
package bioinformatics;
/*
import java.io.BufferedReader;
import java.io.FileReader;
import java.io.IOException;*/
public class Motif { /*
public static void main(String[] args) throws IOException {
BufferedReader br = new BufferedReader( new FileReader( args[0]));
Motif motif_dna = new Motif();
String lines ;
while( (lines = br.readLine()) != null ) {
if ( lines.startsWith(">")) {
continue ;
}
else {
// I will call Motif method here
motif_dna.motif(lines);
}
}br.close();
}*/
public void motif(String lines ) {
System.out.println("Motif: " + lines.contains("AAA"));
System.out.println("Motif position " + lines.indexOf("AAA"));
}
}