<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Proc IML Full Factorial Matrix in SAS/IML Software and Matrix Computations</title>
    <link>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/600492#M4894</link>
    <description>&lt;P&gt;If you do not need the individual elements but only the binary bit pattern, you can save quite a bit of memory by using a character string instead of a vector of 0/1 values. For example, compare BAND versus PUTN with a BINARYw. format:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc iml;
n = 2##20;
x = band(n, 2##(20:0)) &amp;gt; 0;
print x;
y = putn(n, "binary20.");
print y;
&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;For more examples and discussion, see &lt;A href="https://blogs.sas.com/content/iml/2011/01/05/creating-a-matrix-with-all-combinations-of-zeros-and-ones.html" target="_self"&gt;"Creating a matrix with all combinations of zeros and ones."&lt;/A&gt;&lt;/P&gt;</description>
    <pubDate>Wed, 30 Oct 2019 18:24:36 GMT</pubDate>
    <dc:creator>Rick_SAS</dc:creator>
    <dc:date>2019-10-30T18:24:36Z</dc:date>
    <item>
      <title>Proc IML Full Factorial Matrix</title>
      <link>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/599458#M4876</link>
      <description>&lt;P&gt;HI;&lt;/P&gt;&lt;P&gt;I would like to create a matrix reflecting a full factorial design. This would have the following structure&lt;/P&gt;&lt;P&gt;3 factors&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;0 0 1&lt;/P&gt;&lt;P&gt;0 1 0&lt;/P&gt;&lt;P&gt;1 0 0&lt;/P&gt;&lt;P&gt;0 1 1&lt;/P&gt;&lt;P&gt;1 1 0&lt;/P&gt;&lt;P&gt;1 0 1&lt;/P&gt;&lt;P&gt;1 1 1&lt;/P&gt;&lt;P&gt;I tried using allcomb but couldn't get&amp;nbsp; a matrix like the above.&amp;nbsp; Thanks&lt;/P&gt;</description>
      <pubDate>Fri, 25 Oct 2019 21:57:46 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/599458#M4876</guid>
      <dc:creator>Sanscrit_2prov</dc:creator>
      <dc:date>2019-10-25T21:57:46Z</dc:date>
    </item>
    <item>
      <title>Re: Proc IML Full Factorial Matrix</title>
      <link>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/599468#M4877</link>
      <description>&lt;P&gt;You can generate a full factorial matrix in PROC PLAN and then read it into IML if you need it there. SAS has done the work to generate all sorts of designs, so you don't have to. It's also simple to do via looping in a DATA step, and of course you could do similar looping in IML.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 25 Oct 2019 23:12:14 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/599468#M4877</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2019-10-25T23:12:14Z</dc:date>
    </item>
    <item>
      <title>Re: Proc IML Full Factorial Matrix</title>
      <link>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/599474#M4878</link>
      <description>&lt;P&gt;May I ask, why do you want to do this? Seems like its a part of a larger problem?&lt;/P&gt;</description>
      <pubDate>Fri, 25 Oct 2019 23:02:39 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/599474#M4878</guid>
      <dc:creator>PeterClemmensen</dc:creator>
      <dc:date>2019-10-25T23:02:39Z</dc:date>
    </item>
    <item>
      <title>Re: Proc IML Full Factorial Matrix</title>
      <link>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/599514#M4879</link>
      <description>&lt;P&gt;Use the function EXPANDGRID it does exactly what you want, provided you have 15 factors or less.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;  x = expandgrid(0:1, 0:1, 0:1);
  print x;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Sat, 26 Oct 2019 07:18:49 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/599514#M4879</guid>
      <dc:creator>IanWakeling</dc:creator>
      <dc:date>2019-10-26T07:18:49Z</dc:date>
    </item>
    <item>
      <title>Re: Proc IML Full Factorial Matrix</title>
      <link>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/599832#M4881</link>
      <description>&lt;P&gt;Unfortunately I have I can have more than 15 factors as they are combinations of covariate patterns. I did see Proc Factex and will check that out also. Thank you&lt;/P&gt;</description>
      <pubDate>Mon, 28 Oct 2019 15:08:34 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/599832#M4881</guid>
      <dc:creator>Sanscrit_2prov</dc:creator>
      <dc:date>2019-10-28T15:08:34Z</dc:date>
    </item>
    <item>
      <title>Re: Proc IML Full Factorial Matrix</title>
      <link>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/599843#M4882</link>
      <description>&lt;P&gt;Thank you I am looking at both Proc Plan and Proc Factex, but they have some limits in terms of number of factors, It would be nice to be able to do this with loops and I have played around with the program below, but instead of outputting observations in the data step I would like to work solely in IML and generate a matrix. instead, Below is what I have so far. Thanks. I have more work to do!&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;data design;&lt;BR /&gt;do i=1 to 4;&lt;BR /&gt;do j=1 to 4;&lt;BR /&gt;output;&lt;BR /&gt;end;&lt;BR /&gt;end;&lt;BR /&gt;run;&lt;BR /&gt;proc print data=design;&lt;BR /&gt;run;&lt;BR /&gt;PROC IML;&lt;BR /&gt;USE design;&lt;BR /&gt;read all var _num_ into m [colname=varnames];&lt;BR /&gt;l=rowvec(m);&lt;BR /&gt;print (l);&lt;BR /&gt;run;&lt;BR /&gt;quit;&lt;/P&gt;</description>
      <pubDate>Mon, 28 Oct 2019 15:38:42 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/599843#M4882</guid>
      <dc:creator>Sanscrit_2prov</dc:creator>
      <dc:date>2019-10-28T15:38:42Z</dc:date>
    </item>
    <item>
      <title>Re: Proc IML Full Factorial Matrix</title>
      <link>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/599844#M4883</link>
      <description>&lt;P&gt;I am recoding a Matlab program into SAS code. So I am learning IML for the first time.&lt;/P&gt;</description>
      <pubDate>Mon, 28 Oct 2019 15:39:30 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/599844#M4883</guid>
      <dc:creator>Sanscrit_2prov</dc:creator>
      <dc:date>2019-10-28T15:39:30Z</dc:date>
    </item>
    <item>
      <title>Re: Proc IML Full Factorial Matrix</title>
      <link>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/599845#M4884</link>
      <description>&lt;P&gt;If the factors all have 2 levels then the full factorial is nothing more than counting in binary.&amp;nbsp; So you could use something like this:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;x = j(8,3);
do i = 1 to 8;
  x[i, ] = band(i-1, {4 2 1}) &amp;gt; 0;
end;
print x;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Mon, 28 Oct 2019 15:49:35 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/599845#M4884</guid>
      <dc:creator>IanWakeling</dc:creator>
      <dc:date>2019-10-28T15:49:35Z</dc:date>
    </item>
    <item>
      <title>Re: Proc IML Full Factorial Matrix</title>
      <link>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/599848#M4885</link>
      <description>&lt;P&gt;Do you know that you can get the missing value pattern matrix from PROC MI?&lt;/P&gt;
&lt;P&gt;&lt;A href="https://blogs.sas.com/content/iml/2016/04/18/patterns-of-missing-data-in-sas.html" target="_self"&gt;"Examine patterns of missing data in SAS"&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;If the data matrix is not too big, you can use heat maps to&lt;A href="https://blogs.sas.com/content/iml/2017/11/29/visualize-patterns-missing-values.html" target="_self"&gt; visualize the missing data patterns.&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 28 Oct 2019 15:53:29 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/599848#M4885</guid>
      <dc:creator>Rick_SAS</dc:creator>
      <dc:date>2019-10-28T15:53:29Z</dc:date>
    </item>
    <item>
      <title>Re: Proc IML Full Factorial Matrix</title>
      <link>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/599908#M4886</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/295602"&gt;@Sanscrit_2prov&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;Unfortunately I have I can have more than 15 factors as they are combinations of covariate patterns. I did see Proc Factex and will check that out also. Thank you&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Wait a second ... full factorial with more than 15 factors? That will be huge, even if it is a 2-level design. And this is the first time you have mentioned covariates ... a full factorial with covariates, how are the covariates to be handled? Are they part of the full factorial?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Please explain this.&lt;/P&gt;</description>
      <pubDate>Mon, 28 Oct 2019 19:06:30 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/599908#M4886</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2019-10-28T19:06:30Z</dc:date>
    </item>
    <item>
      <title>Re: Proc IML Full Factorial Matrix</title>
      <link>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/599909#M4887</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/295602"&gt;@Sanscrit_2prov&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;Thank you I am looking at both Proc Plan and Proc Factex,&amp;nbsp;but they have some limits in terms of number of factors,&amp;nbsp;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;I am not aware of a limitation on the number of factors in PROC PLAN. There's nothing in the documentation stating a limit. Why do you say this?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;BLOCKQUOTE&gt;
&lt;P&gt;but instead of outputting observations in the data step I would like to work solely in IML and generate a matrix.&lt;/P&gt;
&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Yes, looping in IML can give you a full factorial, but the idea of not using SAS data steps (or did you mean not using SAS data sets?) is one that will make your life miserable. SAS is designed around the concept of a data step, and around data sets, and unless you are determined to do everything in IML, you can't (and shouldn't) avoid using data sets and data steps.&lt;/P&gt;</description>
      <pubDate>Mon, 28 Oct 2019 19:12:11 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/599909#M4887</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2019-10-28T19:12:11Z</dc:date>
    </item>
    <item>
      <title>Re: Proc IML Full Factorial Matrix</title>
      <link>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/599915#M4888</link>
      <description>&lt;P&gt;We are just using the design matrix to indicate the presence or absence of binary (present/absent) predictors (or covariates). I should have been clearer that this isn't an experiment. It is a program looking at average attributable risk over different patterns of predictors. The matrix tells us which predictors are present, It is then used in further matrix operations that multiply the beta coefficients for the predictors that are present, and the resulting sum is used in further calculations.&lt;/P&gt;</description>
      <pubDate>Mon, 28 Oct 2019 19:19:49 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/599915#M4888</guid>
      <dc:creator>Sanscrit_2prov</dc:creator>
      <dc:date>2019-10-28T19:19:49Z</dc:date>
    </item>
    <item>
      <title>Re: Proc IML Full Factorial Matrix</title>
      <link>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/599916#M4889</link>
      <description>&lt;P&gt;Yes I should have clarified. I use a SAS dataset read into an IML matrix.&lt;/P&gt;</description>
      <pubDate>Mon, 28 Oct 2019 19:22:28 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/599916#M4889</guid>
      <dc:creator>Sanscrit_2prov</dc:creator>
      <dc:date>2019-10-28T19:22:28Z</dc:date>
    </item>
    <item>
      <title>Re: Proc IML Full Factorial Matrix</title>
      <link>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/599918#M4890</link>
      <description>&lt;BLOCKQUOTE&gt;
