I extract data, process data along production line, from a database that return data as couples parameter-value (value can be missing).
I use a table split to have data with parameter as column (more missing are expected in many columns).
Then I run a script to convert character to numerical when appropriate.
The problem is that the number of columns can be very high, in my example around 60000 (11 row in the example)
So, in my example, I have 8 seconds to get back data from database,
18 seconds to apply the algorithm that check all column that become 80 seconds to transform the column too.
Can anyone suggest a more efficient way to have the final result?
This is the algorithm that I have used:
names = <FONT face="Courier New" size="3">current data table()</FONT> << Get Column Names( Character, String );
for(I = 1, I <=N items(names), I++,
values= column( names[I]) << get values;
numerical=1;
for(j=1, j<=N items(values),j++,
if(!Is Missing(values[j]) & Is Missing( Num(values[j]) ),
numerical=0;
break();
);
);
if(numerical,
column( names[I]) << data Type("Numeric") << set Modeling Type ("Continuous");
);
);