<?xml version="1.0" encoding="UTF-8"?>
<plugin
  name="%pluginName"
  id="biouml.plugins.microarray"
  version="0.8.6"  
  provider-name="%providerName"
  class="biouml.plugins.microarray.MicroarrayPlugin"
>
  
  <requires>
    <import plugin="biouml.workbench"/>
    <import plugin="com.beanexplorer"/>
    <import plugin="org.apache.log4j"/>
    <import plugin="ru.biosoft.access"/>
    <import plugin="ru.biosoft.table"/>
    <import plugin="ru.biosoft.math"/>
    <import plugin="ru.biosoft.workbench"/>
    <import plugin="com.developmentontheedge.util"/>
    <import plugin="org.mozilla.javascript"/>
    <import plugin="ru.biosoft.plugins.javascript"/>
    <import plugin="jama"/> 
    <import plugin="ru.biosoft.analysis"/>
    <import plugin="biouml.plugins.optimization"/>
	<import plugin="biouml.plugins.creasemarks"/>
  </requires>
  
  <runtime>
    <library name="microarray.jar">
      <export name="*"/>
    </library>
  </runtime>
  
  <extension-point name="%genehub" id="genehub"/>

  <extension id="microarray actions provider" point="ru.biosoft.access.repositoryActionsProvider"> 
      <repositoryActionsProvider class="biouml.plugins.microarray.RepositoryActionsProvider"/> 
  </extension>
  
  <extension id="microarray view" point="biouml.workbench.diagramViewPart"> 
      <diagramViewPart 
        class="biouml.plugins.microarray.MicroarrayViewPart"
        Name="Microarray"
        ShortDescription="Microarray pane"
      /> 
  </extension> 
  
  <extension id="microarray columns" point="biouml.workbench.diagramViewPart"> 
      <diagramEditorPart 
        class="biouml.plugins.microarray.editors.ColumnsViewPart" 
        Name="Columns"
        ShortDescription="Columns"
        Priority = "1.1"
      /> 
  </extension>
  
  <extension id="microarray filters" point="biouml.workbench.diagramViewPart"> 
      <diagramEditorPart 
        class="biouml.plugins.microarray.editors.FilterViewPart" 
        Name="Filters"
        ShortDescription="Filters"
        Priority = "1.4"
      /> 
  </extension>
  
  <extension id="microarray samples" point="biouml.workbench.diagramViewPart"> 
      <diagramEditorPart 
        class="biouml.plugins.microarray.editors.SamplesViewPart" 
        Name="Samples"
        ShortDescription="Samples"
        Priority = "1.2"
      /> 
  </extension>
  
  <extension id="microarray sample groups" point="biouml.workbench.diagramViewPart"> 
      <diagramEditorPart 
        class="biouml.plugins.microarray.editors.GroupsViewPart" 
        Name="Groups"
        ShortDescription="Groups"
        Priority = "1.3"
      /> 
  </extension>

  <extension id="SifImporter" point="biouml.workbench.diagramImport"> 
     <import 
        format="SIF"
        importer="biouml.plugins.microarray.SifImporter"
        description="Import SIF diagram"
     /> 
  </extension> 

  <extension id="table document factory" point="ru.biosoft.workbench.documentFactory"> 
      <documentFactory 
        class="biouml.plugins.microarray.document.TableFactory"
        key="TableFactory"
      /> 
  </extension>
  
  <extension id="microarray" point="ru.biosoft.plugins.javascript.hostObject"> 
    <hostObject name="microarray" class="biouml.plugins.microarray.javascript.JavaScriptAnalysis" >
        <doc description="Facade for data-manipulations">
        <function name="hypergeom" description="Performs hypergemotrical analysis of TableExperiment">
            <argument name="experiment" type="biouml.standard.type.TableExperiment" obligatory="true" description="experiment for analysis" /> 
            <argument name="outputName" type="String" obligatory="true" description="name for output TableExperiment" /> 
            <argument name="outputType" type="String" obligatory="true" description="type for output data. Can be 'up', 'down' and 'all' " /> 
            <argument name="columns" type="String" obligatory="true" description="columns to include in analysis. Example of usage: '1,3,5,6-8,Column10,Groupname5'" /> 
            <argument name="pvalue" type="double" obligatory="true" description="threshold for output data (will be outputed only scores with lesser P-value)" /> 
            <argument name="bv" type="int" obligatory="true" description="boundary value, analysis checks if genes expressions deviates from bv because of random reasons" /> 
            <argument name="isDetailed" type="boolean" obligatory="true" description="if true output detalied information about clones else output brief information about genes" /> 
            <argument name="isCalculatedFDR" type="boolean" obligatory="true" description="if true also calculates False Discovery Rate" /> 
            <returns type="TableExperiment" description="Contains scores" /> 
         </function>
         
         <function name="hypergeom1" description="Performs hypergemotrical analysis of TableExperiment. Most parameters are set by default: P-value=0.01, bv=1, outputType='all', isDetailed=false, isCalculatingFDR=false">
            <argument name="experiment" type="biouml.standard.type.TableExperiment" obligatory="true" description="experiment for analysis" /> 
            <argument name="outputName" type="String" obligatory="true" description="name for output TableExperiment" /> 
            <returns type="TableExperiment" description="Contains scores" /> 
         </function>

        <function name="meta" description="Performs meta-analysis of TableExperiments">
        <argument name="experiment" type="biouml.standard.type.TableExperiment" obligatory="true" description="experiment for analysis" /> 
            <argument name="outputName" type="String" obligatory="true" description="name for output TableExperiment" /> 
            <argument name="outputType" type="String" obligatory="true" description="type for genes in output. Can be 'up', 'down' and 'all' " /> 
            <argument name="pvalue" type="double" obligatory="true" description="threshold for output data (will be outputed only scores with lesser P-value)" />  
            <returns type="TableExperiment" description="Contains metascores" /> 
         </function>
         
         <function name="meta1" description="Performs meta-analysis of TableExperiments with default P-value 0.01" >
         <argument name="experiment" type="biouml.standard.type.TableExperiment" obligatory="true" description="experiment for analysis" /> 
            <argument name="outputName" type="String" obligatory="true" description="name for output TableExperiment" /> 
            <argument name="outputType" type="String" obligatory="true" description="type for genes in output. Can be 'up', 'down' and 'all' " /> 
            <returns type="TableExperiment" description="Contains metascores" /> 
         </function>
         
         <function name="twoSample" description="Performs degenerate hypergeometric analysis of only one column from TableExperiment">
             <argument name="experiment" type="biouml.standard.type.TableExperiment" obligatory="true" description="experiment for analysis" /> 
            <argument name="outputName" type="String" obligatory="true" description="name for output TableExperiment" /> 
            <argument name="outputType" type="String" obligatory="true" description="Type for genes in output. Can be 'up', 'down' and 'all' " /> 
            <argument name="column" type="String" obligatory="true" description="column to include in analysis. Must contain only one column. Examples of usage: '1','Column10','Groupname5'" /> 
            <argument name="control" type="String" obligatory="true" description="control group for analysis. Example of usage: '1,3,5,6-8,Column10,Groupname5'" /> 
            <argument name="pvalue" type="double" obligatory="true" description="threshold for output data (will be outputed only scores with lesser P-value)" />  
            <argument name="isCalculatedFDR" type="boolean" obligatory="true" description="if true also calculates False Discovery Rate" /> 
            <returns type="TableExperiment" description="contains scores" /> 
         </function>
         
          <function name="twoSample1" description="Performs degenerate hypergeometric analysis of TableExperiments (only one column) with P-value 0.01">
             <argument name="experiment" type="biouml.standard.type.TableExperiment" obligatory="true" description="experiment for analysis" /> 
            <argument name="outputName" type="String" obligatory="true" description="name for output TableExperiment" /> 
            <argument name="outputType" type="String" obligatory="true" description="type for genes in output. Can be 'up', 'down' and 'all' " /> 
            <returns type="TableExperiment" description="contains scores" /> 
         </function>


         <function name="linearRegress" description="Performs linear regression analysis of TableExperiments">
             <argument name="experiment" type="biouml.standard.type.TableExperiment" obligatory="true" description="experiment for analysis" /> 
            <argument name="outputName" type="String" obligatory="true" description="name for output TableExperiment" /> 
            <argument name="columns" type="String" obligatory="true" description="columns to include in analysis. Example of usage: '1,3,5,6-8,Column10,Groupname5'" /> 
            <argument name="timePoints" type="String" obligatory="true" description="time points for regression. Amount of time points must be equal to amount of columns. Example: '2,4,6,8,10,12'" /> 
            <argument name="pvalue" type="double" obligatory="true" description="threshold for output data (will be outputed only scores with lesser P-value)" />  
            <argument name="isCalculatedFDR" type="boolean" obligatory="true" description="if true also calculates False Discovery Rate" /> 
            <returns type="TableExperiment" description="contains scores and regression parameters" /> 
         </function>

        <function name="linearRegress1" description="Performs linear regression analysis of TableExperiments with P-value 0.01">
             <argument name="experiment" type="biouml.standard.type.TableExperiment" obligatory="true" description="experiment for analysis" /> 
            <argument name="outputName" type="String" obligatory="true" description="name for output TableExperiment" /> 
            <argument name="columns" type="String" obligatory="true" description="columns to include in analysis. Example of usage: '1,3,5,6-8,Column10,Groupname5'" /> 
            <argument name="timePonts" type="String" obligatory="true" description="time points for regression. Amount of time points must be equal to amount of columns. Example: '2,4,6,8,10,12'" /> 
            <returns type="TableExperiment" description="contains scores and regression parameters" /> 
         </function>
         
          <function name="student" description="Performs student analysis of TableExperiments">
             <argument name="experiment" type="biouml.standard.type.TableExperiment" obligatory="true" description="experiment for analysis" /> 
            <argument name="outputName" type="String" obligatory="true" description="name for output TableExperiment" /> 
            <argument name="columns1" type="String" obligatory="true" description="first group of columns to include in analysis. Example of usage: '1,3,5,6-8,Column10,Groupname5'" /> 
            <argument name="columns1" type="String" obligatory="true" description="second group of columns to include in analysis. Example of usage: '1,3,5,6-8,Column10,Groupname5'" /> 
            <argument name="pvalue" type="double" obligatory="true" description="threshold for output data (will be outputed only scores with lesser P-value)" />  
            <argument name="isCalculatedFDR" type="boolean" obligatory="true" description="If true also calculates False Discovery Rate" /> 
            <returns type="TableExperiment" description="Contains scores" /> 
         </function>
         
         <function name="student1" description="Performs student analysis of TableExperiments with P-value 0.01">
             <argument name="experiment" type="biouml.standard.type.TableExperiment" obligatory="true" description="experiment for analysis" /> 
            <argument name="outputName" type="String" obligatory="true" description="name for output TableExperiment" /> 
            <argument name="columns1" type="String" obligatory="true" description="first group of columns to include in analysis. Example of usage: '1,3,5,6-8,Column10,Groupname5'" /> 
            <argument name="columns1" type="String" obligatory="true" description="second group of columns to include in analysis. Example of usage: '1,3,5,6-8,Column10,Groupname5'" /> 
            <returns type="TableExperiment" description="Contains scores" /> 
         </function>
        </doc>
      </hostObject>
  </extension>  
  
</plugin>
