LISTSERV at the University of Georgia
Menubar Imagemap
Home Browse Manage Request Manuals Register
Previous messageNext messagePrevious in topicNext in topicPrevious by same authorNext by same authorPrevious page (November 2007, week 2)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Wed, 14 Nov 2007 14:57:27 -0600
Reply-To:     William Elliott <elliott.willie@SBCGLOBAL.NET>
Sender:       "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:         William Elliott <elliott.willie@SBCGLOBAL.NET>
Subject:      Adjusting dollar amounts for inflation
Content-Type: text/plain; charset="us-ascii"

Hello, I am trying to convert 1997 dollars to 2002 dollar. Does this code look correct.

/******** ADJUSTING FAMILY INCOME SO THAT IT IS EQUAL TO 2001 DOLLARS ******/

DATA CLEAN_DATA2; SET CLEAN_DATA;

%LET CPI=1.15;

LABEL INC_ADJ97="ADJUSTED INCOME";

INC_ADJ97=&CPI.* FAMINC97;

RUN;

/*PRINTS OUT BOTH THE ADJUSTED FAMILY INCOME FOR 1997 AND THE ACTUAL FAMILY INCOME FOR 1997*/

PROC PRINT NOOBS;

VAR INC_ADJ97 FAMINC97;

TITLE "INCOME AJUSTED FOR INFLACTION WITH CPI = &CPI.";

RUN;

/** CREATES AN AVERAGE FOR THE TWO YEARS USING ADJUSTED FAMILY INCOME***/

DATA CLEAN_DATA3; SET CLEAN_DATA2;

LABEL AVG_FAMINC="AVERAGE FAMILY INCOME FOR 1997 AND 2001";

AVG_FAMINC=(INC_ADJ97+FAMINC01)/2;

RUN;

/*PRINTS OUT BOTH THE AVERAGE FAMILY INCOME AND THE FAMILY INCOME FOR 2001*/

PROC PRINT NOOBS;

VAR AVG_FAMINC FAMINC01;

RUN;


Back to: Top of message | Previous page | Main SAS-L page