Hi all, I worked around a script that would loop around column names and find the ones I want to use. It then finds the row number and the value of that cell. However, I find that these values are repeated for every column. Can anybody point me out to where I might be going wrong?
Here is the script:
dt = current data table();
col = dt << get column names( string );
nc = N Items( col );
Row = 1;
For( i = 1, i <= nc, i++,
for(r=1, r<=NRow(dt), r++,
Col1 = Column(dt,i);
If( Contains( col[i], "Prediction" ),
If(Column(dt, col[i])[r] > 5 | Column(dt, col[i])[r] > 4.5,
show(col[i]);
val = abs(Col Max( Col1 ));
show(val);
MaxRow = dt << get rows where(as column(Col1)==abs(Col Max( Col1 )));
show(MaxRow);
)
)
)
); <BR /><BR />The log looks like this:<BR /><BR />col[i] = "Prediction B";<BR />val = 6.6;<BR />MaxRow = [6];<BR />col[i] = "Prediction B";<BR />val = 6.6;<BR />MaxRow = [6];<BR />col[i] = "Prediction B";<BR />val = 6.6;<BR />MaxRow = [6];<BR />col[i] = "Prediction C";<BR />val = 5;<BR />MaxRow = [1];<BR />