With a lot of help from Jarmo, I got an Associative Array (aa) of columns that are linked. Next, I need to plot those, is that easily done
Names Default To Here(1);
startchar1 = "VT";
startchar2 = "ID";
rgx_startchar1 = Eval Insert("^startchar1^(.+?)$");
dt = Current Data Table();
collist = dt << get column names(string);
VT_IDcols = {};
For( i = 1, i <= N Items( collist ), i++,
If( !Contains( collist[i], "Pass/Fail"), If( Contains( collist[i], "VT") | Contains( collist[i], "ID") , Insert Into( VT_IDcols, collist[i] ))));
aa = Associative Array();
For Each({colname}, VT_IDcols,
col_ptrn = Regex(colname, rgx_startchar1, "\1");
If(!IsMissing(col_ptrn), // starts with VT and ends with H
If(Contains(VT_IDcols, startchar2 || col_ptrn ),
aa[startchar1 || col_ptrn] = startchar2 || col_ptrn;
);
);
);