drop (dataloop)


Specifies columns to be dropped from the output dataset in a data loop.


drop variable_list


drop age, pay, sex;


Commas are optional in variable_list.

Deletes the specified variables from the output dataset. Any variables referenced must already exist, either as elements of the source data set, or as the result of a previous make, vector, or code statement.

If neither keep() nor drop() is used, the output dataset will contain all variables from the source dataset, as well as any defined variables. The effects of multiple keep and drop statements are cumulative.

See also