コード例 #1
0
    def getToolDescription(cls):
        '''
        Specifies a help text in HTML that is displayed below the tool.
        '''
        from proto.hyperbrowser.HtmlCore import HtmlCore

        core = HtmlCore()
        core.paragraph(
            'This tool takes a GSuite file as an input, and downloads the '
            'remote datasets which are referred to in this file onto the HyperBrowser '
            'server, returning a GSuite file referencing these local datasets. '
            'The datasets will be downloaded into hidden history elements, which can be '
            'shown using the menu option "Show hidden datasets" in the history "Options" menu.'
        )
        core.divider()
        core.paragraph(
            'The tool supports the following protocols for downloading:')
        core.unorderedList(['Rsync', 'FTP', 'HTTP', 'HTTPS'])
        core.paragraph(
            'Also,  gzip files ("*.gz) are automatically decompressed.')

        cls._addGSuiteFileDescription(
            core,
            outputLocation=cls.GSUITE_OUTPUT_LOCATION,
            outputFileFormat=cls.GSUITE_OUTPUT_FILE_FORMAT,
            outputTrackType=cls.GSUITE_OUTPUT_TRACK_TYPE,
            errorFile=True)

        return str(core)
コード例 #2
0
    def getToolDescription(cls):
        '''
        Specifies a help text in HTML that is displayed below the tool.
        '''
        from proto.hyperbrowser.HtmlCore import HtmlCore

        core = HtmlCore()
        core.paragraph(
            'This tool provides the option of filtering tracks in a GSuite file '
            'generating as output a GSuite file with the same columns, but '
            'with only a subset of tracks (rows) as selected by the user.')
        core.divider()
        core.paragraph('To filter a GSuite file, please follow these steps: ')
        core.orderedList([
            'Select the input GSuite file from history',
            'Select the tracks that should be kept (described in the list '
            'by its title, or by the whole uri if the title is not defined)',
            'Click the "Execute" button'
        ])

        cls._addGSuiteFileDescription(core,
                                      alwaysShowRequirements=True,
                                      alwaysShowOutputFile=True)

        return str(core)
コード例 #3
0
    def getToolDescription(cls):
        '''
        Specifies a help text in HTML that is displayed below the tool.
        '''
        from proto.hyperbrowser.HtmlCore import HtmlCore

        core = HtmlCore()
        core.paragraph(
            'This tool can be used to compile a GSuite file referring to a selection '
            'of files from the current Galaxy history. Selection of a genome build is optional.'
        )
        core.divider()
        core.smallHeader('Note')
        core.paragraph(
            'Even though this tool can be used to build GSuite compilations of any history elements, '
            'the resulting GSuite file will be more usable if the elements are somewhat homogeneous '
            'in file format and/or track type.')

        cls._addGSuiteFileDescription(
            core,
            outputLocation=cls.GSUITE_OUTPUT_LOCATION,
            outputFileFormat=cls.GSUITE_OUTPUT_FILE_FORMAT,
            outputTrackType=cls.GSUITE_OUTPUT_TRACK_TYPE)

        return str(core)