&lt;P&gt;&lt;SPAN&gt;The matrix tells us which predictors are present, It is then used in further matrix operations that multiply the beta coefficients for the predictors that are present&lt;/SPAN&gt;&lt;/P&gt;
&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;This is what PROC SCORE does. SAS has done the hard work of programming this specific type of matrix calculation, so you don't have to. They have tested it thoroughly and debugged it.&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 28 Oct 2019 19:28:01 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/599918#M4890</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2019-10-28T19:28:01Z</dc:date>
    </item>
    <item>
      <title>Re: Proc IML Full Factorial Matrix</title>
      <link>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/599923#M4891</link>
      <description>&lt;P&gt;I don't understand what the data look like. Could you please provide an example data set (or matrix) that has three columns and five observations, and also supply the result that you expect to get?&lt;/P&gt;</description>
      <pubDate>Mon, 28 Oct 2019 19:39:28 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/599923#M4891</guid>
      <dc:creator>Rick_SAS</dc:creator>
      <dc:date>2019-10-28T19:39:28Z</dc:date>
    </item>
    <item>
      <title>Re: Proc IML Full Factorial Matrix</title>
      <link>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/600454#M4892</link>
      <description>&lt;P&gt;Thank you so much. This is exactly what I needed and was unaware of the band function.&lt;/P&gt;</description>
      <pubDate>Wed, 30 Oct 2019 16:59:21 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/600454#M4892</guid>
      <dc:creator>Sanscrit_2prov</dc:creator>
      <dc:date>2019-10-30T16:59:21Z</dc:date>
    </item>
    <item>
      <title>Re: Proc IML Full Factorial Matrix</title>
      <link>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/600456#M4893</link>
      <description>&lt;P&gt;Thank you. Ian Wakeling solved my problem,&lt;/P&gt;</description>
      <pubDate>Wed, 30 Oct 2019 17:02:04 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/600456#M4893</guid>
      <dc:creator>Sanscrit_2prov</dc:creator>
      <dc:date>2019-10-30T17:02:04Z</dc:date>
    </item>
    <item>
      <title>Re: Proc IML Full Factorial Matrix</title>
      <link>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/600492#M4894</link>
      <description>&lt;P&gt;If you do not need the individual elements but only the binary bit pattern, you can save quite a bit of memory by using a character string instead of a vector of 0/1 values. For example, compare BAND versus PUTN with a BINARYw. format:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc iml;
