On Feb 7, 2013, at 10:58 AM, Aminreza Aamini wrote: > Hi, > I am comparing SAS commands with R. > consider i want to assess the effect of one exposure(like CAT where 1 > equals high and 0 equals low) and one cofounding variable (like > cholesterol leve,CHL) on a diseasee variable (like CHD). > In SAS to get a numerical value for the odds ratio, consider, for > example, the specific values CHL equal to 220 and HPT equal to 1 when > the model contains interaction terms like (CC=CAT*CHL) the command > is: > > PROC GENMOD data=l2 DESCENDING; > MODEL CHD=CAT CHL CC/LINK=LOGIT DIST=BINOMIAL; > ESTIMATE CAT 1 CC 200 /EXP; > RUN; > > I just want to find such a command in R. Its not a homework.
But it _is_ asking an extremely question that would be more rapidly answered by simply typing "how to do logistic regression in R" in a search engine. (I know this because I just tried it.) Such questions are explicitly deprecated in the Posting Guide. You should also do further self-study by reading the Posting Guide, working through the "Introduction to R", and learning to use the help() system. -- David. > > Amin > > > On Wed, Feb 6, 2013 at 9:46 PM, Bert Gunter <gunter.ber...@gene.com> wrote: > >> 1. Please do not double post. >> >> 2. This is a statistics, not an R question. Post on a statistics list, >> like stats.stackexchange.com instead. >> >> 3. Is this a homework question? -- we don't do homework here. >> >> -- Bert >> >> On Wed, Feb 6, 2013 at 8:59 AM, Aminreza Aamini <amin.r....@gmail.com> >> wrote: >>> Dear all, >>> >>> How can i obtain odds ratio in logistic regression when the model >>> contains interaction terms in R? >>> how can i obtain OR for a special case? >>> Thanks in advance for any help. >>> Amin >>> >>> ______________________________________________ >>> R-help@r-project.org mailing list >>> https://stat.ethz.ch/mailman/listinfo/r-help >>> PLEASE do read the posting guide >> http://www.R-project.org/posting-guide.html >>> and provide commented, minimal, self-contained, reproducible code. >> >> >> >> -- >> >> Bert Gunter >> Genentech Nonclinical Biostatistics >> >> Internal Contact Info: >> Phone: 467-7374 >> Website: >> >> http://pharmadevelopment.roche.com/index/pdb/pdb-functional-groups/pdb-biostatistics/pdb-ncb-home.htm >> > > [[alternative HTML version deleted]] > > ______________________________________________ > R-help@r-project.org mailing list > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide http://www.R-project.org/posting-guide.html > and provide commented, minimal, self-contained, reproducible code. David Winsemius Alameda, CA, USA ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.