public class RemoveLowOtuCounts extends OtuCountModule implements ApiModule
BLJ_OPTIONSGZIP_EXT, LOG_EXT, PDF_EXT, RETURN, SH_EXT, TAB_DELIM, TSV_EXT, TXT_EXTLOG_DIR, MAIN_SCRIPT_PREFIX, NO_VERSION, OUTPUT_DIR, RES_DIR, TEMP_DIR| Constructor and Description |
|---|
RemoveLowOtuCounts() |
| Modifier and Type | Method and Description |
|---|---|
void |
checkDependencies()
Validate module dependencies:
Require
Config. exists
Require Config. is positive integer
Require Config. is positive integer
Verify Config. is positive integer if set
Start the AWS DB sync to S3 if a novel DB has been configure and
"aws.copyDbToS3" is enabled
|
void |
cleanUp()
Update
ParserModuleImpl OTU_COUNT field name. |
String |
getCitationString()
At a minimum, this should return the name and/or url for the wrapped tool.
|
String |
getDescription()
Briefly describe what this module does.
|
String |
getSummary()
Produce summary message with min, max, mean, and median number of reads.
|
Boolean |
isValidProp(String property)
Tests to see if the value val is valid for property prop; primarily tests format.
|
protected void |
logLowCountOtus(TreeMap<String,TreeSet<String>> lowCountOtus)
Save a list of low count OTUs to the module temp directory.
|
protected TreeMap<String,TreeSet<String>> |
removeLowOtuCounts(TreeMap<String,TreeMap<String,Long>> sampleOtuCounts)
Remove OTUs below the
Config. |
void |
runModule()
This method executes the modules primary Java routine.
|
getInputFiles, isOtuModule, isValidInputModulebuildScript, executeTask, getDockerImageName, getDockerImageOwner, getDockerImageTag, getWorkerScriptFunctions, markStatus, moduleComplete, moduleFailed, runBioLockJ_CMDbuildScriptForPairedReads, getJobParams, getMainScript, getRuntimeParams, getScriptDir, getScriptErrors, getTimeout, hasScriptsaddGeneralProperty, addGeneralProperty, addGeneralProperty, addNewProperty, addNewProperty, cacheInputFiles, compareTo, equals, findModuleInputFiles, getAlias, getDescription, getDetails, getFileCache, getID, getLogDir, getMenuPlacement, getMetadata, getModuleDir, getOutputDir, getPostRequisiteModules, getPreRequisiteModules, getPropDefault, getPropDescMap, getPropType, getPropTypeMap, getResourceDir, getTempDir, getTitle, hashCode, init, listProps, setAlias, toStringclone, finalize, getClass, notify, notifyAll, wait, wait, waitgetDescription, getDetails, getMenuPlacement, getPropType, getTitle, listPropsexecuteTask, getAlias, getDockerImageName, getDockerImageOwner, getDockerImageTag, getID, getInputFiles, getLogDir, getMetadata, getModuleDir, getOutputDir, getPostRequisiteModules, getPreRequisiteModules, getPropDefault, getResourceDir, getTempDir, init, isValidInputModule, setAlias, versionbuildScriptForPairedReads, getJobParams, getMainScript, getScriptDir, getScriptErrors, getTimeoutpublic void checkDependencies()
throws Exception
ScriptModuleImplConfig. exists
Config. is positive integer
Config. is positive integer
Config. is positive integer if set
checkDependencies in interface BioModulecheckDependencies in class ScriptModuleImplException - thrown if missing or invalid dependencies are foundpublic Boolean isValidProp(String property) throws Exception
ApiModuleBioModule.checkDependencies(). Using switch/case or a stack of if/else is recommended.
Within each case, call any/all method that is used by this module to access the value from the config file,
leveraging the checks in the Config.get* methods.
This method should never actually return false. If the value is not valid, it should throw an exception that
includes a helpful message about whats not valid. As part of a throwable, that message is passed along to
wherever the call started. Any time that "false" is actually the desired form, this method should be wrapped in
a try/catch.isValidProp in interface ApiModuleisValidProp in class ScriptModuleImplExceptionpublic void cleanUp()
throws Exception
ParserModuleImpl OTU_COUNT field name.cleanUp in interface BioModulecleanUp in class BioModuleImplException - thrown if any runtime error occurspublic String getSummary() throws Exception
getSummary in interface BioModulegetSummary in class ScriptModuleImplException - if any error occurspublic void runModule()
throws Exception
JavaModulerunModule in interface JavaModulerunModule in class JavaModuleImplException - thrown if any runtime error occursprotected void logLowCountOtus(TreeMap<String,TreeSet<String>> lowCountOtus) throws Exception
lowCountOtus - TreeMap(sampleId, TreeSet(OTU)) of OTUs found in too few samplesException - if errors occurprotected TreeMap<String,TreeSet<String>> removeLowOtuCounts(TreeMap<String,TreeMap<String,Long>> sampleOtuCounts) throws Exception
Config.sampleOtuCounts - TreeMap(SampleId, TreeMap(OTU, count)) OTU counts for every sampleException - if errors occurpublic String getDescription()
ApiModulegetDetails.getDescription in interface ApiModulepublic String getCitationString()
ApiModulegetCitationString in interface ApiModule