<?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: Discrete Choice Experiment Partial Profil Design with varying number of levels in Statistical Procedures</title>
    <link>https://communities.sas.com/t5/Statistical-Procedures/Discrete-Choice-Experiment-Partial-Profil-Design-with-varying/m-p/639016#M30582</link>
    <description>&lt;P&gt;Sorry for the late response, but I am retired, so I don't pay as much attention to SAS Communities as I did when I was employed. Here is a minor variation of the example starting on page 604. I added a 4 and 5-level factor. The rest are 3-levels.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;title ’Partial Profiles’;&lt;/P&gt;
&lt;P&gt;%macro partprof;&lt;BR /&gt;sum = 0;&lt;BR /&gt;do k = 1 to 10;&lt;BR /&gt;sum = sum + (x[k] = x[k+10] &amp;amp; x[k] = x[k+20]);&lt;BR /&gt;end;&lt;BR /&gt;bad = abs(sum - 4);&lt;BR /&gt;%mend;&lt;/P&gt;
&lt;P&gt;%mktex(3 4 5 3 ** 7 3 4 5 3 ** 7 3 4 5 3 ** 7 , &lt;BR /&gt;n=200, /* 200 runs */&lt;BR /&gt;options=quickr /* very quick run with random init */&lt;BR /&gt;noqc&lt;BR /&gt;nox, /* suppress x1, x2, ... creation */&lt;BR /&gt;order=random, /* loop over columns in a random order */&lt;BR /&gt;out=cand, /* output design stored permanently */&lt;BR /&gt;restrictions=partprof, /* name of restrictions macro */&lt;BR /&gt;seed=382) /* random number seed */&lt;/P&gt;
&lt;P&gt;%mktkey(3 10)&lt;/P&gt;
&lt;P&gt;%mktroll(design=cand, key=key, out=rolled)&lt;/P&gt;
&lt;P&gt;%mktdups(generic, data=rolled, out=nodups, factors=x1-x10, nalts=3)&lt;BR /&gt;proc print data=nodups(obs=9); id set; by set; run;&lt;/P&gt;
&lt;P&gt;%choiceff(data=nodups, /* candidate set of choice sets */&lt;BR /&gt;model=class(x1-x10 / sta),/* model with stdzd orthogonal coding */&lt;BR /&gt;seed=448, /* random number seed */&lt;BR /&gt;maxiter=10, /* maximum iterations for each phase */&lt;BR /&gt;nsets=27, /* number of choice sets */&lt;BR /&gt;nalts=3, /* number of alternatives */&lt;BR /&gt;options=nodups /* no duplicate choice sets */&lt;BR /&gt;relative, /* display relative D-efficiency */&lt;BR /&gt;beta=zero) /* assumed beta vector, Ho: b=0 */&lt;/P&gt;
&lt;P&gt;proc print data=best; id set; by notsorted set; var x1-x10; run;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 10 Apr 2020 16:56:56 GMT</pubDate>
    <dc:creator>WarrenKuhfeld</dc:creator>
    <dc:date>2020-04-10T16:56:56Z</dc:date>
    <item>
      <title>Discrete Choice Experiment Partial Profil Design with varying number of levels</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Discrete-Choice-Experiment-Partial-Profil-Design-with-varying/m-p/637627#M30498</link>
      <description>&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;I am trying to create a Discrete Choice Experiment with a Partial Profile Design from 16 Attributes. 6 with two levels and 10 with 3 levels. I successfully created a design with either all two level or all three level attributes using the Instructions provided by &lt;A href="https://support.sas.com/techsup/technote/mr2010.pdf" target="_self"&gt;Kuhfeld 2010&lt;/A&gt;, by first creating a BIBD (or unbalanced block design) and then an orthogonal Array to build the partial profile design. But it doesn’t seem to be possible to have attributes with different numbers of levels. Does anyone know how or wether this is possible with SAS?&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Attached find the working code for 16 three level attributes:&lt;/P&gt;&lt;PRE&gt;%mktbibd(b=8, nattrs=16, setsize=6, seed=17) /*create BIBD */
%mktex(18 3 ** 6, n=54, seed=306) /* create orthogonal Array with one 18 level (dropped later) and six (=&amp;lt;setsize) 3 level */
proc sort data=randomized out=randes(drop=x1);
by x2 x1;
run;
proc print noobs data=randes; run;
%mktppro(design=randes, ibd=bibd) /* create partial profile design */

%choiceff(data=chdes, /* candidate set of choice sets */
init=chdes, /* initial design */
initvars=x1-x16, /* factors in the initial design */
model=class(x1-x16 / sta),/* model with stdz orthogonal coding */
nsets=144, /* number of choice sets */
nalts=3, /* number of alternatives */
rscale= /* relative D-efficiency scale factor */
%sysevalf(144 * 6 / 16), /* 6 of 16 attrs in 144 sets vary */
beta=zero) /* assumed beta vector, Ho: b=0 */

