Skip to main content

tw datasets

Manage datasets

Run tw datasets -h to view the list of supported operations.

Datasets are CSV (comma-separated values) and TSV (tab-separated values) files stored in a workspace, used as inputs during pipeline execution. The most commonly used datasets for Nextflow pipelines are samplesheets, where each row consists of a sample, the location of files for that sample (such as FASTQ files), and other sample details.

tw datasets add

Add a dataset

tw datasets add [OPTIONS] <FILENAME>

Arguments

ArgumentDescriptionRequired
FILENAMEData file to uploadYes

Options

OptionDescriptionRequiredDefault
-n, --nameDataset name. Must be unique per workspace. Names consist of alphanumeric, hyphen, and underscore characters.Yes
-d, --descriptionOptional dataset description.No
--headerTreat first row as header. Default: false.No
-w, --workspaceWorkspace numeric identifier or reference in OrganizationName/WorkspaceName format (defaults to TOWER_WORKSPACE_ID environment variable)Yes
--overwriteOverwrite the dataset if it already existsNofalse

Run tw datasets add -h to view the required and optional fields for adding a dataset.

Add a preconfigured dataset file to a workspace (include the --header flag if the first row of your samplesheet file is a header):

tw datasets add --name=samplesheet1 --header samplesheet_test.csv

Dataset 'samplesheet1' added at user workspace with id '60gGrD4I2Gk0TUpEGOj5Td'
note

The maximum supported dataset file size is 10 MB.

tw datasets delete

Delete a dataset

tw datasets delete [OPTIONS]

Options

OptionDescriptionRequiredDefault
-i, --idDataset unique identifierYes
-n, --nameDataset nameYes
-w, --workspaceWorkspace numeric identifier or reference in OrganizationName/WorkspaceName format (defaults to TOWER_WORKSPACE_ID environment variable)Yes

To delete a workspace dataset, specify either the dataset name (-n flag) or ID (-i flag):

tw datasets delete -i 6tYMjGqCUJy6dEXNK9y8kh

Dataset '6tYMjGqCUJy6dEXNK9y8kh' deleted at 97652229034604 workspace

tw datasets download

Download a dataset

tw datasets download [OPTIONS]

Options

OptionDescriptionRequiredDefault
-i, --idDataset unique identifierYes
-n, --nameDataset nameYes
--dataset-versionDataset version to downloadNo
-w, --workspaceWorkspace numeric identifier or reference in OrganizationName/WorkspaceName format (defaults to TOWER_WORKSPACE_ID environment variable)Yes

View a stored dataset's contents:

tw datasets download -n samplesheet1

sample,fastq_1,fastq_2,strandedness
WT_REP1,https://raw.githubusercontent.com/nf-core/test-datasets/rnaseq/testdata/GSE110004/SRR6357070_1.fastq.gz,https://raw.githubusercontent.com/nf-core/test-datasets/rnaseq/testdata/GSE110004/SRR6357070_2.fastq.gz,auto
WT_REP1,https://raw.githubusercontent.com/nf-core/test-datasets/rnaseq/testdata/GSE110004/SRR6357071_1.fastq.gz,https://raw.githubusercontent.com/nf-core/test-datasets/rnaseq/testdata/GSE110004/SRR6357071_2.fastq.gz,auto
WT_REP2,https://raw.githubusercontent.com/nf-core/test-datasets/rnaseq/testdata/GSE110004/SRR6357072_1.fastq.gz,https://raw.githubusercontent.com/nf-core/test-datasets/rnaseq/testdata/GSE110004/SRR6357072_2.fastq.gz,reverse
RAP1_UNINDUCED_REP1,https://raw.githubusercontent.com/nf-core/test-datasets/rnaseq/testdata/GSE110004/SRR6357073_1.fastq.gz,,reverse
RAP1_UNINDUCED_REP2,https://raw.githubusercontent.com/nf-core/test-datasets/rnaseq/testdata/GSE110004/SRR6357074_1.fastq.gz,,reverse
RAP1_UNINDUCED_REP2,https://raw.githubusercontent.com/nf-core/test-datasets/rnaseq/testdata/GSE110004/SRR6357075_1.fastq.gz,,reverse
RAP1_IAA_30M_REP1,https://raw.githubusercontent.com/nf-core/test-datasets/rnaseq/testdata/GSE110004/SRR6357076_1.fastq.gz,https://raw.githubusercontent.com/nf-core/test-datasets/rnaseq/testdata/GSE110004/SRR6357076_2.fastq.gz,reverse

tw datasets hide

Hide one or more datasets

tw datasets hide [OPTIONS]

Options

OptionDescriptionRequiredDefault
-i, --idDataset unique identifier(s). May be combined with --name.Yes
-n, --nameDataset name(s). May be combined with --id.Yes
-w, --workspaceWorkspace numeric identifier or reference in OrganizationName/WorkspaceName format (defaults to TOWER_WORKSPACE_ID environment variable)Yes

