Category: SAS

SAS v R: Getting help

I introduced this series the other day. Next up in the list is “getting help”. In both SAS and R, there are many sources of help. SAS has one that the usual R package does not have – technical support – although if you read the …

How to transpose data

“http://www.mitbbs.com/article_t/Statistics/31224273.html”Derive new var in data step –> reshape data in proc transpose –> use proc sql to generate reportdata one;input good P1 P2 P3 P4 P5 P6 P7 P8 P9 P10;if sum(of good-P10)=11 then yes=1;else yes=0…

Improve the Boost macro from Prof. Rayens, W and Dr. Johnson, K

In Chapter 2 of the book “Pharmaceutical Statistics Using SAS: A Practical Guide” (SAS Press), Prof. Rayens, W and Dr. Johnson K. presented their SAS implementation of boost algorithms, including AdaBoost, RealBoost, GentleBoost and LogitBoost. The o…

SAS v. R: Ease of learning

Two days ago, I wrote an introduction to this series. Today, I will discuss ease of learning. Unlike the earlier post (and, I hope, most of the ones to come) this one is inherently subjective. “Ease of learning” is not the same for everyone…

SAS vs. R: Introduction and request

Lately, across the statistical blogosphere, the repeating discussion of R vs. SAS has started up again. In this series of posts, I’ll offer my opinions of the programs, and supply some information. In this post, I introduce the series and say a l…

CALL EXECUTE: Easy way to print or sort multiple files.

When printing multiple files, or sorting multiple datasets, the traditional method is to write multiple steps as below.

Proc print data=libref.ae; var _all_; run;

Proc print data=libref.conmed; var _all_; run;

Proc print data=libref.demog; var _…

Use SAS to write the cover letter for job application

We can use data _null_ to write a customized cover letter in job application.options nodate nocenter nonumber LEFTMARGIN=1in RIGHTMARGIN=1in TOPMARGIN=1in BOTTOMMARGIN=1in; ;title;footnote;%let N1=Chen Junfang;data company;input person $20. /ti…

PROC LOGISTIC: Complete and quasi-complete separation

Description of separation in PROC LOGISTIC If you picture the data as a 2 x 2 crosstab, then quasi-complete separation occurs when one of the cells is 0. Complete separation occurs when one cell in each row and column is 0. An example of quasi-complete…