Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Panel Event Study - Monthly Data

    Dear all,

    I have a thesis with panel data for panel event study. I need a baseline but with monthly data (i.e time 2021m3, 2021m4 etc) and event(2022m2) when I try to generate timetotreat = time - event it goes something wrong with my monthly data. Does anyone knows why?

  • #2
    I doubt very much that anybody can answer your question based on the information you have provided.

    First, and most important, what does "it goes something wrong with my monthly data" mean? There are an enormous number of ways things can go wrong. You need to say what goes wrong. In fact, rather than saying what goes wrong, it is best to show what goes wrong by posting the actual results you get from the command. And if it is not blatantly obvious why what you get is unsatisfactory, you should also show what you were hoping to get.

    In addition, when you say your times are 2021m3, etc. and event is 2022m2, we are left to guess whether you have string variables that look like that, or whether these are proper Stata monthly date variables with a monthly date format attached to them, or perhaps even something else. So you also need to use the -dataex- command to show us example data. If you are running version 18, 17, 16 or a fully updated version 15.1 or 14.2, -dataex- is already part of your official Stata installation. If not, run -ssc install dataex- to get it. Either way, run -help dataex- to read the simple instructions for using it. -dataex- will save you time; it is easier and quicker than typing out tables. It includes complete information about aspects of the data that are often critical to answering your question but cannot be seen from tabular displays or screenshots. It also makes it possible for those who want to help you to create a faithful representation of your example to try out their code, which in turn makes it more likely that their answer will actually work in your data.

    Comment

    Working...
    X