Hi all,
One more question... I have a time field that I want to increment to the next 15 minute interval. So if the first obs is 00:36 I want 00:45, if 1:12 I want 1:15 etc. Here's what I have so far, but it advances to the next hour, not 1/4 hour...
Min_Start = intnx('dthour',StartTime,.25, 'e');
format Min_Start HHMM.;
I think, based on your description, you want the Start of the next 15 minute interval.
Reviewing the SAS LANGUAGE documentation, have a look at INTNX and the DTMINUTEnn function.
Suggested browser search argument: intnx function 15 minute interval site:sas.com
Scott Barry
SBBWorks, Inc.
You could use proc format:
1 - 14 = 15
16 - 29 = 30 etc.
I think, based on your description, you want the Start of the next 15 minute interval.
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 how use the CAT functions in SAS to join values from multiple variables into a single value.
Find more tutorials on the SAS Users YouTube channel.