コード例 #4
0
    def getToolDescription(cls):
        '''
        Specifies a help text in HTML that is displayed below the tool.
        '''
        from proto.hyperbrowser.HtmlCore import HtmlCore

        core = HtmlCore()
        core.smallHeader('General')
        core.paragraph(
            'This tool exports selected tracks in a local GSuite file to the Galaxy history. '
            'The tool creates a new GSuite file with points to the exported tracks. '
            ' In addition, the tool can provide a preview of the the beginning of any track '
            'directly from the tool interface.')
        core.divider()
        core.smallHeader('Conversion')
        core.paragraph(
            'As part of the export process, the tracks can be converted into another file format. '
            'The list of file formats are dynamically created based upon the selected tracks. The list '
            'contains only file formats that allow conversion from all the selected tracks.'
        )

        cls._addGSuiteFileDescription(
            core,
            allowedLocations=cls.GSUITE_ALLOWED_LOCATIONS,
            allowedFileFormats=cls.GSUITE_ALLOWED_FILE_FORMATS,
            allowedTrackTypes=cls.GSUITE_ALLOWED_TRACK_TYPES,
            outputLocation=cls.GSUITE_OUTPUT_LOCATION,
            outputFileFormat=cls.GSUITE_OUTPUT_FILE_FORMAT,
            outputTrackType=cls.GSUITE_OUTPUT_TRACK_TYPE)

        return str(core)
 def getToolDescription():
     '''
     Specifies a help text in HTML that is displayed below the tool.
     '''
     core = HtmlCore()
     core.paragraph(
         'This tool can be used to concatenate HyperBrowser analysis results '
         'from several different history elements into a single tabular file, '
         'providing a simple overview of many runs at once. The tool only works on '
         'history elements created by the tools "Analyze genomic tracks" and '
         '"Execute batch commands".')
     core.divider()
     core.paragraph(
         'In order to concatenate, you will need to select a single result statistic. '
         'The tool will then fetch the resulting values of this statistic '
         'from the different runs in the selected '
         'history elements. The tool supports concatenation of either global '
         'or local results. Several formatting options are also provided.')
     core.divider()
     core.paragraph(
         'The resulting table can easily be pasted into spreadsheet programs '
         'such as Microsoft Excel for further analysis. To look at the data in Excel '
         'you need to:')
     core.orderedList([
         'Click the eye icon of the new history element to look at the table',
         'Click somewhere in the table',
         'Select "Select All" from the "Edit" menu (or type cmd-A (Mac) or cltr-A (Windows))',
         'Copy the table (cmd/ctrl-C)', 'Switch to Excel',
         'Select "Paste special..." '
         'from the "Edit" menu.',
         'In the dialog box that opens, choose "Text"'
     ])
     return str(core)
コード例 #6
0
    def getToolDescription():
        '''
        Specifies a help text in HTML that is displayed below the tool.
        '''
        from proto.hyperbrowser.HtmlCore import HtmlCore
        core = HtmlCore()
        core.paragraph('''
This tool combines elements from two separate data sets into a single track where
the elements are denoted as case (target) or control, depending on their source.
This allows analyses of how other tracks preferentially interact with case
elements as opposed to control elements.''')
        core.divider()
        core.smallHeader('Shared regions')
        core.paragraph('''
This tool supports four ways of handling regions that are found in both case and
control tracks. These regions do not need to be full segments, as defined in the
input tracks; the tool also correctly handles shared parts of segments.''')
        core.descriptionLine('Shared regions should be removed', \
            'the shared regions are not returned, neither as case nor as control segments')
        core.descriptionLine('Shared regions should be returned as case regions', \
            'the shared regions are all denoted as case regions and returned')
        core.descriptionLine('Shared regions should be returned as control regions', \
            'the shared regions are all denoted as control regions and returned')
        core.descriptionLine('Shared regions should be returned as they are', \
            '''
the shared regions are not handled in any way, but denoted according to whether
they were found in the case or the control input track. Note that this may
result in case and control regions that overlap. The subsequent analysis may not
handle this correctly.''')
        return str(core)
コード例 #7
0
    def getToolDescription(cls):
        '''
        Specifies a help text in HTML that is displayed below the tool.
        '''
        from proto.hyperbrowser.HtmlCore import HtmlCore

        core = HtmlCore()
        core.paragraph(
            'This tool can be used to compile a GSuite file referring to a subset of the tracks '
            'in the HyperBrowser repository. To use the tool, please follow these steps:'
        )
        core.orderedList([
            'Select the genome build',
            'Select the parent track, i.e. the top level in the track hierarchy that '
            'you are interested in. The tool will return all tracks that are found in the '
            'hierarchy underneath the selected parent track, descending into all sublevels.'
        ])
        core.divider()
        core.smallHeader('Note')
        core.paragraph(
            'Even though this tool can be used to build GSuite compilations of any tracks, '
            'the resulting GSuite file will be more usable if the track are somewhat homogeneous '
            'in track type.')

        cls._addGSuiteFileDescription(
            core,
            outputLocation=cls.GSUITE_OUTPUT_LOCATION,
            outputFileFormat=cls.GSUITE_OUTPUT_FILE_FORMAT,
            outputTrackType=cls.GSUITE_OUTPUT_TRACK_TYPE)

        return str(core)
    def getToolDescription(cls):
        '''
        Specifies a help text in HTML that is displayed below the tool.
        '''
        from proto.hyperbrowser.HtmlCore import HtmlCore

        core = HtmlCore()
        core.paragraph(
            'Converts a preprocessed GSuite into a primary GSuite with local file paths'
        )

        core.divider()
        core.paragraph(
            str(HtmlCore().highlight(
                'NOTE: SHOULD NOT BE MADE PUBLIC FOR SECURITY '
                'REASONS.')))

        cls._addGSuiteFileDescription(
            core,
            allowedLocations=cls.GSUITE_ALLOWED_LOCATIONS,
            allowedFileFormats=cls.GSUITE_ALLOWED_FILE_FORMATS,
            allowedTrackTypes=cls.GSUITE_ALLOWED_TRACK_TYPES,
            outputLocation=cls.GSUITE_OUTPUT_LOCATION,
            outputFileFormat=cls.GSUITE_OUTPUT_FILE_FORMAT,
            outputTrackType=cls.GSUITE_OUTPUT_TRACK_TYPE,
            errorFile=False,
            minTrackCount=cls.GSUITE_MIN_TRACK_COUNT)

        return str(core)
