BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
Reader587
Calcite | Level 5

How do I change Beta=0 to Beta=2 for proc reg?

1 ACCEPTED SOLUTION

Accepted Solutions
5 REPLIES 5
PaigeMiller
Diamond | Level 26
Please explain further. Provide more detail. Provide example data.
--
Paige Miller
Reader587
Calcite | Level 5
data plastic2;
input hardness minutes;
cards;
199.0 16.0
205.0 16.0
196.0 16.0
200.0 16.0
218.0 24.0
220.0 24.0
215.0 24.0
223.0 24.0
237.0 32.0
234.0 32.0
235.0 32.0
230.0 32.0
250.0 40.0
248.0 40.0
253.0 40.0
246.0 40.0
;run;
proc reg;
model hardness=minutes/clb alpha=.01;run;
I am trying to change the test from Ho:B1=0 vs Ha:B1^=0 to Ho:B1=2 vs. Ha:B1^=2
PaigeMiller
Diamond | Level 26

Use the TEST statement in PROC REG. Examples: https://documentation.sas.com/doc/en/pgmmvacdc/9.4/statug/statug_reg_syntax20.htm

--
Paige Miller
Reader587
Calcite | Level 5
What if I want to do a one-sided t-test for regression?
PaigeMiller
Diamond | Level 26

The PROC REG output contains two-sided tests. If you were to do a two-sided test at the alpha=0.05 level, then 0.025 chance of a type I error is in the upper tail and 0.025 chance of a type I error is in the lower tail. 

 

You want a one-sided test with alpha=0.05 in one tail and alpha=0 in the other tail. So, if the pvalue from SAS is <0.10, your one-sided test is statistically significant at the alpha=0.05 level, because 0.05 chance of type I error in one tail, and 0 percent chance of type I error in the other tail.

--
Paige Miller

sas-innovate-2024.png

Available on demand!

Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.

 

Register now!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 5 replies
  • 393 views
  • 1 like
  • 2 in conversation