Closed MostafaYA closed 1 year ago
Don't leave spaces in ${}
, and note the quotes.
$ cat test.tsv \
| csvtk mutate2 -t -e "\$f1 + '_' + \$ref + '_' + \$f2 + '_' + \${$sample}" -n position \
| csvtk pretty -t
Gene_position ref IP-e-D-1-9 f1 f2 position
------------- --- ---------- ---- -- -----------
gyrA_43 V V gyrA 43 gyrA_V_43_V
gyrA_71 D D gyrA 71 gyrA_D_71_D
thanks!!
Prerequisites
csvtk version
Describe your issue
Hi, I am using
csvtk mutate2
as a part of a script to concatenate results of multiple columns. I take sample name as a variable but special character makes a problem hereThank you
I'm grateful to users who have greatly helped to report bugs and suggested new features.
I may respond to issues or fix bugs quickly, but I usually implement new features periodically (two or more weeks).