TSINFO Procedure

Example 28.2 Examining Multiple BY Groups

This example illustrates how a time ID variable can be examined independently over each BY group and summarized over all observations in the data table that is specified in the DATA= option.

The following DATA step creates the BY-group variable, class, and loads the Air data set onto the CAS server:

data mylib.air(replace=yes);
   set sashelp.air;
   do class=1 to 10;
     output;
   end;
run;

The following TSINFO procedure statements generate data tables that summarize data that have 10 BY groups:

proc tsinfo data=mylib.air outintervaldetails=mylib.interval2 nthreads=2;
  id date align=B;
  by class;
run;

The summarized information shows that BY groups 1 to 10 in the mylib.interval2 data table contain the interval fit information of the time ID values and shows the number of counts, alignment, and seasonality for each by group. All BY groups conform exactly to the MONTH interval. The information can be useful in diagnosing time series that contain many time intervals.

Last updated: July 09, 2026