Module Development
By convention, each module generally has a long name (eg, One-way Anova) and a shorter acronym, (OWA). The module is generally referred to by this short acronym, and the acronym is used as the algorithm class name and its package name. Convention states that the class name for the main Algorithm implementation should be all caps, (OWA.java) whereas the packages should be lowercase (org.tigr.microarray.mev.cluster.algorithm.impl.owa.* and org.tigr.microarray.mev.cluster.gui.owa.*)
A new module requires the creation of the following components.
GUI classes:
included are all GUI components for the module, e.g. expression viewers, tables, init dialogs and **GUI.java.
-An IClusterGUI implemenation.
-An initialization dialog for parameter collection.
-Extension of base IViewer implementations for basic cluster viewers.
-Optional module specific viewers
-Optional helper classes
All GUI classes are contained in the package org.tigr.microarray.mev.cluster.gui.impl.<module-package>
source\org\tigr\microarray\mev\cluster\gui\impl
Algorithm Engine:
org.tigr.microarray.mev.cluster.algorithm.impl
This package contains all AbstractAlgorithm extensions that correspond
to module implementations. These are the classes that do the computational
work during algorithm execution. Main method, AlgorithmData execute(AlgorithmData) where the sole argument is the parameter container and the return AlgorithData has the accumulated results.
An algorithm class takes in an AlgorithmData object and returns and object of the same class back to the Module's GUI class.
source\org\tigr\microarray\mev\cluster\algorithm\impl\**.java
Parameters info:
Each module provides an html page describing the use of the module's parameters. This short tutorial is not designed to describe the algorithm in any depth, but walk a user through the types of analysis available for their data.
source\org\tigr\microarray\mev\cluster\gui\impl\dialogs\dialogHelpUtil\dialogHelpPages\**_parameters.html
To create the help window, add the appropriate module key to
source\org\tigr\microarray\mev\cluster\gui\impl\dialogs\dialogHelpUtil\HelpWindow.java
Build Script:
The MeV build script, located in the \build_script directory of the source tree needs the following edits:
1.) Change Module Selection Properties by adding:
<property name="**" value="y"/>
2.) Add algorithm dependency by adding algorithm name to:
<target name="algorithm-modules"
depends=
and
<target name="modules-only"
depends=
-note: With new toolbar layout, target order is no longer essential for correct categorizing of modules.
3.) Add build target for algorithm:
(example)
<target name="**" depends="**-GUI" if="**">
<javac debug="${debug}" target="${java.target.version}" sourcepath="" srcdir="${alg.impl.dir}" destdir="${dest.dir}">
<include name="**.java"/>
<classpath>
<pathelement location="${lib.dir}/JSciCore.jar"/>
<!-- jars to support module compilation -->
<pathelement location="${lib.dir}/mev-util.jar"/>
<pathelement location="${lib.dir}/mev-gui-impl.jar"/>
<pathelement location="${lib.dir}/mev-gui-support.jar"/>
<pathelement location="${lib.dir}/mev-algorithm-impl.jar"/>
<pathelement location="${lib.dir}/mev-algorithm-support.jar"/>
<pathelement location="${lib.dir}/mev-base.jar"/>
</classpath>
</javac>
<propertyfile file="${alg.properties.file}">
<entry key="**" value="org.tigr.microarray.mev.cluster.algorithm.impl.**"/>
</propertyfile>
</target>
4.) Add build target for GUI. Specify which Module Category (Clustering, statistics, etc.) to which the module belongs.
(example)
<target name="**-GUI">
<javac debug="${debug}" target="${java.target.version}" srcdir="${gui.impl.dir}/**" destdir="${dest.dir}">
<classpath refid="module.build.class.path"/>
</javac>
<propertyfile file="${gui.properties.file}">
<entry key="gui.names" value="**:" operation="+"/>
<entry key="**.name" value="**"/>
<entry key="**.class" value="org.tigr.microarray.mev.cluster.gui.impl.**.**GUI"/>
<entry key="**.category" value="${STATISTICS}"/>
<entry key="**.smallIcon" value="analysis.gif"/>
<entry key="**.largeIcon" value="**_button.gif"/>
<entry key="**.tooltip" value="Example Algorithm"/>
</propertyfile>
</target>
Icon
Add icon button gif to
source\org\tigr\microarray\mev\cluster\gui\impl\images
and
source\org\tigr\images
button icon is a gif 32 pixels x 32 pixels
State-saving
If the module uses only the standard viewers to display its results, no state-saving work need be done. If the module includes custom viewers, however, please consult the state-saving documentation for information on how to ensure that the new viewer will save and load completely.
Documentation
There should be a section of the MeV user manual for each module. It should describe what the module does and how to use it. Include plenty of screenshots.
If there is a paper reference for the module, add it to the MeV manual in the References section at the end and in the manual section devoted to the module. Also add the reference to the MeV page on the TM4 website. Also write a short description of the module to be included in the release notes when the new module is released with MeV.