Search Results

Search: Posts Made By: thienxho
1,339
Posted By rdrtx1
try: awk ' NR==FNR {a[$1]=$2; next;} {c=0;...
try:
awk '
NR==FNR {a[$1]=$2; next;}
{c=0; for (i=1; i<=NF; i++) {for (s in a) if ($0 ~ s && c==0) {sub(s, a[s]); c=1}}}
1
' species-names.txt sequence-names.txt
3,101
Posted By vgersh99
awk -f thie.awk myFile where thie.awk is: ...
awk -f thie.awk myFile
where thie.awk is:

BEGIN {
if (!chars) chars="A T G C"
nchars=split(chars, charsA, FS)
}
{
width=length($2)
for(i=1;i<=width;i++)
arr[substr($2,i,1),i]++...
Showing results 1 to 2 of 2

 
All times are GMT -4. The time now is 04:15 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy