Hi Koen @sbxkoenk I have tried the Proc BCHOICE as well and it didn't work. I was basing my code off of document MR2010F found a this link https://support.sas.com/resources/papers/tnote/tnote_marketresearch.html Here is my code. I used the same data as in the original post so I didn't repost it here. Data ChoiceBTM;
Infile datalines dlm="09"x;
input Subj c ef ea b;
Set=1;
datalines;
*/insert data here;
;
run;
Data DesignM;
Infile datalines dlm="09"x;
input ef ea b;
datalines;
0 0 1
0 1 0
1 0 0
;
run;
*/tried this and it didn't run;
proc bchoice data=ChoiceBTM outpost=bsamp nmc=10000 thin=2 seed=124;
class ef(ref='0') ea(ref='0') b(ref='0') Subj;
model c = ef ea b / choiceset=(Subj);
preddist covariates=DesignM nalter=3 outpred=Predout;
run; Here is the log. I get a blank results page. And as @Quentin pointed out, I need to fix something but that is the underlying question - how do I fix this? 1 OPTIONS NONOTES NOSTIMER NOSOURCE NOSYNTAXCHECK;
68
69 Data DesignM;
70 Infile datalines dlm="09"x;
71 input ef ea b;
72 datalines;
NOTE: Invalid data for ef in line 73 1-80.
NOTE: Invalid data for ea in line 74 1-80.
NOTE: Invalid data for b in line 75 1-80.
RULE: ----+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9----+----0
75 1 0 0
NOTE: Invalid data errors for file CARDS occurred outside the printed range.
NOTE: Increase available buffer lines with the INFILE n= option.
ef=. ea=. b=. _ERROR_=1 _N_=1
NOTE: SAS went to a new line when INPUT statement reached past the end of a line.
NOTE: The data set WORK.DESIGNM has 1 observations and 3 variables.
NOTE: DATA statement used (Total process time):
real time 0.00 seconds
user cpu time 0.01 seconds
system cpu time 0.00 seconds
memory 668.71k
OS Memory 24228.00k
Timestamp 10/28/2022 02:40:07 PM
Step Count 30 Switch Count 2
Page Faults 0
Page Reclaims 144
Page Swaps 0
Voluntary Context Switches 9
Involuntary Context Switches 0
Block Input Operations 0
Block Output Operations 264
76 ;
77 run;
78
79 */tried this and it didn't run;
NOTE: PROCEDURE BCHOICE used (Total process time):
real time 0.00 seconds
user cpu time 0.00 seconds
system cpu time 0.00 seconds
memory 403.65k
OS Memory 24484.00k
Timestamp 10/28/2022 02:40:07 PM
Step Count 31 Switch Count 2
Page Faults 0
Page Reclaims 249
Page Swaps 0
Voluntary Context Switches 10
Involuntary Context Switches 0
Block Input Operations 0
Block Output Operations 160
NOTE: The SAS System stopped processing this step because of errors.
WARNING: The data set WORK.BSAMP may be incomplete. When this step was stopped there were 0 observations and 0 variables.
80 proc bchoice data=ChoiceBTM outpost=bsamp nmc=10000 thin=2 seed=124;
81 cla
___
180
ERROR 180-322: Statement is not valid or it is used out of proper order.
82 ss ef(ref='0') ea(ref='0') b(ref='0') Subj;
83 model c = ef ea b / choiceset=(Subj);
84 preddist covariates=DesignM nalter=3 outpred=Predout;
85 run;
86 quit;
87
88 OPTIONS NONOTES NOSTIMER NOSOURCE NOSYNTAXCHECK;
98
... View more