コード例 #9
0
    def getToolDescription(cls):
        '''
        Specifies a help text in HTML that is displayed below the tool.
        '''
        from proto.hyperbrowser.HtmlCore import HtmlCore
        from gold.gsuite.GSuiteConstants import URI_COL, FILE_FORMAT_COL, \
                                                TRACK_TYPE_COL, TITLE_COL

        core = HtmlCore()
        core.paragraph('This tool provides the option of filtering metadata columns '
                       'in a GSuite file, generating as output a GSuite file with the '
                       'same tracks (rows), but with only a subset of '
                       'metadata columns as selected by the user. ')
        core.divider()
        core.paragraph('To filter a GSuite file, please follow these steps: ')
        core.orderedList(['Select the input GSuite file from history',
                          'Select the metadata columns that should be kept',
                          'Click the "Execute" button'])

        core.divider()
        core.smallHeader('Note')
        core.paragraph('The standard metadata columns of a GSuite file cannot be '
                       'removed by this tool: ')
        core.unorderedList([URI_COL, FILE_FORMAT_COL, TRACK_TYPE_COL])
        core.paragraph('The exception to this rule is the "%s" column.' % TITLE_COL)

        cls._addGSuiteFileDescription(core,
                                      alwaysShowRequirements=True,
                                      alwaysShowOutputFile=True)

        return str(core)
        string = 'This tool provides the option of filtering track attributes in a GSuite file and generates a GSuite with the user selected attributes. It takes a GSuite file as an input, and displays all the included attributes in mutiple selections box. Upon the user selection, only the selected attributes will appear in the resulted GSuite.'
        return string
コード例 #10
0
 def getToolDescription():
     from proto.hyperbrowser.HtmlCore import HtmlCore
     core = HtmlCore()
     core.paragraph(
         'Create density distribution or smoothed version of any track, based on a sliding window across the genome.'
     )
     core.divider()
     core.paragraph(
         'The available density/smoothing options will depend on the type of the selected track of interest. For instance, it gives meaning to compute the density along the genome of a point track, but for a function track it instead gives meaning to smooth function values in a sliding window. For segments, it may be meaningful to consider either the count or coverage of segments along the genome.'
     )
     return str(core)
コード例 #11
0
ファイル: ResultsViewer.py プロジェクト: uio-bmi/track_rand
    def __str__(self):
        core = HtmlCore()

        #core.begin()
        for i, viewer in enumerate(self._viewers):
            core.paragraph(str(viewer))
            if i < len(self._viewers) - 1:
                core.divider(withSpacing=True)
        #core.end()

        return str(core)
コード例 #12
0
 def getToolDescription():
     from proto.hyperbrowser.HtmlCore import HtmlCore
     core = HtmlCore()
     core.paragraph('Extract occurrences of a given k-mer in a specified region along the selected genome. K-mer occurrence track is extracted as a BED file.')
     core.divider()
     core.highlight('K-mer')
     core.paragraph('A string based on only the following characters: a, c, g, t, A, C, G, T. Eventual use of case has no effect.')
     core.divider()
     core.highlight('Region of the genome')
     core.paragraph('Region specification as in UCSC Genome browser. * means whole genome. k and m denotes thousand and million bps, respectively. E.g chr1:1-20m')
     return str(core)
