Statalist The Stata Listserver

[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: logical operator for date in variable name

From   Caleb Southworth <[email protected]>
To   [email protected]
Subject   st: logical operator for date in variable name
Date   Fri, 15 Sep 2006 19:17:58 -0700 (PDT)

I would like to have a list of stubs to automate reshaping some data. I
plan to -reshape long subname, i(federation) j(year)-

All the variable names have years on the end, for example

. ds
federation w_1902 w_union~1908 b_b_1914 w_1921 gal_1929 ts_1950
w_1880 foner_1902 ts_1908 b_union~1914 w_union~1921 w_1930 ts_1951 w_1881
foner_u~1902 b_st_1908 w_1915 ts_1921 w_union~1930 ts_1952 w_1882

Is there a way to get a set or subset of stubs such as w_ w_union~ gal_ ,
etc. without typing this list explicitly?
*   For searches and help try:

© Copyright 1996–2024 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index