sasitup.blogspot.com
SAS it up: quartiles (or x-tiles) for the lazy
http://sasitup.blogspot.com/2007/02/quartiles-or-x-tiles-for-lazy.html
Getting down with SAS. Tuesday, February 13, 2007. Quartiles (or x-tiles) for the lazy. Set data.composite;. Proc rank groups=4 out=ranked;. Var srcalc srprot sriron srmagnes srphos srzinc srvitc srvitd packyrs bmi;. Ranks rank srcalc rank srprot rank sriron rank srmagnes rank srphos rank srzinc rank srvitc rank srvitd rank packyrs rank bmi;. Subscribe to: Post Comments (Atom). Direct filename with path to a file. SAS Tips Published Tips. Quartiles (or x-tiles) for the lazy. Make a good looking histogram.
sasitup.blogspot.com
SAS it up: magic code to transform R data with 'NA' for missing to SAS '.'
http://sasitup.blogspot.com/2008/03/magic-code-to-transform-r-data-with-na.html
Getting down with SAS. Monday, March 17, 2008. Magic code to transform R data with 'NA' for missing to SAS '.'. Array inc dlfib- dlcrp;. Subscribe to: Post Comments (Atom). Direct filename with path to a file. SAS Tips Published Tips. Magic code to transform R data with NA for missi.
sasitup.blogspot.com
SAS it up: February 2007
http://sasitup.blogspot.com/2007_02_01_archive.html
Getting down with SAS. Tuesday, February 13, 2007. Quartiles (or x-tiles) for the lazy. Set data.composite;. Proc rank groups=4 out=ranked;. Var srcalc srprot sriron srmagnes srphos srzinc srvitc srvitd packyrs bmi;. Ranks rank srcalc rank srprot rank sriron rank srmagnes rank srphos rank srzinc rank srvitc rank srvitd rank packyrs rank bmi;. Sunday, February 11, 2007. Create a categorical variable in one fell swoop. Categorize a variable with "lazy elegance. If age ne . then agecat= int(iage/5-1);.
sasitup.blogspot.com
SAS it up: June 2007
http://sasitup.blogspot.com/2007_06_01_archive.html
Getting down with SAS. Sunday, June 24, 2007. Use "retain statement" to make a count variable. This code comes from UCLA statistical computing seminar. Link here to code. Proc sort data=kids out=sort kids;. Set sort kids;. Retain sumwt count;. Carry over the value from previous obs to next obs*/. If first.famid then do;. At 1st obs of each family set sumwt and count = 0*/. Sumwt = sumwt wt;. Count = count 1;. Meanwt = sumwt/count;. Proc print data=retain1;. Var famid kidname wt sumwt count meanwt;.
sasitup.blogspot.com
SAS it up: use "retain statement" to make a count variable
http://sasitup.blogspot.com/2007/06/use-retain-statement-to-make-count.html
Getting down with SAS. Sunday, June 24, 2007. Use "retain statement" to make a count variable. This code comes from UCLA statistical computing seminar. Link here to code. Proc sort data=kids out=sort kids;. Set sort kids;. Retain sumwt count;. Carry over the value from previous obs to next obs*/. If first.famid then do;. At 1st obs of each family set sumwt and count = 0*/. Sumwt = sumwt wt;. Count = count 1;. Meanwt = sumwt/count;. Proc print data=retain1;. Var famid kidname wt sumwt count meanwt;.
datasteps.blogspot.com
Data Steps: I Git Busy
http://datasteps.blogspot.com/2012/08/i-git-busy.html
A regularly updated blog about programming with the SAS System. SAS Jobs For SAS Programmers. Wednesday, August 01, 2012. While I was on vacation, I got a friendly email reminding me that my WUSS 2012 paper was due July 30th. Yikes! I had exactly one week to get home and write it. My mother calls it procrastinating. I prefer to think of it as Lazy Loading. So I was a bit busy last week. But I finished it. And I think it's good. At least, I hope it's good. It is an Introduction to Git. Stephen, look forwa...
datasteps.blogspot.com
Data Steps: March 2011
http://datasteps.blogspot.com/2011_03_01_archive.html
A regularly updated blog about programming with the SAS System. SAS Jobs For SAS Programmers. Tuesday, March 29, 2011. Here is something to keep in mind when using the END= option on the set statement: There is no guarantee. You will hit the end of file. Simple example to illustrate:. Do i = 1 to 10;. Data null ;. Set test(where=(i 10) end= eof;. Then put "It set EOF for end of file";. In the SAS documentation this is stated cryptically:. In that case it does set eof to 1 as expected. Try where i. What w...
datasteps.blogspot.com
Data Steps: Rainbow Table Salt
http://datasteps.blogspot.com/2012/06/rainbow-table-salt.html
A regularly updated blog about programming with the SAS System. SAS Jobs For SAS Programmers. Tuesday, June 12, 2012. DISCLAIMER: I am not an expert at cryptology. But I generally understand the industry best practices and have implemented this stuff on several sites. That said, read on at your own risk :). There's been a lot of talk about LinkedIN passwords getting stolen. It's an interesting read and it made me think it would make for a good blog post. Strict password requirements create bad passwords.
datasteps.blogspot.com
Data Steps: November 2011
http://datasteps.blogspot.com/2011_11_01_archive.html
A regularly updated blog about programming with the SAS System. SAS Jobs For SAS Programmers. Wednesday, November 16, 2011. Remove Formatting From Variables. What do you do if you have a SAS data set with formatted variables, but you don't have access to the format? You have to remove the format from the variables if you want to work with the data set. The easiest way to remove formats from variables in a data set is to use proc datasets. Proc datasets library = myLibrary memtype=data;. Links to this post.