コード例 #13
0
    def getToolDescription():
        from proto.hyperbrowser.HtmlCore import HtmlCore
        core = HtmlCore()
        
        core.paragraph('''
This tool generates a function track covering the whole genome, where each base
pair gets a value denoting the distance (in bps) to the nearest element in the
selected track.''')
        core.divider()
        core.paragraph('''
The distance measure may be transformed to other bps-derived values (e.g. the
logarithm or fifth square root of the bps distance), if desired.''')
        
        return str(core)
コード例 #14
0
 def getToolDescription():
     from proto.hyperbrowser.HtmlCore import HtmlCore
     core = HtmlCore()
     core.paragraph(
         'Creates a scatter plot of the relation between two tracks across local bins along the genome.'
     )
     core.divider()
     core.paragraph(
         'Each point in the scatter plot is a summarized value of the two tracks (as x and y-values) in a given bin. Thus, a point corresponds to a bin, the x-axis corresponds to first track, and the y-axis corresponds to second track.'
     )
     core.divider()
     core.paragraph(
         'First, select a genome and two track of interest. Then a full analysis specification page appears, where one can directly start a basic analysis or specify further details on the analysis of interest.'
     )
     return str(core)
コード例 #15
0
 def getToolDescription(cls):
     core = HtmlCore()
     core.paragraph(
         "This is a simple tool for preprocessing track files in the HyperBrowser track repository. "
         "Please select a track directory from the standarized tracks file tree. "
     )
     core.divider()
     core.descriptionLine(
         "Recursion",
         "Directories can be selected at any level. The preprocessor will recursively visit all "
         "sub-directories of the selected directory")
     core.descriptionLine(
         "Track file merge",
         "All track files within a directory will be merged together as one track (under the "
         "assumption that all files are of the same track type).")
     return str(core)
コード例 #16
0
 def getToolDescription():
     from proto.hyperbrowser.HtmlCore import HtmlCore
     core = HtmlCore()
     core.paragraph(
         'Analyze occurrences of a given k-mer along the genome, either in itself or in relation to other genomic tracks.'
     )
     core.divider()
     core.paragraph(
         'First, select a genome and k-mer of interest. Then a full analysis specification page appears, where one can directly start a basic analysis or specify further details on the analysis of interest.'
     )
     core.divider()
     core.highlight('K-mer')
     core.paragraph(
         'A string based on only the following characters: a, c, g, t, A, C, G, T. Eventual use of case has no effect.'
     )
     return str(core)
コード例 #17
0
    def getToolDescription():

        htmlCore = HtmlCore()

        htmlCore.paragraph(
            'The tool is used to generate frequency of dataset and rainfall plots.'
        )

        htmlCore.divider()

        htmlCore.paragraph(
            'The input for tool is a GSuite file contains one or more datasets.'
        )
        htmlCore.paragraph('The output for tool is a plot.')

        return str(htmlCore)
コード例 #18
0
 def getToolDescription():
     from proto.hyperbrowser.HtmlCore import HtmlCore
     core = HtmlCore()
     core.paragraph(
         'Inspect the frequency variation of occurrences of a given k-mer in a specified region along the selected genome. The tool tries to determine appropriate binning of the specified region, and outputs the number of k-mer occurrences per bin as a plot and as underlying textual data.'
     )
     core.divider()
     core.highlight('K-mer')
     core.paragraph(
         'A string based on only the following characters: a, c, g, t, A, C, G, T. Eventual use of case has no effect.'
     )
     core.divider()
     core.highlight('Region of the genome')
     core.paragraph(
         'Region specification as in UCSC Genome browser. * means whole genome. k and m denotes thousand and million bps, respectively. E.g chr1:1-20m'
     )
     return str(core)
