For an assignment I am comparing means of willingness to pay (WTP) with willingness to pay repeat (WTP_R) under various conditions. I need to know if the mean of WTP_R is higher or lower for the following conditions:
willingness_to_Pay_Repeat - willingness_to_Pay if focus==0 & certainty==0
willingness_to_Pay_Repeat - willingness_to_Pay if focus==1 & certainty==0
willingness_to_Pay_Repeat - willingness_to_Pay if focus==2 & certainty==0
willingness_to_Pay_Repeat - willingness_to_Pay if focus==0 & certainty==1
willingness_to_Pay_Repeat - willingness_to_Pay if focus==1 & certainty==1
willingness_to_Pay_Repeat - willingness_to_Pay if focus==2 & certainty==1
It is a within-sample design since the subjects had first provided his WTP, and if he chose yes I want to repeat, he provided his WTP_R
Now I am not sure which test I can use for this, when trying a t-test, it gives me an error. ?
Code:
ttest willingness_to_Pay_Repeat if focus==0 & certainty==0, by(willingness_to_Pay)
Can I just use normal regression analyses eg:
Code:
regress willingness_to_Pay_Repeat willingness_to_Pay if focus==0 & certainty==0
Thanks,
Daniël
0 Response to Comparing two groups with if statements
Post a Comment