Object Reference : Object View and Procedure Reference : Group
  
 
insertobs
Shift the observations of the series in the group up or downwards, inserting blank observations.
Syntax
group_name.insertobs(startpoint, col_range) n
Where startpoint specifies the first or last observation from which the observations are shifted. For dated workfiles, startpoint should be entered as a date. For panels and non-dated workfiles startpoint should be an observation number.
The col_range option is used to describe the columns to be shifted in the group. It may take one of the following forms:
 
@all
Apply to all series in the group.
col
Column number or letter (e.g., “2”, “B”). Apply to the series corresponding to the column.
first_col[:]last_col
Colon delimited range of columns (from low to high, e.g., “3:5”). Apply to all series corresponding to the column range.
first_series[:]last_series
Colon delimited range of columns (from low to high, e.g., “series01:series05”) specified by the series names. Apply to all series corresponding to the column range.
n specifies the number of observations shifted.
Examples
g.insertobs(1952q2, 1) 2
Inserts 2 new observations beginning at observation 1952 quarter 2 into the first series in the group. The previous value associated with 1952Q2 for that series will now correspond to 1952Q4.
g.insertobs(10, gdp) -5
Inserts 5 new observations to the series GDP ending at observation number 10.
g.insertobs(1990m2, @all) 8
Inserts 8 new observations beginning at February 1990 for all series in the group.