Panel structure daily data
Posted: Tue Jul 10, 2018 8:49 am
Hello everybody,
hope someone can help me out. For a variety of reasons, my data is structured the following way. Each row resembles a firm and each column resembles a point in time. That basically means that each series object contains the data of one variable of all firms for one point in time. Each series object is named after the variable and point in time (for example: size_1990M6).
As we are normally using monthly data, we can easily use for loops (for example: for !year = 1990 to 2000 / for !month = 1 to 12) to analyze the data.
However for our new research project we only have daily data. The problem with daily data is that each year has a different amount of days, which makes it impossible to use the for loops like we did so far.
My question is whether or not there is a command which tells the for loop which series object contains the data of the last day of a month.
Second question: is there a command or expression which tells the for loop if a series object still belongs to a certain month.
Thank you in advance!
hope someone can help me out. For a variety of reasons, my data is structured the following way. Each row resembles a firm and each column resembles a point in time. That basically means that each series object contains the data of one variable of all firms for one point in time. Each series object is named after the variable and point in time (for example: size_1990M6).
As we are normally using monthly data, we can easily use for loops (for example: for !year = 1990 to 2000 / for !month = 1 to 12) to analyze the data.
However for our new research project we only have daily data. The problem with daily data is that each year has a different amount of days, which makes it impossible to use the for loops like we did so far.
My question is whether or not there is a command which tells the for loop which series object contains the data of the last day of a month.
Second question: is there a command or expression which tells the for loop if a series object still belongs to a certain month.
Thank you in advance!