docs / data_structures / read_group / inner_read_group_to_string
Task

inner_read_group_to_string

Converts a ReadGroup struct to a String without any validation.
WDL Version
1.1
RUN WITH

sprocket run --name inner_read_group_to_string data_structures/read_group.wdldata_structures\read_group.wdl [INPUTS]...

Inputs

Required Inputs

Name
Type
Description
read_group
ReadGroup
ReadGroup struct to stringify
ReadGroup struct to stringify

Other Inputs

Name
Type
Default
Description
format_as_sam_record
Boolean
false
Format the `ReadGroup` as a SAM record? If `true`, the read group string will be...
Format the ReadGroup as a SAM record? If true, the read group string will be prefixed with @RG and tab delimiters will be used instead of space delimiters.
false

Outputs

Name
Type
Expression
Description
stringified_read_group
String
read_string("out.txt")
Input ReadGroup as a string
Input ReadGroup as a string
read_string("out.txt")

Default Runtime Attributes

Attribute
Value
memory
"4 GB"
disks
"10 GB"
container
"ghcr.io/stjudecloud/util:2.2.1"
maxRetries
1

Command

if ~{format_as_sam_record}; then echo -n "@RG~{delimiter}" > out.txt fi { echo -n "~{"ID:~{read_group.ID}"}" # required field. All others optional # if any individual placeholder of an interpolated String evaluates to None # the entire parent String will evaluate to the empty String. echo -n "~{"~{delimiter}BC:~{read_group.BC}"}" echo -n "~{"~{delimiter}CN:~{read_group.CN}"}" echo -n "~{"~{delimiter}DS:~{read_group.DS}"}" echo -n "~{"~{delimiter}DT:~{read_group.DT}"}" echo -n "~{"~{delimiter}FO:~{read_group.FO}"}" echo -n "~{"~{delimiter}KS:~{read_group.KS}"}" echo -n "~{"~{delimiter}LB:~{read_group.LB}"}" echo -n "~{"~{delimiter}PG:~{read_group.PG}"}" echo -n "~{"~{delimiter}PI:~{read_group.PI}"}" echo -n "~{"~{delimiter}PL:~{read_group.PL}"}" echo -n "~{"~{delimiter}PM:~{read_group.PM}"}" echo -n "~{"~{delimiter}PU:~{read_group.PU}"}" echo "~{"~{delimiter}SM:~{read_group.SM}"}" } >> out.txt