From: radar on 5 May 2010 18:57 In a loop where sql queries are returning one table for each day of data (100,000 rows), can I dynamically declare and name the matrix to store the query result? For example, I'd like to name each matrix with the date of the query like this: mname = sprintf('mat-%s', datestr(t0(k),'mmm-dd-yyyy')); but I don't know how, or if it is possible, to dynamically create a new matrix variable and name it as shown in each loop iteration.
From: Walter Roberson on 5 May 2010 23:22 radar wrote: > but I don't know how, or if it is possible, to dynamically create a new matrix variable and name it as shown in each loop iteration. Don't Do That. http://matlabwiki.mathworks.com/MATLAB_FAQ#How_can_I_create_variables_A1.2C_A2.2C....2CA10_in_a_loop.3F
From: radar on 6 May 2010 02:33 thanks so much for getting me straight on that in the last few days, you've made my program so much better for k = 1:1000 disp('THANK YOU WALTER!!'); end;
|
Pages: 1 Prev: Image processing problems Next: help me in syntax problem |