-
Notifications
You must be signed in to change notification settings - Fork 305
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add single file argument to count kmers.
- Loading branch information
Showing
6 changed files
with
148 additions
and
15 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
GGGGGGGGAAAAAAAAAAGGG 1 | ||
AAAAAAAAAAAAAAAAAAAAG 1 | ||
GGGGAAAAAAAAAAGGGGGGG 1 | ||
GGGGGGGAAAAAAAAAAGGGG 1 | ||
AGGGGGGGGGGAAAAAAAAAA 2 | ||
AAAAAAAAAAAAAGGGGGGGG 1 | ||
GGGGGAAAAAAAAAAGGGGGG 1 | ||
GAAAAAAAAAAAAAAAAAAAA 1 | ||
AAAAAAAAAAAAAAAGGGGGG 1 | ||
GGGGGGGGGAAAAAAAAAAAA 1 | ||
AAAAAAAAAAAAAAAAAAAGG 1 | ||
AAAGGGGGGGGGGAAAAAAAA 2 | ||
GGGGGGGGAAAAAAAAAAAAA 1 | ||
GGAAAAAAAAAAGGGGGGGGG 1 | ||
GGGGGGAAAAAAAAAAGGGGG 1 | ||
AAAAGGGGGGGGGGAAAAAAA 2 | ||
GGGGGGGAAAAAAAAAAAAAA 1 | ||
AAAAAAAAAAAAAAGGGGGGG 1 | ||
GGGGGGGGGGAAAAAAAAAAG 1 | ||
AAAAAAAAAGGGGGGGGGGAA 2 | ||
AAGGGGGGGGGGAAAAAAAAA 2 | ||
GGAAAAAAAAAAAAAAAAAAA 1 | ||
AAAAAAAAAAAAAAAAGGGGG 1 | ||
AAAAAAAAAAAGGGGGGGGGG 1 | ||
AAAAAAAAAAAAAAAAAGGGG 1 | ||
GGGGGGGGGGAAAAAAAAAAA 1 | ||
GGGAAAAAAAAAAAAAAAAAA 1 | ||
GGGGGGGGGAAAAAAAAAAGG 1 | ||
GAAAAAAAAAAGGGGGGGGGG 1 | ||
AAAAAAGGGGGGGGGGAAAAA 2 | ||
AAAAAGGGGGGGGGGAAAAAA 2 | ||
GGGAAAAAAAAAAGGGGGGGG 1 | ||
GGGGGAAAAAAAAAAAAAAAA 1 | ||
AAAAAAAAAAAAAAAAAAAAA 1050 | ||
AAAAAAAAAAAAAAAAAAGGG 1 | ||
GGGGGGAAAAAAAAAAAAAAA 1 | ||
AAAAAAAAGGGGGGGGGGAAA 2 | ||
GGGGAAAAAAAAAAAAAAAAA 1 | ||
AAAAAAAGGGGGGGGGGAAAA 2 | ||
AAAAAAAAAAGGGGGGGGGGA 2 | ||
AAAAAAAAAAAAGGGGGGGGG 1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
ACACACAC 1 | ||
ACACACACACAC 1 | ||
ACACACACAC 3 |
31 changes: 31 additions & 0 deletions
31
adam-cli/src/test/scala/org/bdgenomics/adam/cli/CountReadKmersSuite.scala
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
/** | ||
* Licensed to Big Data Genomics (BDG) under one | ||
* or more contributor license agreements. See the NOTICE file | ||
* distributed with this work for additional information | ||
* regarding copyright ownership. The BDG licenses this file | ||
* to you under the Apache License, Version 2.0 (the | ||
* "License"); you may not use this file except in compliance | ||
* with the License. You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
package org.bdgenomics.adam.cli | ||
|
||
import org.bdgenomics.adam.ds.ADAMContext._ | ||
import org.bdgenomics.adam.util.ADAMFunSuite | ||
|
||
class CountReadKmersSuite extends ADAMFunSuite { | ||
sparkTest("count kmers to single file") { | ||
val inputPath = copyResource("sorted.sam") | ||
val actualPath = tmpFile("sorted.counts.txt") | ||
val expectedPath = copyResource("sorted.counts.txt") | ||
CountReadKmers(Array("-single", inputPath, actualPath, "21")).run(sc) | ||
checkFiles(expectedPath, actualPath) | ||
} | ||
} |
31 changes: 31 additions & 0 deletions
31
adam-cli/src/test/scala/org/bdgenomics/adam/cli/CountSliceKmersSuite.scala
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
/** | ||
* Licensed to Big Data Genomics (BDG) under one | ||
* or more contributor license agreements. See the NOTICE file | ||
* distributed with this work for additional information | ||
* regarding copyright ownership. The BDG licenses this file | ||
* to you under the Apache License, Version 2.0 (the | ||
* "License"); you may not use this file except in compliance | ||
* with the License. You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
package org.bdgenomics.adam.cli | ||
|
||
import org.bdgenomics.adam.ds.ADAMContext._ | ||
import org.bdgenomics.adam.util.ADAMFunSuite | ||
|
||
class CountSliceKmersSuite extends ADAMFunSuite { | ||
sparkTest("count slice kmers to single file") { | ||
val inputPath = copyResource("artificial.fa") | ||
val actualPath = tmpFile("artificial.counts.txt") | ||
val expectedPath = copyResource("artificial.counts.txt") | ||
CountSliceKmers(Array("-single", inputPath, actualPath, "21")).run(sc) | ||
checkFiles(expectedPath, actualPath) | ||
} | ||
} |