Added text-input for contrast-matrix creator for affymetrics workflow.
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
import gtk
|
||||
from system import dataset, logger, plots, workflow
|
||||
from system import dataset, logger, plots, workflow, dialogs
|
||||
from scipy import randn, array, transpose, zeros
|
||||
import cPickle
|
||||
|
||||
@@ -17,6 +17,7 @@ class AffyWorkflow (workflow.Workflow):
|
||||
load.add_function(PhenotypeImportFunction())
|
||||
load.add_function(TestDataFunction())
|
||||
load.add_function(DatasetLoadFunction())
|
||||
load.add_function(ContrastMatrixGenerateFunction())
|
||||
self.add_stage(load)
|
||||
|
||||
explore = workflow.Stage('explore', 'Explorative analysis')
|
||||
@@ -103,7 +104,20 @@ class DatasetSaveFunction(workflow.Function):
|
||||
logger.log("notice", "Saved data to %r." % chooser.get_filename())
|
||||
finally:
|
||||
chooser.destroy()
|
||||
|
||||
|
||||
|
||||
class ContrastMatrixGenerateFunction(workflow.Function):
|
||||
def __init__(self):
|
||||
workflow.Function.__init__(self, 'contrast_create', 'Create contrast matrix')
|
||||
|
||||
def run(self, data):
|
||||
response = dialogs.get_text('Enter contrasts...', """\
|
||||
Enter comma-separated list of contrasts.
|
||||
Available categories: %s
|
||||
|
||||
Example: Y-N, M-F""" % ", ".join(data.get_categories()))
|
||||
logger.log("notice", "contrasts selected: %s" % response)
|
||||
|
||||
|
||||
class CelFileImportFunction(workflow.Function):
|
||||
"""Loads Affymetrics .CEL-files into matrix."""
|
||||
|
Reference in New Issue
Block a user