Creating a Cartesian Product in SAS

Posted by bkloss | SAS | Friday 13 February 2009 6:49 am

Here’s the first of several question/answer posts.

Feel free to write me with your SAS question and I’ll provide the answer in a post.

Question

Suppose I have two SAS datasets, set A contains 5 variables having 3000 unique records and set B contains just 1 variable having 500 unique records (just a bunch of ID numbers). Suppose I would like to create a new dataset where each of the records from set A would be duplicated so that the first record would be repeated 500 times where each of those would be paired with a unique ID from set B. The goal is to have the new dataset with 6 variables (the five from A and the one from B) containing a total of 1,500,000 records produced in this way.

Any help or suggestions you can provide is greatly appreciated.

(more…)

SAS Resume Tools

Posted by bkloss | Data Visualisation,SAS | Wednesday 4 February 2009 10:00 pm

Although you may consider yourself an Analyst, during your job search you need to think like a salesman . Every interaction with a prospective employer is a golden opportunity to sell yourself. Submitting a resume is equivalent to cold calling a client so stick your foot in the door by connecting quickly with the hiring manager. At a glance, this person needs to see what they’re looking for or else your resume will hit the bottom of the pile, or worse, the paper shredder.

The simple tools provided below turn any SAS Job resume into a targeted sales weapon. The first visualization displays the words that occur most commonly among 450 SAS job postings from SASJobs.BlogSpot.com and SASJobs.com . Make sure you address each of these terms appropriately in your resume and personal statement. The bigger the word, the more commonly it was used- act accordingly. If you want to drill down even further, click on the layout drop down to increase the maximum number of terms shown.

These Visualizations work best in Fire Fox    ————-      Make sure to have Java enabled

(more…)

Sorting Data in SAS with Proc Sort

Posted by bkloss | SAS | Sunday 18 January 2009 7:54 pm

The SAS Sort Procedure

Sorting data in SAS is an everyday task accomplished for a variety of reasons.

    1. Certain types of reports require that data be presorted to present results accurately.
    2. Programs that include a where statement can execute more quickly on a sorted data set.
    3. Unlike SQL, SAS requires data sets to be sorted by a common variable before a join operation can occur.

      These examples are just a few situations where a presorted data set is necessary or essential.  Luckily, PROC SORT is a relatively simple procedure.  The Basic Syntax is below:

      Proc Sort data =<data set>;

      By <variable-1 … variable-n>;

      Run ;

      (more…)

      Base SAS Certification after two months?

      Posted by bkloss | SAS | Friday 5 September 2008 5:04 am

      Yes, it can be done.

      I passed the Base SAS Certification after only 2 months working with the tool.

      That being said, I truly crammed my bum off to make the grade.

      I can’t blame SAS for creating a tough exam because the benefits of certification are clear.  This is what SAS has to say about obtaining certification…

      (more…)