Hi SAS Forum,
I cannot read the date of this small dataset using ddmmyy10. informat. And then I also cannot display with the same date format?
This error messege pops up.
NOTE: Invalid data for date in line 20 1-9.
RULE: ----+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9----+----0
20 3/31/2012 1 2 3
date=. a=1 b=2 c=3 _ERROR_=1 _N_=1
NOTE: Invalid data for date in line 21 1-9.
21 4/30/2012 4 5 6
date=. a=4 b=5 c=6 _ERROR_=1 _N_=2
NOTE: Invalid data for date in line 22 1-9.
/*
data have;
informat date DDMMYY10.;
format date DDMMYY10.;
input date a b c;
cards;
3/31/2012 1 2 3
4/30/2012 4 5 6
5/31/2012 7 8 9
6/30/2012 3 2 1
7/31/2012 6 5 3
8/31/2012 5 8 9
9/30/2012 6 5 8
10/31/2012 3 6 5
11/30/2012 5 6 4
12/31/2012 6 5 8
1/31/2013 2 5 6
2/28/2013 3 5 1
3/31/2013 2 5 4
4/30/2013 3 6 5
5/31/2013 2 5 4
6/30/2013 3 6 5
;
run;
*/
Could anyone help me.
Thanks
Mirisage
That's because your data format is MMDDYY10.
PG
Don't miss out on SAS Innovate - Register now for the FREE Livestream!
Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.
Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.
Find more tutorials on the SAS Users YouTube channel.