コード例 #19
0
    def getToolDescription(cls):
        '''
        Specifies a help text in HTML that is displayed below the tool.
        '''
        from proto.hyperbrowser.HtmlCore import HtmlCore

        core = HtmlCore()
        core.paragraph(
            'This tool contains various operations for manipulating textual '
            'track files referred to in a GSuite file.')
        core.divider()
        core.smallHeader('Instructions')
        core.orderedList([
            'Select a GSuite file referring to local textual track files',
            'The first track referred to in the GSuite is automatically selected '
            'as an example track, with the beginning of the file shown in a '
            'text box. The example file is later used to show the results of the '
            'selected operation. If you want to use another file as the example track '
            'please select it in the selection box. ',
            'Select the required operation from the list of operations '
            '(click the info box if you need further description of each operation '
            'and its parameters):' + str(HtmlCore().unorderedList(
                [key for key in cls.ALL_OPERATIONS.keys()])),
            'Each parameter for the selected operation is shown in a selection box, '
            'with the default value indicated. If another value than the default is '
            'needed, please select the parameter and change its value. '
            'the order in which the parameters is selected is unimportant.',
            'The output of the selected operation with the selected parameter values '
            'on the beginning of the selected example track is shown in a text box.',
            'If the file format (e.g. "bed") of the track is changed as a result of '
            'carrying out the operation, please indicate the new file suffix. '
            'It is important for the tracks to have the correct file suffix for further '
            'analysis.'
        ])

        cls._addGSuiteFileDescription(
            core,
            allowedLocations=cls.GSUITE_ALLOWED_LOCATIONS,
            allowedFileFormats=cls.GSUITE_ALLOWED_FILE_FORMATS,
            outputLocation=cls.GSUITE_OUTPUT_LOCATION,
            outputFileFormat=cls.GSUITE_OUTPUT_FILE_FORMAT,
            outputTrackType=cls.GSUITE_OUTPUT_TRACK_TYPE,
            errorFile=True)

        return str(core)
コード例 #20
0
    def getToolDescription(cls):
        '''
        Specifies a help text in HTML that is displayed below the tool.
        '''
        from proto.hyperbrowser.HtmlCore import HtmlCore
        core = HtmlCore()

        core.paragraph('The tool provides a structured search for genomic tracks stored in '
                       'the following repositories:')
        core.unorderedList(['ENCODE tracks which are located in both UCSC and Ensembl databases.',
#                            'Roadmap Epigenomics',
                            'Roadmap Epigenomics',
                            'Cancer Genome Atlas (TCGA)',
                            'FANTOM 5',
                            'International Cancer Genome Consortium (ICGC)',
                            'Ensembl BLUEPRINT epigenome project',
                            'NHGRI-EBI GWAS Catalog'])

        core.paragraph('The tool generates a metadata file in the GSuite format which contains '
                       'the URL and other metadata associated with each of the track files that '
                       'match the search criteria. To use the tool, please follow these steps:')
        core.orderedList(['Select an attribute from the attribute list to search with',
                          'Select the value associated with this attribute from the associated attribute list',
                          'Repeat steps 1 and 2 to filter using more attributes',
                          'Select whether to compile a GSuite using:' +
                          str(HtmlCore().unorderedList(['All rearch results',
                                                        'Present results as a file list and have '
                                                        'the option of selecting a subset of those '
                                                        'result to compile the GSuite'])),
                          'Specify  the format of the output (' + str(HtmlCore().highlight('gsuite')) +
                              ' for GSuite or ' + str(HtmlCore().highlight('HTML')) +
                              ' for a more human readable format)'])

        core.divider()
        core.smallHeader('Note')
        core.paragraph('Even though this tool can be used to build GSuite compilations of any files, '
                       'the resulting GSuite file will be more usable if the files are somewhat homogeneous '
                       'in file format and/or track type.')

        cls._addGSuiteFileDescription(core,
                                      outputLocation=cls.GSUITE_OUTPUT_LOCATION,
                                      outputFileFormat=cls.GSUITE_OUTPUT_FILE_FORMAT,
                                      outputTrackType=cls.GSUITE_OUTPUT_TRACK_TYPE)

        return str(core)
