1.1. How can I specify the column order for stacked visualizations of OTU abundance tables?
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 order
Use the order of the read lists in the Navigation Area
If 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:
- Select the top read list
- Hold down "Shift" on the keyboard
- Select the lower read list
- Click the arrow to select the elements
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 order
If 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:
- Select each element individually in the wizard, so the selected inputs are listed in the desired order,
- Sort a relevant Metadata Table on the desired attribute, and select the data elements from there.
- Open the Metadata Table describing the samples and sort it based on a relevant column.
- Select the rows for the relevant samples.
- Click on the Find Associated Data button.
- Select the rows for the data (sequence lists) to be used as input to the tool or workflow.
- Click on the Find in Navigation Area button.
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 panel
The 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 Patient results. Here the data is shown in the same order as the sample numbers.
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).