Importing time series from a table
Posted: Fri Nov 11, 2016 3:41 am
I sometime have the following problem: I have a quarterly time series published as a table, as in this Excel file, range O8::S26
http://www.turkstat.gov.tr/PreIstatisti ... ab_id=2272
namely
Q1 Q2 Q3 Q4
Year1 v v v v
Year2 v v v v
etc
where "v" stands for the numeric values of my quarterly time series X
I used to read these tables using the READ command in a loop, but I recently learned that the READ command is now deprecated.
I can read the table using a laborious loop, as in
But I am wondering if there is a simpler solution...
Thank you for your support
http://www.turkstat.gov.tr/PreIstatisti ... ab_id=2272
namely
Q1 Q2 Q3 Q4
Year1 v v v v
Year2 v v v v
etc
where "v" stands for the numeric values of my quarterly time series X
I used to read these tables using the READ command in a loop, but I recently learned that the READ command is now deprecated.
I can read the table using a laborious loop, as in
Code: Select all
' Reads the four columns as annual series, named Series01 to Series04
copy(c=r) annual\series* quarterly\
pageselect quarterly
series gdp
for !year=1998 to 2016
for !q = 1 to 4
smpl {!year}Q{!q} {!year}Q{!q}
gdp = series0{!q}
next
next
smpl @all
Thank you for your support