Dear Tom,
While Data wizard has a scan function to read the first and last data points, saying 1995:02 and 2017:04, how can do it programmatically using DATA instruction? I do not see the possibility with OPEN DATA and DATA commands.
The idea is that I have 6 excel files which contain data for six stocks. I don't want to set the starting date manually for each dataset, the last date is the same for all countries. Using data wizard RATS sees the different starting dates so that it generates the corresponding codes. Which instruction can read the first date? Or I have to program by reading the text then read the first row to extract the date?
Is there any shortcut?
Kind regards,
Auto read first and last date
Re: Auto read first and last date
If you have usable dates on the file, set a start date for the work space that's the earliest start date of the data sets (or earlier). When you read data, the entries prior to the start will come in as NA.