コード例 #21
0
    def getToolDescription(cls):
        '''
        Specifies a help text in HTML that is displayed below the tool.
        '''

        core = HtmlCore()
        core.paragraph(
            'This tool creates a new GSuite file based upon the contents of an '
            'archive file. Currently, the tool supports ".tar" (with and without '
            '".gz") and ".zip" files. To use the tool, please upload an archive file '
            'to your history using the Galaxy import tool (click the icon to the right '
            'of the "Tools" header in the top left of the window). You will need to '
            'manually select the file type as "gsuite.zip" or "gsuite.tar", as '
            'described below. After uploading, you then open this tool, select the '
            'archive, and click "Execute".')
        core.divider()
        core.smallHeader('* IMPORTANT *')
        core.paragraph(
            str(HtmlCore().emphasize(
                'In order to circumvent Galaxy\'s integrated archive decompresssion (which '
                'for zip files only extracts a single file), you must manually select '
                '"gsuite.tar" or "gsuite.zip" in the "Type" column in the upload file '
                'dialog box.')))
        core.divider()
        core.smallHeader(
            'Keep directory hierarchy intact and present as columns in the GSuite '
            'file?')
        core.paragraph(
            'By default, any directory structure in the archive is kept intact in '
            'the file path in the URIs in the output GSuite file. In addition, one '
            'column is added per level in the directory hierarchy, with the values '
            'denoting the directory where the file resides. In this way, one can '
            'make use of the directory structure as metadata categories. Optionally, '
            'one can ignore the hierarchy, flattening the archive into a single '
            'directory level, with no extra columns added.')

        cls._addGSuiteFileDescription(
            core,
            outputLocation=cls.GSUITE_OUTPUT_LOCATION,
            outputFileFormat=cls.GSUITE_OUTPUT_FILE_FORMAT,
            outputTrackType=cls.GSUITE_OUTPUT_TRACK_TYPE,
            errorFile=False)

        return str(core)
    def getToolDescription():

        htmlCore = HtmlCore()

        htmlCore.paragraph(
            'The tool is used to generate density of distribution.')

        htmlCore.divider()

        htmlCore.paragraph('The input for tool is following:')
        htmlCore.line('- GSuite')
        htmlCore.line(
            '- file with regions (bed format), which should be given by user')

        htmlCore.divider()

        htmlCore.paragraph('The output for tool is a plot.')

        return str(htmlCore)
コード例 #23
0
    def getToolDescription(cls):
        '''
        Specifies a help text in HTML that is displayed below the tool.
        '''
        from proto.hyperbrowser.HtmlCore import HtmlCore
        from gold.origdata.GenomeElementSource import getAllGenomeElementSourceClasses

        core = HtmlCore()
        core.paragraph(
            'This tool is used to preprocess the textual track files referred to by '
            'a GSuite file into a indexed, binary format that is needed for '
            'efficient analysis by the HyperBrowser analysis tools.')
        core.divider()
        core.smallHeader('Genome')
        core.paragraph(
            'Preprocessing tracks requires that the specific genome build is selected. '
            'If a genome build is defined within the GSuite file, it can still be overridden '
            'by the user if another build is selected. If the GSuite file contains no '
            'genome, the selection of a genome build is required.')
        core.divider()
        core.smallHeader('Supported file types')
        core.paragraph(
            'The HyperBrowser preprocessor supports the following file types (name: file suffix):'
        )

        geSourceClsList = getAllGenomeElementSourceClasses(
            forPreProcessor=True)
        core.unorderedList([
            '%s: "%s"' % (geSourceCls.FILE_FORMAT_NAME,
                          ', '.join(geSourceCls.FILE_SUFFIXES))
            for geSourceCls in geSourceClsList
        ] + ['broadPeak: ".broadpeak"', 'narrowPeak: ".narrowpeak"'])

        cls._addGSuiteFileDescription(
            core,
            allowedFileFormats=cls.GSUITE_ALLOWED_FILE_FORMATS,
            allowedLocations=cls.GSUITE_ALLOWED_LOCATIONS,
            outputLocation=cls.GSUITE_OUTPUT_LOCATION,
            outputFileFormat=cls.GSUITE_OUTPUT_FILE_FORMAT,
            errorFile=True)

        return str(core)
コード例 #24
0
    def getToolDescription(cls):
        from proto.hyperbrowser.HtmlCore import HtmlCore

        core = HtmlCore()
        core.paragraph('Converts a GSuite file with primary and locally stored tracks to an equal '
                       'GSuite file with the absolute paths from local storage.')

        core.divider()
        core.paragraph(str(HtmlCore().highlight('NOTE: SHOULD NOT BE MADE PUBLIC FOR SECURITY '
                                                'REASONS.')))

        cls._addGSuiteFileDescription(core,
                                      allowedLocations=cls.GSUITE_ALLOWED_LOCATIONS,
                                      allowedFileFormats=cls.GSUITE_ALLOWED_FILE_FORMATS,
                                      allowedTrackTypes=cls.GSUITE_ALLOWED_TRACK_TYPES,
                                      outputLocation=cls.GSUITE_OUTPUT_LOCATION,
                                      outputFileFormat=cls.GSUITE_OUTPUT_FILE_FORMAT,
                                      outputTrackType=cls.GSUITE_OUTPUT_TRACK_TYPE)

        return str(core)
