# Logistic Regression Models: Reversed odds ratios in SAS Proc Logistic–Use ‘Descending’

by

If you’ve ever been puzzled by odds ratios in a logistic regression that seem backward, stop banging your head on the desk.

Odds are (pun intended) you ran your analysis in SAS Proc Logistic.

Proc logistic has a strange (I couldn’t say odd again) little default.  If your dependent variable Y is coded 0 and 1, SAS will model the probability of Y=0.  Most of us are trying to model the probability that Y=1.  So, yes, your results ARE backward, but only because SAS is testing a hypothesis opposite yours.

Luckily, SAS made the solution easy.  Simply add the ‘Descending’ option right in the proc logisitic command line.  For example:

PROC LOGISTIC DESCENDING;
MODEL Y = X1 X2;
RUN;

All of your parameter estimates (B) will reverse signs, although p-values will not be affected.

[Logistic_Regression_Workshop]

### Related Posts Jim Hess
{"ft_lang_label":"__label__en","ft_lang_prob":0.88561875,"math_prob":0.71934813,"size":918,"snap":"2020-24-2020-29","text_gpt3_token_len":219,"char_repetition_ratio":0.09190372,"word_repetition_ratio":0.0,"special_character_ratio":0.23093683,"punctuation_ratio":0.113513514,"nsfw_num_words":0,"has_unicode_error":false,"math_prob_llama3":0.980152,"pos_list":[0,1,2],"im_url_duplicate_count":[null,null,null],"WARC_HEADER":"{\"WARC-Type\":\"response\",\"WARC-Date\":\"2020-05-24T22:26:25Z\",\"WARC-Record-ID\":\"<urn:uuid:c31112d5-dcb1-4a13-bec7-2c74dd6ec16e>\",\"Content-Length\":\"47947\",\"Content-Type\":\"application/http; msgtype=response\",\"WARC-Warcinfo-ID\":\"<urn:uuid:681dad76-4942-413c-a039-369dc4aff0e5>\",\"WARC-Concurrent-To\":\"<urn:uuid:ffde40ac-f33c-4159-8f40-a7592a920907>\",\"WARC-IP-Address\":\"69.163.170.205\",\"WARC-Target-URI\":\"https://www.theanalysisfactor.com/logistic-regression-models-reversed-odds-ratios-in-sas-proc-logistic-use-descending/\",\"WARC-Payload-Digest\":\"sha1:ROB7D6NUGNDPH5PB7GAWZYFUYRZ4GICE\",\"WARC-Block-Digest\":\"sha1:KO4IFTXRUGWY7RGYI7RQPO77M7ZD6662\",\"WARC-Identified-Payload-Type\":\"application/xhtml+xml\",\"warc_filename\":\"/cc_download/warc_2020/CC-MAIN-2020-24/CC-MAIN-2020-24_segments_1590347385193.5_warc_CC-MAIN-20200524210325-20200525000325-00421.warc.gz\"}"}