n = 2##20;
x = band(n, 2##(20:0)) &amp;gt; 0;
print x;
y = putn(n, "binary20.");
print y;
&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;For more examples and discussion, see &lt;A href="https://blogs.sas.com/content/iml/2011/01/05/creating-a-matrix-with-all-combinations-of-zeros-and-ones.html" target="_self"&gt;"Creating a matrix with all combinations of zeros and ones."&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 30 Oct 2019 18:24:36 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/600492#M4894</guid>
      <dc:creator>Rick_SAS</dc:creator>
      <dc:date>2019-10-30T18:24:36Z</dc:date>
    </item>
    <item>
      <title>Re: Proc IML Full Factorial Matrix</title>
      <link>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/601162#M4895</link>
      <description>&lt;P&gt;I have a question.&lt;/P&gt;&lt;P&gt;Your code results in one row with 21 columns and the first column is a 1&lt;/P&gt;&lt;P&gt;How do I get all of the rows with the different columns equal to 1?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;So let's say it was 4.&lt;/P&gt;&lt;P&gt;0000&lt;/P&gt;&lt;P&gt;0001&lt;/P&gt;&lt;P&gt;0010&lt;/P&gt;&lt;P&gt;etc&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 02 Nov 2019 18:24:37 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/601162#M4895</guid>
      <dc:creator>Sanscrit_2prov</dc:creator>
      <dc:date>2019-11-02T18:24:37Z</dc:date>
    </item>
    <item>
      <title>Re: Proc IML Full Factorial Matrix</title>
      <link>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/601215#M4896</link>
      <description>&lt;P&gt;If you use the 'band' method, it only really makes sense to fill the matrix one row at a time as I have shown.&amp;nbsp;&amp;nbsp; I think Rick's point is mainly about storage space.&amp;nbsp; As Paige has pointed out, the full-factorial matrix is going to be huge when you are looking at 2^16 or higher, and if you can manage with a character matrix, it will be reduce the memory requirement by a factor of 8.&amp;nbsp;&amp;nbsp; I have put both methods in to general modules below, so you can experiment.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc iml;

start FullFactorial( n );
  r = 2 ## n;
  x = j(r, n);
  pot = 2 ## ( (n-1):0 );
  do i = 1 to r;
    x[i, ] = band( i-1, pot ) &amp;gt; 0;
  end;
  return( x );
finish;

start FFstr( n );
  fmt = cats("binary",char(n),".");
  return( putn( t( 0:(2##n - 1) ), fmt) );
finish;

a = FullFactorial( 4 );
print a;

b = FFstr( 4 );
print b;
  
quit;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 03 Nov 2019 09:32:50 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/Proc-IML-Full-Factorial-Matrix/m-p/601215#M4896</guid>
      <dc:creator>IanWakeling</dc:creator>
      <dc:date>2019-11-03T09:32:50Z</dc:date>
    </item>
  </channel>
</rss>