コード例 #25
0
    def getToolDescription():
        htmlCore = HtmlCore()

        htmlCore.paragraph('This tool provides the possibility to generate synthetic dataset with Poisson distribution.')

        htmlCore.divider()

        htmlCore.paragraph('The input for tool is following:')
        htmlCore.line('- genome, which you can select from the given options')
        htmlCore.line('- file with parameters (gtrack format), which should be given by user')


        htmlCore.paragraph('File with parameters should include information about:')
        htmlCore.line('- chromosome')
        htmlCore.line('- start position')
        htmlCore.line('- end position')
        htmlCore.line('- inter-events distance')
        htmlCore.line('- intra-events distance')
        htmlCore.line('- probability value')

        htmlCore.paragraph('The example of file with parameters:')

        htmlCore.paragraph('''
                ##Track type: points <br \>
                ###seqid        start   end     inter   intra   prob <br \>
                ####genome=hg19 <br \>
                chr1	0	100000	0.0001	0	1
        ''')
        htmlCore.line(', where first three lines are a header, the fourth line contains the information about'
                      'region (chromosome, start, end position) and values ' \
                      '(inter-, intra-mutations, probability) for which will be calculated synthetic dataset.')

        htmlCore.divider()

        htmlCore.line('IMPORTANT INFORMATION')
        htmlCore.line('The file can contains more than one line with parameters, but the calculated simulated datasets ' \
                      'for every regions are merged together at the end.')

        htmlCore.divider()

        htmlCore.paragraph('The output for tool is a GSuite containing one simulated dataset.')

        htmlCore.divider()

        htmlCore.line('IMPORTANT OTHER TOOLS')
        htmlCore.line('To upload your own file with parameters (available later as an element in the history) use the tool called:' \
                      ' Upload file ')

        return str(htmlCore)
コード例 #26
0
    def getToolDescription():
        '''
        Specifies a help text in HTML that is displayed below the tool.
        '''
        core = HtmlCore()
        core.paragraph(
            'Analyze a selected track of genome locations for spatial co-localization with '
            'respect to the three-dimensional structure of the genome, as defined using '
            'results from recent Hi-C experiments. The Hi-C data has been corrected for bias '
            'using a method presented in a recent manuscript (submitted), and further '
            'normalized by subtracting the expected signal given the sequential distance '
            'between elements.')

        core.divider()
        core.smallHeader('References')
        core.paragraph('Paulsen, Jonas, Tonje G. Lien, Geir Kjetil Sandve, Lars Holden, &Oslash;rnulf Borgan, ' +\
                       'Ingrid K. Glad, and Eivind Hovig. "' +\
                       str(HtmlCore().link('Handling realistic assumptions in hypothesis testing of 3D co-localization of genomic elements.',
                                           'http://nar.oxfordjournals.org/content/41/10/5164.full')) + \
                       '" Nucleic acids research 41, no. 10 (2013): 5164-5174.')

        return str(core)
コード例 #27
0
    def getToolDescription():
        core = HtmlCore()
        core.paragraph(
            'Checks a GTrack file for correspondence to the GTrack specification. '
            'For the latest version of the specification, see the "Show GTrack specification" tool.'
        )

        core.divider()
        core.smallHeader('Genome')
        core.paragraph(
            'If a genome build is selected, the tool will check whether all coordinates '
            'fall within the coordinate system of the genome build (i.e. based on the sequence names and lengths). '
            'Also, some GTrack files require a specified genome to be valid, e.g. if bounding regions '
            'are specified without explicit end coordinates.')

        core.divider()
        core.smallHeader('Notice')
        core.paragraph(
            'The results of the validation is output as a new history element. '
            'A correctly run history item, i.e. one colored green, does not mean that the GTrack file '
            'has been found valid. One must click the eye icon of the history item to see the correct '
            'conclusion.')
        return str(core)