%mktblock(data=chdes, /* input choice design to block */
out=finalBlock, /* output blocked choice design */
/* stored in permanent SAS data set */
nalts=3, /* three alternatives */
nblocks=12, /* twelve blocks */
factors=x1-x16, /* 16 attributes, x1-x16 */
print=design, /* print the blocked design (only) */
seed=472) /* random number seed */&lt;/PRE&gt;</description>
      <pubDate>Sat, 04 Apr 2020 20:40:57 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Discrete-Choice-Experiment-Partial-Profil-Design-with-varying/m-p/637627#M30498</guid>
      <dc:creator>eifelracerpat</dc:creator>
      <dc:date>2020-04-04T20:40:57Z</dc:date>
    </item>
    <item>
      <title>Re: Discrete Choice Experiment Partial Profil Design with varying number of levels</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Discrete-Choice-Experiment-Partial-Profil-Design-with-varying/m-p/637673#M30501</link>
      <description>&lt;P&gt;Kuhfeld (2010) has lots of examples. Some show how to use combinatorial methods--orthogonal arrays and BIBDs-- to make *optimal* designs. Others show how to use computerized searches and restrictions to create the more complicated and gnarley designs researcher need in practice.&lt;/P&gt;</description>
      <pubDate>Sun, 05 Apr 2020 11:44:15 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Discrete-Choice-Experiment-Partial-Profil-Design-with-varying/m-p/637673#M30501</guid>
      <dc:creator>WarrenKuhfeld</dc:creator>
      <dc:date>2020-04-05T11:44:15Z</dc:date>
    </item>
    <item>
      <title>Re: Discrete Choice Experiment Partial Profil Design with varying number of levels</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Discrete-Choice-Experiment-Partial-Profil-Design-with-varying/m-p/638415#M30549</link>
      <description>&lt;P&gt;Dear Mr. Kuhfeld thank you very much for your reply. I am terribly sorry to bother you again with this, but I cant seem to find a solution with the given literature.&lt;/P&gt;&lt;P&gt;If you could just provide me with the means to create a partial profile design where some attributes have x levels and some have y levels with x&amp;lt;y that would already help me solve my problem.&lt;/P&gt;</description>
      <pubDate>Wed, 08 Apr 2020 17:42:46 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Discrete-Choice-Experiment-Partial-Profil-Design-with-varying/m-p/638415#M30549</guid>
      <dc:creator>eifelracerpat</dc:creator>
      <dc:date>2020-04-08T17:42:46Z</dc:date>
    </item>
    <item>
      <title>Re: Discrete Choice Experiment Partial Profil Design with varying number of levels</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Discrete-Choice-Experiment-Partial-Profil-Design-with-varying/m-p/639016#M30582</link>
      <description>&lt;P&gt;Sorry for the late response, but I am retired, so I don't pay as much attention to SAS Communities as I did when I was employed. Here is a minor variation of the example starting on page 604. I added a 4 and 5-level factor. The rest are 3-levels.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;title ’Partial Profiles’;&lt;/P&gt;
&lt;P&gt;%macro partprof;&lt;BR /&gt;sum = 0;&lt;BR /&gt;do k = 1 to 10;&lt;BR /&gt;sum = sum + (x[k] = x[k+10] &amp;amp; x[k] = x[k+20]);&lt;BR /&gt;end;&lt;BR /&gt;bad = abs(sum - 4);&lt;BR /&gt;%mend;&lt;/P&gt;
&lt;P&gt;%mktex(3 4 5 3 ** 7 3 4 5 3 ** 7 3 4 5 3 ** 7 , &lt;BR /&gt;n=200, /* 200 runs */&lt;BR /&gt;options=quickr /* very quick run with random init */&lt;BR /&gt;noqc&lt;BR /&gt;nox, /* suppress x1, x2, ... creation */&lt;BR /&gt;order=random, /* loop over columns in a random order */&lt;BR /&gt;out=cand, /* output design stored permanently */&lt;BR /&gt;restrictions=partprof, /* name of restrictions macro */&lt;BR /&gt;seed=382) /* random number seed */&lt;/P&gt;
&lt;P&gt;%mktkey(3 10)&lt;/P&gt;
&lt;P&gt;%mktroll(design=cand, key=key, out=rolled)&lt;/P&gt;
&lt;P&gt;%mktdups(generic, data=rolled, out=nodups, factors=x1-x10, nalts=3)&lt;BR /&gt;proc print data=nodups(obs=9); id set; by set; run;&lt;/P&gt;
&lt;P&gt;%choiceff(data=nodups, /* candidate set of choice sets */&lt;BR /&gt;model=class(x1-x10 / sta),/* model with stdzd orthogonal coding */&lt;BR /&gt;seed=448, /* random number seed */&lt;BR /&gt;maxiter=10, /* maximum iterations for each phase */&lt;BR /&gt;nsets=27, /* number of choice sets */&lt;BR /&gt;nalts=3, /* number of alternatives */&lt;BR /&gt;options=nodups /* no duplicate choice sets */&lt;BR /&gt;relative, /* display relative D-efficiency */&lt;BR /&gt;beta=zero) /* assumed beta vector, Ho: b=0 */&lt;/P&gt;
&lt;P&gt;proc print data=best; id set; by notsorted set; var x1-x10; run;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 10 Apr 2020 16:56:56 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Discrete-Choice-Experiment-Partial-Profil-Design-with-varying/m-p/639016#M30582</guid>
      <dc:creator>WarrenKuhfeld</dc:creator>
      <dc:date>2020-04-10T16:56:56Z</dc:date>
    </item>
    <item>
      <title>Re: Discrete Choice Experiment Partial Profil Design with varying number of levels</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Discrete-Choice-Experiment-Partial-Profil-Design-with-varying/m-p/639440#M30596</link>
      <description>Thank you very much, this worked perfectly for my problem.</description>
      <pubDate>Mon, 13 Apr 2020 11:54:18 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Discrete-Choice-Experiment-Partial-Profil-Design-with-varying/m-p/639440#M30596</guid>
      <dc:creator>eifelracerpat</dc:creator>
      <dc:date>2020-04-13T11:54:18Z</dc:date>
    </item>
  </channel>
</rss>

