Greetings to all,
Being a very inexperienced Gretl user, I ran into an issue which must have a simple
solution, however I could find it nowhere.
My question is the following :
In a time series which comprises daily entries over 10 years, how may I select a certain
period of each year, i.e. only March-April for instance ?
Up to now I have had to resort to a most inefficient solution, although it seems to work,
whereby a given variable time (containing only the dates of the entries under a format
20040101, which Gretl doesn't recognise as a date) was used to open a new variable
month=int((time-10000*int(time/10000))/100)
This works, in that I now have a variable returning the number of each month. I then
proceeded to restrict based on the criterion month >= 2 && month <= 4
However the result of this is that I have a series which is not chronological any more. If
I convert it back to a time series, it logically gives me a roughly two-year-long period
with daily entries. Which means I should proceed to isolate the trimester of each year
manually. This is very inefficient and time-consuming.
As this is surely not an over-the-top functionality, I assume there must be a simpler and
more efficient way of selecting a given period within each year, repetitively over several
years. Can someone kindly help me out ?
Hoping my explanations were clear, and thanking all in advance,
Best,
Marc O'Callaghan