How can I specify the column order for stacked visualizations of OTU abundance tables?
Go Back The order of the columns of the stacked visualization of OTU abundance tables reflects the order of the inputs provided to the OTU clustering tool or the Data QC and OTU Clustering workflow. Thus, to see the columns in the stacked visualization in a specific order, select the inputs to the tool/workflow in that order. The order of the columns can also be altered using the Sort Sample by option in the side panel. This can be used to group columns, with metadata specifying the groups. Note however that the order within groups is still determined by the order of the inputs to the tool/workflow. Below, we outline methods for specifying inputs to the workflow in a particular order, and then provide further details about the Sort Sample by option.
Selecting inputs to the workflow in a particular orderUse the order of the read lists in the Navigation AreaIf you select multiple read lists in one action or by using the right-click option "Add folder contents", the read lists will be selected in the same order they are listed in the Navigation Area. If this order is the same order the columns in the stacked visualization should be shown in, then this is a simple method to get that order. To select multiple read lists in one action:
Note: The order in the Navigation Area is not maintained if you un-select one or more of the already selected samples or select multiple elements using the "Shift + Control (Ctrl)" keys together.
In the example images below the samples are selected in the order 1 to 8 with 1 being on the top. This will sort the samples 1 to 8 with 1 being to the left in the stacked visualization:
Read lists stored in the Navigation Area that cannot be sorted in the particular orderIf your read lists cannot be sorted in the Navigation Area to be in the same order you want for the columns in the stacked visualization, you can instead:
or
Specifically:
When launching the tool or workflow, the samples will now be preselected in the same order as they were listed in the Metadata Table.
In the example images below the 8 sample cannot be sorted in the particular order 1 to 8 in the Navigation Area, as the read lists include a prefix, e.g. NGS-10100, NGS-20110, etc.. When using the sorted Metadata table to find the samples in the Navigation Area, they will be preselected in the same order as the Metadata table, when launching the workflow.
Using the Sort Samples by option in the side panelThe Sort Sample by option in the side panel can be used to group columns, with metadata specifying the groups. This option changes the order of groups of columns, but the order within those groups is still determined by the order of the inputs to the workflow. In the images below this is exemplified by grouping 8 samples into the three groups: Patient (A, B, C and D), Sex (Male and Female) and Treatment (Before and After) using the following metadata:
Sorting on Sex changes the order of Samples 3 and 4, and Samples 5 and 6, as it groups the male and female samples. Sorting on Treatment groups Sample 1, 3, 5, and 7 (before treatment) and Sample 2, 4, 6, and 8 (after treatment). |