コード例 #28
0
    def getToolDescription():
        '''
        Specifies a help text in HTML that is displayed below the tool.
        '''
        from proto.hyperbrowser.HtmlCore import HtmlCore

        core = HtmlCore()
        core.paragraph(
            'This tool provides the option of editing contents of medatata '
            'columns in a GSuite file where the user can edit the titles '
            'in the file.')
        core.divider()
        core.paragraph('To filter a GSuite file, please follow these steps: ')
        core.orderedList([
            'Select the input GSuite file from history',
            'Select the titles of the tracks that should be edited',
            'Edit the titles of the tracks', 'Click the Execute button'
        ])
        '''cls._addGSuiteFileDescription(core,
                                      alwaysShowRequirements=True,
                                      alwaysShowOutputFile=True)'''

        return str(core)
コード例 #29
0
    def getToolDescription(cls):
        '''
        Specifies a help text in HTML that is displayed below the tool.
        '''
        from proto.hyperbrowser.HtmlCore import HtmlCore

        core = HtmlCore()

        core.paragraph('This tool computes the proportions of overlap between the segments '
                       'of a query track against each track in a collection of reference tracks '
                       'described in a GSuite file. The overlap proportions are output in an '
                       'interactive heatmap, where each cell is colored according to the '
                       'overlap between each query segment (column) with each reference '
                       'track (row).')

        core.divider()
        core.paragraph('To carry out the analysis, please follow these steps:')
        core.orderedList(['Select a genome build. Both the query track and the reference tracks'
                          'need to use the same genome build.',
                          'Select a query track from the HyperBrowser repository',
                          'Select a reference track collection as a GSuite file from history',
                          'Select the color map, going from no overlap to full overlap.',
                          'Click "Execute"'])

        core.divider()
        core.smallHeader('Requirements for query track')
        core.descriptionLine('Track types', ', '.join(cls.TRACK_ALLOWED_TRACK_TYPES), emphasize=True)


        cls._addGSuiteFileDescription(core,
                                      allowedLocations=cls.GSUITE_ALLOWED_LOCATIONS,
                                      allowedFileFormats=cls.GSUITE_ALLOWED_FILE_FORMATS,
                                      allowedTrackTypes=cls.GSUITE_ALLOWED_TRACK_TYPES,
                                      disallowedGenomes=cls.GSUITE_DISALLOWED_GENOMES)

        return str(core)
    def getToolDescription():
        from proto.hyperbrowser.HtmlCore import HtmlCore
        core = HtmlCore()
        core.paragraph('Creates a function track based on a custom expression applied on a sliding windows across the genome.')
        core.divider()
        core.paragraph('''For each position in the selected genome, the supplied custom expression is evaluated for the DNA sequence of a window of selected size around the region. Details on the expression format:''')
        core.paragraph( str(HtmlCore().unorderedList(['The DNA sequence of this window is available in a variable "s". Thus s[0] will give the bp letter at position 0', '''A binary vector (list) named "a" is available, where the value of a[i] is 1 if the base pair at position i is A, if not, the value is 0. ("a[i]" is thus identical to the expression "1 if s[i]=='a' else 0". Similarly, there are vectors c,g,t,n. )''', 'The variable "winSize" gives the window size', 'The variable "winIndexes" gives a list of all index positions in the window (thus, winIndexes is equivalent to "range(len(s))").', 'All 1-letter variables are usable if defined in the expression.', 'The following words (2 or more letters) are allowed: sum, max, min, if, else, for, in, len, range', 'The expression must follow python/numpy syntax.'])) )
        core.divider()
        core.paragraph('One can choose whether index 0 should be the left-most position of sliding window (with n-1 being right-most), or whether index 0 should be midpoint, that is the same position that gets assigned the computed value (so that left-most is index "-n/2" and right-most is "n/2").')
        core.divider()
        core.paragraph('''Example of custom expression, computing GC content in a sliding window: <br>''')
        core.append(CreateDnaBasedCustomTrackTool._exampleText('sum([g[i]+c[i] for i in winIndexes])'))
        #core.paragraph('''A full example of how this tool can be used is given through a %s.''' % str(HtmlCore().link('Galaxy Page', 'http://hyperbrowser.uio.no/test/u/vegard/p/create-track-from-dna-sequence')))
        #core.paragraph('''<a href=http://hyperbrowser.uio.no/test/u/vegard/p/create-track-from-dna-sequence target=_top>See full example</a> of how to use this tool.''')

        return str(core)