tw datasets labels

Manage dataset labels

tw datasets labels [OPTIONS] [labels]

Arguments

ArgumentDescriptionRequired
&lt;labels&gt;Comma-separated list of labels.No

Options

OptionDescriptionRequiredDefault
-i, --idDataset unique identifierYes
-n, --nameDataset nameYes
-w, --workspaceWorkspace numeric identifier or reference in OrganizationName/WorkspaceName format (defaults to TOWER_WORKSPACE_ID environment variable)No
--no-createAssign labels without creating the ones which were not found.No
--operations, -oType of operation (set, append, delete) [default: set].Noset

tw datasets list

List datasets

tw datasets list [OPTIONS]

Options

OptionDescriptionRequiredDefault
-w, --workspaceWorkspace numeric identifier or reference in OrganizationName/WorkspaceName format (defaults to TOWER_WORKSPACE_ID environment variable)Yes
-f, --filterOptional filter criteria, allowing free text search on name or ID and keywords: username, label, visibility, createdAfter, createdBefore, usedAfter, usedBefore. Example keyword usage: -f label:custom-label.No
--show-hiddenInclude datasets marked as hidden in the results.Nofalse
-l, --labelsShow labels.Nofalse
--pagePage number for paginated results (default: 1)No
--offsetRow offset for paginated results (default: 0)No
--maxMaximum number of records to display (default: 100)No

Run tw datasets list -h to view the optional fields for listing and filtering datasets.

Command:

tw datasets list -f data

Datasets at 97652229034604 workspace:

Example output:

ID                     | Name     | Created
------------------------+----------+-------------------------------
6vBGj6aWWpBuLpGKjJDpZy | dataset2 | Tue, 27 Aug 2024 14:49:32 GMT

tw datasets show

Make one or more hidden datasets visible

tw datasets show [OPTIONS]

Options

OptionDescriptionRequiredDefault
-i, --idDataset unique identifier(s). May be combined with --name.Yes
-n, --nameDataset name(s). May be combined with --id.Yes
-w, --workspaceWorkspace numeric identifier or reference in OrganizationName/WorkspaceName format (defaults to TOWER_WORKSPACE_ID environment variable)Yes

tw datasets view

View dataset details

tw datasets view [OPTIONS]

Options

OptionDescriptionRequiredDefault
-i, --idDataset unique identifierYes
-n, --nameDataset nameYes
-w, --workspaceWorkspace numeric identifier or reference in OrganizationName/WorkspaceName format (defaults to TOWER_WORKSPACE_ID environment variable)Yes

Run tw datasets view -h to view the required and optional fields for viewing a stored dataset's details.

Command:

tw datasets view -n samplesheet1

Dataset at 97652229034604 workspace:

Example output:

-------------+-------------------------------
ID | 60gGrD4I2Gk0TUpEGOj5Td
Name | samplesheet1
Description |
Media Type | text/csv
Created | Mon, 19 Aug 2024 07:59:16 GMT
Updated | Mon, 19 Aug 2024 07:59:17 GMT

tw datasets view versions

Display dataset versions.

tw datasets view versions

tw datasets update

Update a dataset

tw datasets update [OPTIONS]

Options

OptionDescriptionRequiredDefault
-i, --idDataset unique identifierYes
-n, --nameDataset nameYes
--new-nameUpdated dataset name. Must be unique per workspace. Names consist of alphanumeric, hyphen, and underscore characters.No
-d, --descriptionUpdated dataset description.No
--headerTreat first row as headerNo
-f, --fileData file to uploadNo
-w, --workspaceWorkspace numeric identifier or reference in OrganizationName/WorkspaceName format (defaults to TOWER_WORKSPACE_ID environment variable)Yes

Run tw datasets update -h to view the required and optional fields for updating a dataset.

tw datasets update -n dataset1 --new-name=dataset2 -f samplesheet_test.csv

Dataset 'dataset1' updated at 97652229034604 workspace with id '6vBGj6aWWpBuLpGKjJDpZy'

tw datasets url

Get dataset URL

tw datasets url [OPTIONS]

Options

OptionDescriptionRequiredDefault
-i, --idDataset unique identifierYes
-n, --nameDataset nameYes
--dataset-versionDataset version for URLNo
-w, --workspaceWorkspace numeric identifier or reference in OrganizationName/WorkspaceName format (defaults to TOWER_WORKSPACE_ID environment variable)Yes

Run tw datasets url -h to view the required and optional fields for obtaining a dataset URL.

$ tw datasets url -n dataset2

Dataset URL

-----------

https://api.cloud.seqera.io/workspaces/97652229034xxx/datasets/6vBGj6aWWpBuLpGKjJDxxx/v/2/n/samplesheet_test.csv