73 data testout;
74 set grocery_coupons(keep= couponexpiry);
75 today=today();
76 format today date9.;
77 format coupon_issuance_date date9.;
78 mon_diff_coupexp=intck('month',couponexpiry,today);
79 week_diff_coupexp=intck('week',couponexpiry,today);
80 day_diff_coupexp=intck('day',couponexpiry,today);
81
82 /*from 31-Mar-14*/
83 Day='31-Mar-14'd;
84 mon_diff_coupexp1=intck('month',couponexpiry,day);
85 week_diff_coupexp1=intck('week',couponexpiry,day);
86 day_diff_coupexp1=intck('day',couponexpiry,day);
87
88 /*question2*/
89 coupon_issuance_date=intnx('month',couponexpiry,3);
90 /*question3 -30-sep-14*/
91 day2='30-sep-14'd;
92 day_diff_coupexp2=datdif(day2,couponexpiry,'30/act');
93 run;
NOTE: Invalid argument to function DATDIF(19996,19774,'30/act') at line 92 column 19.
couponexpiry=20FEB2014 today=20FEB2019 coupon_issuance_date=01MAY2014 mon_diff_coupexp=60 week_diff_coupexp=261
day_diff_coupexp=1826 Day=19813 mon_diff_coupexp1=1 week_diff_coupexp1=6 day_diff_coupexp1=39 day2=19996 day_diff_coupexp2=.
_ERROR_=1 _N_=1
NOTE: Invalid argument to function DATDIF(19996,19775,'30/act') at line 92 column 19.
couponexpiry=21FEB2014 today=20FEB2019 coupon_issuance_date=01MAY2014 mon_diff_coupexp=60 week_diff_coupexp=261
day_diff_coupexp=1825 Day=19813 mon_diff_coupexp1=1 week_diff_coupexp1=6 day_diff_coupexp1=38 day2=19996 day_diff_coupexp2=.
_ERROR_=1 _N_=2
NOTE: Invalid argument to function DATDIF(19996,19776,'30/act') at line 92 column 19.
couponexpiry=22FEB2014 today=20FEB2019 coupon_issuance_date=01MAY2014 mon_diff_coupexp=60 week_diff_coupexp=261
day_diff_coupexp=1824 Day=19813 mon_diff_coupexp1=1 week_diff_coupexp1=6 day_diff_coupexp1=37 day2=19996 day_diff_coupexp2=.
_ERROR_=1 _N_=3
NOTE: Invalid argument to function DATDIF(19996,19777,'30/act') at line 92 column 19.
couponexpiry=23FEB2014 today=20FEB2019 coupon_issuance_date=01MAY2014 mon_diff_coupexp=60 week_diff_coupexp=260
day_diff_coupexp=1823 Day=19813 mon_diff_coupexp1=1 week_diff_coupexp1=5 day_diff_coupexp1=36 day2=19996 day_diff_coupexp2=.
_ERROR_=1 _N_=4
NOTE: Invalid argument to function DATDIF(19996,19778,'30/act') at line 92 column 19.
couponexpiry=24FEB2014 today=20FEB2019 coupon_issuance_date=01MAY2014 mon_diff_coupexp=60 week_diff_coupexp=260
day_diff_coupexp=1822 Day=19813 mon_diff_coupexp1=1 week_diff_coupexp1=5 day_diff_coupexp1=35 day2=19996 day_diff_coupexp2=.
_ERROR_=1 _N_=5
NOTE: Invalid argument to function DATDIF(19996,19779,'30/act') at line 92 column 19.
couponexpiry=25FEB2014 today=20FEB2019 coupon_issuance_date=01MAY2014 mon_diff_coupexp=60 week_diff_coupexp=260
day_diff_coupexp=1821 Day=19813 mon_diff_coupexp1=1 week_diff_coupexp1=5 day_diff_coupexp1=34 day2=19996 day_diff_coupexp2=.
_ERROR_=1 _N_=6
NOTE: Invalid argument to function DATDIF(19996,19780,'30/act') at line 92 column 19.
couponexpiry=26FEB2014 today=20FEB2019 coupon_issuance_date=01MAY2014 mon_diff_coupexp=60 week_diff_coupexp=260
day_diff_coupexp=1820 Day=19813 mon_diff_coupexp1=1 week_diff_coupexp1=5 day_diff_coupexp1=33 day2=19996 day_diff_coupexp2=.
_ERROR_=1 _N_=7
NOTE: Invalid argument to function DATDIF(19996,19781,'30/act') at line 92 column 19.
couponexpiry=27FEB2014 today=20FEB2019 coupon_issuance_date=01MAY2014 mon_diff_coupexp=60 week_diff_coupexp=260
day_diff_coupexp=1819 Day=19813 mon_diff_coupexp1=1 week_diff_coupexp1=5 day_diff_coupexp1=32 day2=19996 day_diff_coupexp2=.
_ERROR_=1 _N_=8
NOTE: Invalid argument to function DATDIF(19996,19782,'30/act') at line 92 column 19.
couponexpiry=28FEB2014 today=20FEB2019 coupon_issuance_date=01MAY2014 mon_diff_coupexp=60 week_diff_coupexp=260
day_diff_coupexp=1818 Day=19813 mon_diff_coupexp1=1 week_diff_coupexp1=5 day_diff_coupexp1=31 day2=19996 day_diff_coupexp2=.
_ERROR_=1 _N_=9
NOTE: Invalid argument to function DATDIF(19996,19782,'30/act') at line 92 column 19.
couponexpiry=28FEB2014 today=20FEB2019 coupon_issuance_date=01MAY2014 mon_diff_coupexp=60 week_diff_coupexp=260
day_diff_coupexp=1818 Day=19813 mon_diff_coupexp1=1 week_diff_coupexp1=5 day_diff_coupexp1=31 day2=19996 day_diff_coupexp2=.
_ERROR_=1 _N_=10
NOTE: Invalid argument to function DATDIF(19996,19783,'30/act') at line 92 column 19.
couponexpiry=01MAR2014 today=20FEB2019 coupon_issuance_date=01JUN2014 mon_diff_coupexp=59 week_diff_coupexp=260
day_diff_coupexp=1817 Day=19813 mon_diff_coupexp1=0 week_diff_coupexp1=5 day_diff_coupexp1=30 day2=19996 day_diff_coupexp2=.
_ERROR_=1 _N_=11
NOTE: Invalid argument to function DATDIF(19996,19784,'30/act') at line 92 column 19.
couponexpiry=02MAR2014 today=20FEB2019 coupon_issuance_date=01JUN2014 mon_diff_coupexp=59 week_diff_coupexp=259
day_diff_coupexp=1816 Day=19813 mon_diff_coupexp1=0 week_diff_coupexp1=4 day_diff_coupexp1=29 day2=19996 day_diff_coupexp2=.
_ERROR_=1 _N_=12
NOTE: Invalid argument to function DATDIF(19996,19785,'30/act') at line 92 column 19.
couponexpiry=03MAR2014 today=20FEB2019 coupon_issuance_date=01JUN2014 mon_diff_coupexp=59 week_diff_coupexp=259
day_diff_coupexp=1815 Day=19813 mon_diff_coupexp1=0 week_diff_coupexp1=4 day_diff_coupexp1=28 day2=19996 day_diff_coupexp2=.
_ERROR_=1 _N_=13
NOTE: Invalid argument to function DATDIF(19996,19786,'30/act') at line 92 column 19.
couponexpiry=04MAR2014 today=20FEB2019 coupon_issuance_date=01JUN2014 mon_diff_coupexp=59 week_diff_coupexp=259
day_diff_coupexp=1814 Day=19813 mon_diff_coupexp1=0 week_diff_coupexp1=4 day_diff_coupexp1=27 day2=19996 day_diff_coupexp2=.
_ERROR_=1 _N_=14
NOTE: Invalid argument to function DATDIF(19996,19787,'30/act') at line 92 column 19.
couponexpiry=05MAR2014 today=20FEB2019 coupon_issuance_date=01JUN2014 mon_diff_coupexp=59 week_diff_coupexp=259
day_diff_coupexp=1813 Day=19813 mon_diff_coupexp1=0 week_diff_coupexp1=4 day_diff_coupexp1=26 day2=19996 day_diff_coupexp2=.
_ERROR_=1 _N_=15
NOTE: Invalid argument to function DATDIF(19996,19774,'30/act') at line 92 column 19.
couponexpiry=20FEB2014 today=20FEB2019 coupon_issuance_date=01MAY2014 mon_diff_coupexp=60 week_diff_coupexp=261
day_diff_coupexp=1826 Day=19813 mon_diff_coupexp1=1 week_diff_coupexp1=6 day_diff_coupexp1=39 day2=19996 day_diff_coupexp2=.
_ERROR_=1 _N_=16
NOTE: Invalid argument to function DATDIF(19996,19776,'30/act') at line 92 column 19.
couponexpiry=22FEB2014 today=20FEB2019 coupon_issuance_date=01MAY2014 mon_diff_coupexp=60 week_diff_coupexp=261
day_diff_coupexp=1824 Day=19813 mon_diff_coupexp1=1 week_diff_coupexp1=6 day_diff_coupexp1=37 day2=19996 day_diff_coupexp2=.
_ERROR_=1 _N_=17
NOTE: Invalid argument to function DATDIF(19996,19777,'30/act') at line 92 column 19.
couponexpiry=23FEB2014 today=20FEB2019 coupon_issuance_date=01MAY2014 mon_diff_coupexp=60 week_diff_coupexp=260
day_diff_coupexp=1823 Day=19813 mon_diff_coupexp1=1 week_diff_coupexp1=5 day_diff_coupexp1=36 day2=19996 day_diff_coupexp2=.
_ERROR_=1 _N_=18
NOTE: Invalid argument to function DATDIF(19996,19778,'30/act') at line 92 column 19.
couponexpiry=24FEB2014 today=20FEB2019 coupon_issuance_date=01MAY2014 mon_diff_coupexp=60 week_diff_coupexp=260
day_diff_coupexp=1822 Day=19813 mon_diff_coupexp1=1 week_diff_coupexp1=5 day_diff_coupexp1=35 day2=19996 day_diff_coupexp2=.
_ERROR_=1 _N_=19
NOTE: Invalid argument to function DATDIF(19996,19779,'30/act') at line 92 column 19.
WARNING: Limit set by ERRORS= option reached. Further errors of this type will not be printed.
couponexpiry=25FEB2014 today=20FEB2019 coupon_issuance_date=01MAY2014 mon_diff_coupexp=60 week_diff_coupexp=260
day_diff_coupexp=1821 Day=19813 mon_diff_coupexp1=1 week_diff_coupexp1=5 day_diff_coupexp1=34 day2=19996 day_diff_coupexp2=.
_ERROR_=1 _N_=20
NOTE: Missing values were generated as a result of performing an operation on missing values.
Each place is given by: (Number of times) at (Line):(Column).
276 at 78:18 276 at 79:19 276 at 80:18 276 at 84:19 276 at 85:20 276 at 86:19 276 at 89:22
NOTE: Mathematical operations could not be performed at the following places. The results of the operations have been set to
missing values.
Each place is given by: (Number of times) at (Line):(Column).
1680 at 92:19
NOTE: There were 1680 observations read from the data set WORK.GROCERY_COUPONS.
NOTE: The data set WORK.TESTOUT has 1680 observations and 12 variables.
NOTE: DATA statement used (Total process time):
real time 0.36 seconds
cpu time 0.37 second