TH-cam recently changed the way my content will be monetised. My channel now needs 1,000 subscribers. So it would be amazing if you show your support by both watching my videos and subscribing to my channel if you haven’t done so already. Monetising my videos allows me to invest back into the channel with some new equipment so this small gesture from you will be extremely huge for me. Many thanks for your support….CrunchEconometrix loves to teach, support my Channel with your subscription and sharing my videos with your cohorts.
Your videos series on Panel ARDL using Stata have been very helpful. Will appropriate your assistance on how to interact variables in estimation. Thank you so much for all you've been doing. Hyeladi Stanley Dibal Federal University Wukari
Hi Hyeladi, thanks for the positive feedback. Interaction is when you multiply 2 variables and put them in the model. Pick up any econometrics textbook for examples. Kind regards.
Hallow @CrunchEconometrix, thank you very much for these insightful videos, my concern is how do I establish /explain convergence of a same particular variable(s) of country X and Z on Panel ARDL Output. For example, I want to know how long country X's GDP will reach country Z's GDP, or Stock market capitalization of Country X will catch up with that of country Z?. Please I really need this assistance.
Hi. And thank you for a great video. I was wondering how you would do if you would for instance have the optimal lag order to be like (2 2 2 2) how would you write the code?
Anton, I rarely use panel ARDL techniques for my articles... and if I have to, I'll use (1 0 0 0) to avoid losing too many observations and degrees of freedom.
Thank you for the good work. Please, l ran the hausman test along with the mg and pmg codes. I saw an unending trail of iterations for the pmg, which were not concave. I did not get any results for the pmg and the hausman test in the end. What could possibly be the problem? Thank you
Dear Prof. Thank you for the video. Could you let me know please about the comments for Common Correlated Effect PMG and MG ? Look forward to hearing from you. Thanks.
Hi Emre, I have videos on PMG and MG but not on their CCE variants. Though interpretations are pretty much the same. You may want to watch them. Thanks.
Hi professor, thanks for your very useful videos. I have some questions. In our work, we used cs ardl model for cross sectional dependent panel variables. Our ECT term is -1.56 and significant at 1%. In many paper said that this coefficient should be negative and lower than 1. In your video you said that "if this coefficient has negative sign and between 1 and 2, it's fine". We wonder is there a difference between panel ardl and cs ardl in terms of ECT interpretion. And also how we interpret negative and statistically significant and higher than 1 ECT coefficient?
Hi. Your videos are very helpful. Thank you for giving such a brilliant example. :)) I have a question, if I have subgroups - high and low, do I need to re-run the Hausman test on PMG and MG for these subgroups? Or, based on the earlier Hausman test result, which determined the model support PMG, it also implies the subgroups support PMG? Thank you :)
Good day professor. If I want to run a regression after checking for stationarity and I realize that the variables are stationary at their first difference, do I run the regression of their differences like you did or I just run their logs or original states?
Hello CrunchEconometrix. Thank you for the series of panel ardl. I have a question. Where we use lag selection that you found step 5. In your stata command for pmg writes ARDL(1,0,0,0) but where we use this lag selection that ı dont understand.
Hi Huseyin, thanks for the positive feedback. Deeply appreciated! This video used ARDL(1,0,0,0). It shows the steps and lags in the syntax. Kindly watch again. Kind regards.
recall ARDL lag is (p, q, q, q) where p is the lag for dv, and q is the lag for corresponding regressorsm here is three regressors. Ff you have two regressors, your ARDL lags is (p, q, q).
Ma'am, 1. How can I control seasonality in monthly panel data for pmg model? I took 12 monthly dummies. What to do now? Should I include those dummies with constant in short run? 2. Is it possible to add short run variables at level in pmg model? 3. Should I check multicollinearity, heteroscedasticity, serial correlation in pmg model?
Great questions! To control seasonality in monthly panel data for a pmg model, including 12 monthly dummies is a good start. To further address seasonality, you can also consider using seasonal adjustment techniques like seasonal decomposition of time series. As for including the dummies with the constant in the short run, it depends on the specific model and your research objectives. Experiment with different specifications and see which yields the best results!
To the best of my knowledge, it's the Hausman test. I will suggest that you post this to Statalist.org for more constructive feedback from other Stata users.
Many thanks to you I have a question. How can I fix this problem, please? xtpmg d.INF d.UN d.PG , lr(l.INF UN PG) ec(ECT) replace mg invalid new variable name; variable name ECT is in the list of predictors r(110); Note: I use Stata 17
I am doing a panel ardl regression involving renewable energy. for some countries for the first few years there were no renewable energy capacity. Thus 0 in the dependent variable for some countries for few years. for some countries it is may be 0.5 watts per capita in the beginning. i am unable to use logarithm because of 0 values and if i log 0.5 it will become a minus value. I don't know how to resolve this. dear professor, is it ok to use values as they are without converting to logarithm for dependent and independent variables.
Professor I want to know long run and short run relationship among independent and dependent variable. Some Variables are stationary at 0 level and some at 1. My questions is can I use ARDL OR SOME OTHER METHOD APPLIED
Dear Professor, I have wathced almost all of your videos. I have following questions: 1. I have N=30 and T=27 with 9 regressors containing 4 I(1) and 5 I(0). Is T>N a must follow precondition for panel ARDL? 2. How many regressors can xtpmg work with? When i run xtpmg it does iteration for long time and gives failure after a long while. Can i skip iteration process and produce results for my 9 regressors from xtpmg? Eagerly waiting for your reply. Thanks.
Hi Jony, from my experience panel ARDL performs best with (1) few variables between 3 and 5, (2) both your N and T are large which brings a conflict on the appropriate technique. It is either you reduce N or T considerably to use the applicable techniques.
Hello, thank you for your informative video. I have a little challenge. Whenever I ran the codes for the PMG and the MG I have the following errors: "initial values not feasible" r(1400); "expression (-_b[var]/_b[L.var]) evaluates to missing" respectively. Can you please help me to overcome this?
In this video at 7.28 you have the ARDL Optimal Lag selection typed above the xtpmg code. Must this be included in the process or not? When I included it above the xtpmg syntax I got the following message - ardl already defined (error occurred while loading ARDL.ado)
Hello CrunchEconometrix, Thank you for the videos. I have two questions. ..1. What does it mean if STATA did not report the p-values, standard error and the confidence interval of a particular variable? 2. What happens if i put the lags at the short-run side (example: l.d.gdppr ...) instead of the long-run side lr(l.gdppr ...). Does it mean something different. I get different results depending on where i put it.
Hello CrunchEconometrix, Please I tried using this code . When I tried it using the pmg at the end it worked, however when I tried using mg at the end of the code, it didn't work. I am currently using Stata 17. Please how do I correct this?
Miss, If I want to take lag of variables, should I write l1 for 1st, l2 for second lag? Or l(0/1) for first and l(1/2) for second lag of any variable? I am talking about pmg model.
prof, i also noticed that as u said before the command crashes with many lags . i also tried in eviews to choose for instance lag 2 for the dep. variable and lag 2 or 1 for the indep. variables in the results u only get the lag one for the dep. and lag 0 for the indep. so in my work do i have to mention the step of choosing the optimal lag or just estimate the model with lag 1 for the dep and zero lag for the inde
Hello Professor, How can we treat the dummy variable in these commands? Let us suppose I use data from 1985 to 2015 and few Asian countries have a long-run effect of Asian financial crises of 1997 onwards. If I have a binary value of 0 up to 1997 and 1 after 1998 to 2015, then how can I treat these issues?
Dear professor, I got this message on the below: . ARDL (1,1,0,0,0) program ardl already defined (error occurred while loading ARDL.ado) How can I solve this problem
Hi Geoff, the corrct syntax is "xtpmg" and not xtpgm as you have typed. Type it correctly and see if the Stata error occurs. May I know from where (location) you are reaching me?
It happen to me as well, need to check the command inside the lr ( ), as sometimes the typo, we should type l instead of 1 to refer the lag. This works for me
Hello there. A quick question. Is it possible to conduct PMG regression with time dummies, i.e. in an example where you have a monthly panel data series and want to control for month-specific effects? I would be very grateful if you could help me on this.
One question can we do all this procedure by having one dummy variable in my panel data or there are other commands for that waiting for your kind reply as soon as possible as I am stuck due to above asked question.
Hello. In step 5 you got an optimal lag selection of (1, 0, 0, 0). Do we need to include that in the commands when estimating the model (step 8)? If you got an optimal lag length of say (1, 1, 2, 2), would you still estimate the model the same way as you did with an optimal lag selection of (1, 0, 0, 0)? Best regards
Hi Nayaz, not quite. The lags will be distributed act the variables. It then becomes difficult to estimate so better to apply the (1,0,0,0) structure. Please may I know from where (location) you are reaching me?
Hi professor, when I tried running PMG full sample, the ECT is -0.1502 but not significant. Is my long-run coefficients are still reliable? How can I interpret this? Thank you very much.
Hi Everyone. I thought that after the optimal lag length for the model was established you would insert the lags of variables as they related to the code respectively. For example with this video the lag cod is (1, 0 0 0) and i was expecting to see the gdpgr variable with one lag in the syntax of the syntax of the model before it was estimated. Isn't this how panel ARDL where at least a lagged dependent variable should be included in the model which makes it dynamic.?
Hi Alistair, as said at the beginning of my video the syntax for Panel ARDL is user-written so you may not find immediate answers to these queries elsewhere. Those who have used this syntax obtained results because it works. (1,0,0,0) implies a lag of the dependent variable as a regressor while other regressors have 0 lags which makes the model dynamic. Kindly watch the series on panel ARDL again and adapt the procedure to your work. Thanks.
Hello Dr., Please can you help me with the specification of a Panel ARDL model of (1 1 1 1 1)? And can one estimate a panel ARDL (1 0 0 0 ..) without knowing the optimal lag selection? Finally, a question that has been bothering me, I conducted a panel unit root test on the log of inflation and it was stationary without trend but not stationary with a trend at both level and first difference. However, the variable is a control variable which was not stationary without the log for both trend and non-trend case. My question is can I still include it in my model for estimation given that it was stationary without trend? I await your kind response and thanks in advance.
Hi Talatu, the panel ARDL syntax in Stata is user-written which breaks down when you lag all the variables. Also, go ahead with your analysis regardless of whether the series is stationary with a trend or without.
Thank you, for this video. however, I follow the same as you did in the video but when i enter the command for pmg it start coming the Iteraction 1 log likelihood=....(not concave) and it doesnt want to stop till 500 and more and i didnt get the table yet ....please i need your help. thank you .
Hi Abdullh, a lot of factor can be responsible for that. Amongst them are (1) multicollinearity of the regressors, (2) functional form of the model e.g, log-log, level-level, level-log, log-level, (3) if there are too many countries. You can run different simulations while considering these suggestions.
Hello dear Doctor. Do we use the lags when conducting pmg? in the command there is no gdp(-1) since my ARDL (1.0.0.0) is the same as your model..... so when you have run the model you used only the data of GDP in both short and long run.... i am confusing.thank you in advance
I have a problem with the use of the command xtpmg with the mg option Infact, if I give the following command: xtpmg d.lpcco2e d.lgdp d.lpcecgj d.lopeness if EMU==0, lr(l.lpcco2e lgdp lpcecgj lopeness) ec(ECT) replace mg it does not work, giving me the following error: invalid new variable name; variable name ec is in the list of predictors r(110); Could you kindly help me? Many thanks, CM
Hi CM, the mg option works in Stata13 because I have used it severally. It is possible the option is not supported by Stata's recent versions 15 and 16.
Message STATA support and get an older copy, I had the exact same problem when using STATA 16.1 now on 14.2 it works perfectly just like is shown in the video :). The only way around it is to look on the forums for a guide to edit the STATA ado files which I found confusing.
Hello sir; I am a student in 2 years of Master in Research of the Faculty of Economics and Management of Mahdia. I have an annual database of 30 countries from 1980 to 2017. I apply the ARDL approach for this database. My problem is that the command of the ARDL is not correct (the command I use: forval i = 1/30 { ardl my variables, maxlags (p, q ......) matrix list e (delay) di }) The results are "no observations" why What is the problem with this command? help me STATA 15
hello please if I have (2 0 0 3 ) for lag = 3 we assume that the independent variable is FDI how do I write it in the request ? l.d.FDI ll.d.FDI ? or dd.l.FDI ?? sincerely
The xtpmg is a user-written code and due to the complexities of this technique particularly in Stata, I restrict to using lag (1 0 0 0) for easy estimation.
Hello Prof, i'm working on a panel ARDL with a optimal lag of (3,0,2) and the variables are Y, X1, X2. I want to know what is the commande for xtpmg for estimations by using Stata? Thanks !
I have generated a PMG model where my output includes an ECT of 0.08. How do I interpret this value? In another instance I have ECT values between -1 and -2 like what is in this video but theoretically aren't ECT values supposed to be between 0 and -1? How do we explain ECT values between -1 and -2 when theoretically they are supposed to be between 0 and -1?
Hi Alistair, ECT 0.08 implies that there is no reversion to long-run equilibrium even though the variables are co-integrated. Means the model is explosive. For ECT values between -1 and -2, cite Loayza and Ranciere (2006) to support your result. Thanks.
@@CrunchEconometrix Thanks. Could you please tell me the meaning of that lag selection command. I could not communicate it to Stata especially this "i" part
Hi again Ngozi, I need to run my panel ardl (2 1 1 2). However I wasn't able to modify the code that you provided for (1 0 0 0). I have two main questions: 1- is there any reference that (1 0 0 0) is the most common and suitable lags? 2-If our optimal lags goes beyond (1 0 0 0 ), what's the command and how could we modify the code? Many thanks for your kind help.
You cannot modify the code. I recall referring you to the Sarmagandi et al paper...and let us be careful here: there is no reference to (1 0 0 0) as being "the most common and suitable lags". You won't see that anywhere and I never said that. The authors only gave their justification for using that structure.
@@same174 The optimal lags are generated the same way whereby you use the most common lag across the countries for each variable which I explained in the video.
Dear Cruncheconometrix. Could you share the command in case of the lag length of (for example) (1,1,1,0) or (1,2,2,2). I wonder whether the lag length is used in the short run or long run part of the commands? Thanks in advance!
The lags are included in the short-run part of the equation. It's most likely your model will break down due to multicollinearity but you can try it. From experience, I don't go beyond lag(1,0,0,0) or at best lag (2,0,0,0).
Dear, Then I do not quite understand where the lag length is added. For example, in the tutorial the lag of (1,0,0,0) is used but in the short run part of command it is written as d.lngdp d.lnexp etc... from what I see, all have the lag length of 1.
@@AnhNguyen-th2ud No, u're getting it wrong. Lag(1,0,0,0) tells you that the depvar has 1 lag (which is in the long run synt) and the regressors have 0 lags. For the short-run part of the syntax, d.x1 signifies 1st difference not lags. Check the syntax again.
CrunchEconometrix its quite confusing now since in the 1st reply you have said lag is included in the short run part. Anw just to be clear, in case of lag of (1 1 1 1) for example, the command should be xtpmg d.gdp d.dcf d.exp d.tr, lr(l.gdp l.dcf l.exp l.tr) ec(ECT) replace pmg. Right?
@@AnhNguyen-th2ud Like I said before, I restrict to lag(1,0,0,0). It's possible that the lags are for the long-run part. But I'll suggest you do more findings on this.
hello Mrs ; i tried to run an ardl pmg model, using 34 countries with 7 periods data on 8 variables. I got this error message "initial values not feasible" command xtpmg d.gy d.lgdpi d.lse d.ltrade d.lm3 d.liy d.PM, lr(l.gy lgdpi lse d.ltrade lm3 liy PM) ec(ec) replace pmg when i decreased the number of variables, i got this error message "Hessian has become unstable or asymmetric r(504)" xtpmg d.gy d.lgdpi d.lse d.liy d.PM, lr(l.gy lgdpi lse liy PM) ec(ec) replace pmg Could you help me, please? Thank you indeed
Hi Meriem, you did not watch the foundation video on panel ARDL. This technique is not appropriate for your data structure. Panel ARDL works when N < T.
Thanks Prof. xtpmg d.gdpgr d.lndcf d.lnexp d.lntr, lr(l.gdpgr lndcf lnexp lntr) ec(ECT) replace pmg In this code, d.gdpgr mean first difference of dependent variable (no log)? within the parenthesis of long-run code, what does mean by l.gdpgr? Is it log of dependent variable?
@@CrunchEconometrix Thanks again. xtpmg dlnY dlnX1 dlnX2 dlnX3, lr( lnY lnX1 lnX2 lngX3) ec(ECT) replace pmg Here, I created first-difference variable: gen dX= d.X Using these codes, I find positive Error Correction Term (ECT). According to PMG approach, ECT should range from any negative value to zero. What is the reason behind positive ECT in this code?
hello dr and good afternoon, please i have tried estimating the hausman test command but i keep on getting "not sorted as results" kindly help me out in this thanks
I can't exactly point out the problem but I believe if your data structure is right and you follow the guides, there shouldn't be issues. You may have to watch the series all over and kindly pen down some notes while at it. Thanks.
@@CrunchEconometrix thank you. Btw, when i am trying to estimate the optimal lag, it keeps showing that collinear variable detected. However, the correlation matrix shows there is no two variable with a correlation of equal or greater than 0.8
By the way, the code you provided is for ardl (1 1 1 1) not (1 0 0 0). You should simply reply you don't know the code or don't have the code. I see other people here asked the same question but didn't get an answer.
Esmaeil, I clearly demonstrated the lag generating process and provided the code for replication. Surmising to ARDL (1 0 0 0) did not come abstractly. Kindly watch the clip again and adapt. You can also do further online search on the procedure. Thanks.
@@CrunchEconometrix Professor, in the Stata Journal on Estimation of nonstationary heterogeneous panels (Blackburne & Frank, 2007) the same specification of the xtpmg command as you use, is described as an ARDL(1,1,1) model. This makes sense, since you also include the first differences of all the short run parameters, and hence the lags are included in the estimation.
Pradeep, I've seen your several queries on Fb regarding panel ARDL which no one has helped you out, except with hints from me. To date, my TH-cam Channel provides the most information about this technique. So, watch the my panel ARDL videos again to understand how I got the lag structure of ARDL(1,0,0,0). Thanks.
TH-cam recently changed the way my content will be monetised. My channel now needs 1,000 subscribers. So it would be amazing if you show your support by both watching my videos and subscribing to my channel if you haven’t done so already. Monetising my videos allows me to invest back into the channel with some new equipment so this small gesture from you will be extremely huge for me. Many thanks for your support….CrunchEconometrix loves to teach, support my Channel with your subscription and sharing my videos with your cohorts.
Thank you prof .. your video tutorial s are really good, well structured and easy to understand.
Thanks for the encouraging feedback. Deeply appreciated!
Miss you are doing the marvellous job may God bless you. Really thankful to you for being my remote teacher.
Thanks for the encouraging words and feedback. Deeply appreciated! Please may I know from where (location) you are reaching me?
@@CrunchEconometrix Dear Professor I am from Sindh Pakistan and really you are the bundle of blessings for me.
Your videos series on Panel ARDL using Stata have been very helpful. Will appropriate your assistance on how to interact variables in estimation. Thank you so much for all you've been doing.
Hyeladi Stanley Dibal
Federal University Wukari
Hi Hyeladi, thanks for the positive feedback. Interaction is when you multiply 2 variables and put them in the model. Pick up any econometrics textbook for examples. Kind regards.
@@CrunchEconometrix Thank you for the reply.
Hallow @CrunchEconometrix, thank you very much for these insightful videos, my concern is how do I establish /explain convergence of a same particular variable(s) of country X and Z on Panel ARDL Output. For example, I want to know how long country X's GDP will reach country Z's GDP, or Stock market capitalization of Country X will catch up with that of country Z?. Please I really need this assistance.
Hi John, your query is outside my scope of engagement. You may want to check out other online resources. My sincere apologies 🙏
Hi. And thank you for a great video. I was wondering how you would do if you would for instance have the optimal lag order to be like (2 2 2 2) how would you write the code?
Anton, I rarely use panel ARDL techniques for my articles... and if I have to, I'll use (1 0 0 0) to avoid losing too many observations and degrees of freedom.
Thank you for the good work.
Please, l ran the hausman test along with the mg and pmg codes.
I saw an unending trail of iterations for the pmg, which were not concave. I did not get any results for the pmg and the hausman test in the end. What could possibly be the problem? Thank you
Hi Dennis, most likely multicollinearity from the underlying lags and difference terms. Reduce your explvars and re-estimate.
Dear Prof. Thank you for the video. Could you let me know please about the comments for Common Correlated Effect PMG and MG ?
Look forward to hearing from you.
Thanks.
Hi Emre, I have videos on PMG and MG but not on their CCE variants. Though interpretations are pretty much the same. You may want to watch them. Thanks.
@@CrunchEconometrix yes, l watched them, thanks. If you know CCE variants, l would be more than happy to learn them.
Hi professor, thanks for your very useful videos. I have some questions. In our work, we used cs ardl model for cross sectional dependent panel variables. Our ECT term is -1.56 and significant at 1%. In many paper said that this coefficient should be negative and lower than 1. In your video you said that "if this coefficient has negative sign and between 1 and 2, it's fine". We wonder is there a difference between panel ardl and cs ardl in terms of ECT interpretion. And also how we interpret negative and statistically significant and higher than 1 ECT coefficient?
You will have to do your findings on panel ARDL and CS-ARDL for more information.
Hi. Your videos are very helpful. Thank you for giving such a brilliant example. :))
I have a question, if I have subgroups - high and low, do I need to re-run the Hausman test on PMG and MG for these subgroups? Or, based on the earlier Hausman test result, which determined the model support PMG, it also implies the subgroups support PMG?
Thank you :)
The Hausman test may be separately performed for the sub-samples.
Hi! Thank you for this video!! I have a doubt though- can Panel ARDL be used when N>T and cointegration exists?
Hi Nausheen, use GMM. You will find the 9 GMM videos very helpful.
Good day professor. If I want to run a regression after checking for stationarity and I realize that the variables are stationary at their first difference, do I run the regression of their differences like you did or I just run their logs or original states?
Estimation models in natural logarithms is at the discretion of the researcher.
Hello CrunchEconometrix. Thank you for the series of panel ardl. I have a question. Where we use lag selection that you found step 5. In your stata command for pmg writes ARDL(1,0,0,0) but where we use this lag selection that ı dont understand.
Hi Huseyin, thanks for the positive feedback. Deeply appreciated! This video used ARDL(1,0,0,0). It shows the steps and lags in the syntax. Kindly watch again. Kind regards.
recall ARDL lag is (p, q, q, q) where p is the lag for dv, and q is the lag for corresponding regressorsm here is three regressors. Ff you have two regressors, your ARDL lags is (p, q, q).
You are very correct, Ahmad.
Ma'am,
1. How can I control seasonality in monthly panel data for pmg model? I took 12 monthly dummies. What to do now? Should I include those dummies with constant in short run?
2. Is it possible to add short run variables at level in pmg model?
3. Should I check multicollinearity, heteroscedasticity, serial correlation in pmg model?
Great questions! To control seasonality in monthly panel data for a pmg model, including 12 monthly dummies is a good start. To further address seasonality, you can also consider using seasonal adjustment techniques like seasonal decomposition of time series. As for including the dummies with the constant in the short run, it depends on the specific model and your research objectives. Experiment with different specifications and see which yields the best results!
Hello CrunchEconometrix
Please do you have any video on how to estimate using dynamic ardl simulations?
Hi Kofi, not at all. I intend learning how to perform dynamic ARDL. It's on my to-do list. Thanks
Merci 🙏
U're welcome! 🥰
Is there any other test(s) for deciding among mg, pmg and dfe?
Hausman test is not working between pmg and dfe. Also mg is not executable.
To the best of my knowledge, it's the Hausman test. I will suggest that you post this to Statalist.org for more constructive feedback from other Stata users.
Many thanks to you
I have a question. How can I fix this problem, please?
xtpmg d.INF d.UN d.PG , lr(l.INF UN PG) ec(ECT) replace mg
invalid new variable name;
variable name ECT is in the list of predictors
r(110);
Note: I use Stata 17
Hi Motaz, a lot of people are getting this error. It may be due to a bug. You may want to post this on Statalist.org for more constructive feedback.
I am doing a panel ardl regression involving renewable energy. for some countries for the first few years there were no renewable energy capacity. Thus 0 in the dependent variable for some countries for few years. for some countries it is may be 0.5 watts per capita in the beginning. i am unable to use logarithm because of 0 values and if i log 0.5 it will become a minus value. I don't know how to resolve this. dear professor, is it ok to use values as they are without converting to logarithm for dependent and independent variables.
Hi Mo, you are right. Do not take the log of negative variables. Either use the variable as it is or use a closer proxy
Professor I want to know long run and short run relationship among independent and dependent variable. Some Variables are stationary at 0 level and some at 1. My questions is can I use ARDL OR SOME OTHER METHOD APPLIED
Hi Nishu, if you are referring to a panel data where N
Dear Professor,
I have wathced almost all of your videos.
I have following questions:
1. I have N=30 and T=27 with 9 regressors containing 4 I(1) and 5 I(0).
Is T>N a must follow precondition for panel ARDL?
2. How many regressors can xtpmg work with? When i run xtpmg it does iteration for long time and gives failure after a long while. Can i skip iteration process and produce results for my 9 regressors from xtpmg?
Eagerly waiting for your reply. Thanks.
Hi Jony, from my experience panel ARDL performs best with (1) few variables between 3 and 5, (2) both your N and T are large which brings a conflict on the appropriate technique. It is either you reduce N or T considerably to use the applicable techniques.
@@CrunchEconometrix Thank you professor.
Is there any option to skip iteration process while doing xtpmg and get results fast?
Hello, thank you for your informative video.
I have a little challenge. Whenever I ran the codes for the PMG and the MG I have the following errors:
"initial values not feasible"
r(1400);
"expression (-_b[var]/_b[L.var]) evaluates to missing" respectively.
Can you please help me to overcome this?
Hi Peter, not sure what the problem is. I will suggest you post this on Statalist.org for constructive feedback. Thanks.
Miss,
If I use full option in pmg model and error correction term of few countries come insignificant and positive, what does it mean?
Insignificant means zero effect.
In this video at 7.28 you have the ARDL Optimal Lag selection typed above the xtpmg code. Must this be included in the process or not? When I included it above the xtpmg syntax I got the following message - ardl already defined
(error occurred while loading ARDL.ado)
Hi Alistair, the syntax starts with "xtpmg". See Stata output for confirmation.
Hi Alistair, the syntax starts with "xtpmg". See Stata output for confirmation.
Hello CrunchEconometrix, Thank you for the videos. I have two questions. ..1. What does it mean if STATA did not report the p-values, standard error and the confidence interval of a particular variable? 2. What happens if i put the lags at the short-run side (example: l.d.gdppr ...) instead of the long-run side lr(l.gdppr ...). Does it mean something different. I get different results depending on where i put it.
Hi Bright, (1) Stata will report those and (2) do that and observe your results.
Hello CrunchEconometrix, Please I tried using this code .
When I tried it using the pmg at the end it worked, however when I tried using mg at the end of the code, it didn't work. I am currently using Stata 17. Please how do I correct this?
Hi Kofi, the code should work. The downside with Stata codes is that they get overwritten with updates.
Miss,
If I want to take lag of variables, should I write l1 for 1st, l2 for second lag? Or l(0/1) for first and l(1/2) for second lag of any variable?
I am talking about pmg model.
Use l(1/2) for 1st and 2nd lags.
Miss, how can I estimate first lag only for long run in pmg?
I showed how in the video. Kindly follow the guide. Thanks.
Miss, in the video you took lr(l.gdpgr..) but in outcome no lagged variable of gdpgr has come.
prof, i also noticed that as u said before the command crashes with many lags . i also tried in eviews to choose for instance lag 2 for the dep. variable and lag 2 or 1 for the indep. variables
in the results u only get the lag one for the dep. and lag 0 for the indep.
so in my work do i have to mention the step of choosing the optimal lag or just estimate the model with lag 1 for the dep and zero lag for the inde
Hi Ruru, simply indicate the ARDL ( ) specifications in your paper or thesis.
Hello Professor, How can we treat the dummy variable in these commands? Let us suppose I use data from 1985 to 2015 and few Asian countries have a long-run effect of Asian financial crises of 1997 onwards. If I have a binary value of 0 up to 1997 and 1 after 1998 to 2015, then how can I treat these issues?
Hi Pradeep, I haven't attempted estimating panel ARDL with dummy variables so may not be able to offer any constructive suggestions. Thanks.
Thank you Prof, is it optional to lag all the long run variables. Thank you
I used lag (1 0 0 0) so, yes.
Dear professor,
I got this message on the below:
. ARDL (1,1,0,0,0)
program ardl already defined
(error occurred while loading ARDL.ado)
How can I solve this problem
Hi Mehmet, I have no idea what this error is about. Please click the Stata error code and follow the guide for resolution. Thanks.
Hi there, a quick question. When I run the code xtpgm, the stata displays lr: operator invalid. Does anyone know how to solve the problem?
Hi Geoff, the corrct syntax is "xtpmg" and not xtpgm as you have typed. Type it correctly and see if the Stata error occurs. May I know from where (location) you are reaching me?
You should probably install this command first. I had similar problem
It happen to me as well, need to check the command inside the lr ( ), as sometimes the typo, we should type l instead of 1 to refer the lag. This works for me
Hello there. A quick question. Is it possible to conduct PMG regression with time dummies, i.e. in an example where you have a monthly panel data series and want to control for month-specific effects? I would be very grateful if you could help me on this.
Hi Andreas, not sure if it is possible. I'll encourage you to attempt it and see the outcomes.
One question can we do all this procedure by having one dummy variable in my panel data or there are other commands for that waiting for your kind reply as soon as possible as I am stuck due to above asked question.
You can include a dummy variable.
Hello. In step 5 you got an optimal lag selection of (1, 0, 0, 0). Do we need to include that in the commands when estimating the model (step 8)? If you got an optimal lag length of say (1, 1, 2, 2), would you still estimate the model the same way as you did with an optimal lag selection of (1, 0, 0, 0)?
Best regards
Hi Nayaz, not quite. The lags will be distributed act the variables. It then becomes difficult to estimate so better to apply the (1,0,0,0) structure. Please may I know from where (location) you are reaching me?
Hi professor, when I tried running PMG full sample, the ECT is -0.1502 but not significant. Is my long-run coefficients are still reliable? How can I interpret this?
Thank you very much.
Clara, it implies reversion to LR equilibrium is statistically not significant.
Hi Everyone. I thought that after the optimal lag length for the model was established you would insert the lags of variables as they related to the code respectively. For example with this video the lag cod is (1, 0 0 0) and i was expecting to see the gdpgr variable with one lag in the syntax of the syntax of the model before it was estimated.
Isn't this how panel ARDL where at least a lagged dependent variable should be included in the model which makes it dynamic.?
Hi Alistair, as said at the beginning of my video the syntax for Panel ARDL is user-written so you may not find immediate answers to these queries elsewhere. Those who have used this syntax obtained results because it works. (1,0,0,0) implies a lag of the dependent variable as a regressor while other regressors have 0 lags which makes the model dynamic. Kindly watch the series on panel ARDL again and adapt the procedure to your work. Thanks.
why do we need to check for the optimal lag length if we'll alwasy go with lag one for the dep. and zero lags for the indep. ?
Hi Ruru, that information is needed for anyone reviewing your work.
Hello Dr.,
Please can you help me with the specification of a Panel ARDL model of (1 1 1 1 1)?
And can one estimate a panel ARDL (1 0 0 0 ..) without knowing the optimal lag selection?
Finally, a question that has been bothering me, I conducted a panel unit root test on the log of inflation and it was stationary without trend but not stationary with a trend at both level and first difference. However, the variable is a control variable which was not stationary without the log for both trend and non-trend case. My question is can I still include it in my model for estimation given that it was stationary without trend?
I await your kind response and thanks in advance.
Hi Talatu, the panel ARDL syntax in Stata is user-written which breaks down when you lag all the variables. Also, go ahead with your analysis regardless of whether the series is stationary with a trend or without.
@@CrunchEconometrix Thank you so much it has been helpful.
Ma'am what can we conclude if our PMG iterations keep on continuing and do not stop anywhere. What could be the possible problem in this case?
Hi Rochna, it happens for several reasons: multicollinearity, few observations, and functional form of the model.
Thank you, for this video. however, I follow the same as you did in the video but when i enter the command for pmg it start coming the Iteraction 1 log likelihood=....(not concave) and it doesnt want to stop till 500 and more and i didnt get the table yet ....please i need your help. thank you .
Hi Abdullh, a lot of factor can be responsible for that. Amongst them are (1) multicollinearity of the regressors, (2) functional form of the model e.g, log-log, level-level, level-log, log-level, (3) if there are too many countries. You can run different simulations while considering these suggestions.
Hello dear Doctor. Do we use the lags when conducting pmg? in the command there is no gdp(-1) since my ARDL (1.0.0.0) is the same as your model..... so when you have run the model you used only the data of GDP in both short and long run.... i am confusing.thank you in advance
Hi Dhaouia, look at the syntax again and you'll see the gdp_1 in lr( ).
@@CrunchEconometrix ok thank you i got it.
@@dhaouia1 i have this same problem, how does one incorporate the lags of variables in the model
I have a problem with the use of the command xtpmg with the mg option
Infact, if I give the following command:
xtpmg d.lpcco2e d.lgdp d.lpcecgj d.lopeness if EMU==0, lr(l.lpcco2e lgdp lpcecgj lopeness) ec(ECT) replace mg
it does not work, giving me the following error:
invalid new variable name;
variable name ec is in the list of predictors
r(110);
Could you kindly help me?
Many thanks,
CM
Hi CM, the mg option works in Stata13 because I have used it severally. It is possible the option is not supported by Stata's recent versions 15 and 16.
Message STATA support and get an older copy, I had the exact same problem when using STATA 16.1 now on 14.2 it works perfectly just like is shown in the video :). The only way around it is to look on the forums for a guide to edit the STATA ado files which I found confusing.
Hello sir;
I am a student in 2 years of Master in Research of the Faculty of Economics and Management of Mahdia. I have an annual database of 30 countries from 1980 to 2017. I apply the ARDL approach for this database. My problem is that the command of the ARDL is not correct (the command I use: forval i = 1/30 {
ardl my variables, maxlags (p, q ......)
matrix list e (delay)
di
})
The results are "no observations" why
What is the problem with this command? help me
STATA 15
Reduce N to about 10 and re-estimate.
hello please if I have (2 0 0 3 ) for lag = 3 we assume that the independent variable is FDI how do I write it in the request ? l.d.FDI ll.d.FDI ? or dd.l.FDI ??
sincerely
The xtpmg is a user-written code and due to the complexities of this technique particularly in Stata, I restrict to using lag (1 0 0 0) for easy estimation.
But what about lags?
I used (1,0,0,0) lags.
Hello Dr, I got this message while specifying the ARDL(1,0,0,2,0) : program ardl already defined
Hi Mohd, apologies for the late response, why not use my dofile? It is freely available on my website. Link is at the end of the video.
@@CrunchEconometrix
Miss,
Is the do file still freely available? I can't find if in your website. But I find many articles there.
Hello! Do we use the lags when conducting pmg? The command xtpmg..... does not seem to incorporate any of the optimal lags found from step 5
Hi there, the optimal lags are (1,0,0,0) therefore only the dependent variable is lagged. See the listed variables in "lr()".
Ok i got it.. Thnk you :)
Ashna Gangoo I'll be grateful if you tell your colleagues and social media community about my TH-cam channel 💕
Sure Mme i will do that
Hello Prof, i'm working on a panel ARDL with a optimal lag of (3,0,2) and the variables are Y, X1, X2.
I want to know what is the commande for xtpmg for estimations by using Stata?
Thanks !
I have generated a PMG model where my output includes an ECT of 0.08. How do I interpret this value?
In another instance I have ECT values between -1 and -2 like what is in this video but theoretically aren't ECT values supposed to be between 0 and -1? How do we explain ECT values between -1 and -2 when theoretically they are supposed to be between 0 and -1?
Hi Alistair, ECT 0.08 implies that there is no reversion to long-run equilibrium even though the variables are co-integrated. Means the model is explosive. For ECT values between -1 and -2, cite Loayza and Ranciere (2006) to support your result. Thanks.
@@CrunchEconometrix Thanks for your reply.
@@CrunchEconometrix Hello Prof. I am here again. How to interpret an ECT that is not significant at all but is negative and less than 1?
Hi Emillenne, an insignificant coefficient implies no impact and in this case the long-run equilibrium convergence is of NO significance.
@@CrunchEconometrix Ohhh I see. Ok thanks. But in the case of panel model, I thought the ECT value does not matter?
Professor, I missed the part. where and how did you use your results from optimal lag selection step while running the regression of the model?
The optimal lags (1,0,0,0)are included in the model specification. Kindly watch the clip again.
@@CrunchEconometrix Thanks. Could you please tell me the meaning of that lag selection command. I could not communicate it to Stata especially this "i" part
@@akhliddinismailov3766 The is the country identifiers.
Hi again Ngozi,
I need to run my panel ardl (2 1 1 2). However I wasn't able to modify the code that you provided for (1 0 0 0). I have two main questions:
1- is there any reference that (1 0 0 0) is the most common and suitable lags?
2-If our optimal lags goes beyond (1 0 0 0 ), what's the command and how could we modify the code?
Many thanks for your kind help.
You cannot modify the code. I recall referring you to the Sarmagandi et al paper...and let us be careful here: there is no reference to (1 0 0 0) as being "the most common and suitable lags". You won't see that anywhere and I never said that. The authors only gave their justification for using that structure.
CrunchEconometrix so that means we don't have a command for the other optimal lags?
@@same174 The optimal lags are generated the same way whereby you use the most common lag across the countries for each variable which I explained in the video.
CrunchEconometrix I meant a command for something like (2 1 3 0 ) rather than (1 0 0 0)
@@same174 Please watch my video again to understand how panel ARDL optimal lags are generated. I think that will clarify a lot of issues. Thanks.
Dear Cruncheconometrix. Could you share the command in case of the lag length of (for example) (1,1,1,0) or (1,2,2,2). I wonder whether the lag length is used in the short run or long run part of the commands? Thanks in advance!
The lags are included in the short-run part of the equation. It's most likely your model will break down due to multicollinearity but you can try it. From experience, I don't go beyond lag(1,0,0,0) or at best lag (2,0,0,0).
Dear,
Then I do not quite understand where the lag length is added. For example, in the tutorial the lag of (1,0,0,0) is used but in the short run part of command it is written as d.lngdp d.lnexp etc... from what I see, all have the lag length of 1.
@@AnhNguyen-th2ud No, u're getting it wrong. Lag(1,0,0,0) tells you that the depvar has 1 lag (which is in the long run synt) and the regressors have 0 lags. For the short-run part of the syntax, d.x1 signifies 1st difference not lags. Check the syntax again.
CrunchEconometrix its quite confusing now since in the 1st reply you have said lag is included in the short run part. Anw just to be clear, in case of lag of (1 1 1 1) for example, the command should be xtpmg d.gdp d.dcf d.exp d.tr, lr(l.gdp l.dcf l.exp l.tr) ec(ECT) replace pmg. Right?
@@AnhNguyen-th2ud Like I said before, I restrict to lag(1,0,0,0). It's possible that the lags are for the long-run part. But I'll suggest you do more findings on this.
hello Mrs
; i tried to run an ardl pmg model, using 34 countries with 7 periods data on 8 variables.
I got this error message "initial values not feasible"
command
xtpmg d.gy d.lgdpi d.lse d.ltrade d.lm3 d.liy d.PM, lr(l.gy lgdpi lse d.ltrade lm3 liy PM) ec(ec) replace pmg
when i decreased the number of variables, i got this error message "Hessian has become unstable or asymmetric r(504)"
xtpmg d.gy d.lgdpi d.lse d.liy d.PM, lr(l.gy lgdpi lse liy PM) ec(ec) replace pmg
Could you help me, please? Thank you indeed
Hi Meriem, you did not watch the foundation video on panel ARDL. This technique is not appropriate for your data structure. Panel ARDL works when N < T.
@@CrunchEconometrix thank you for your reply but i redid the estimation with only 2 countries and 7 T and I got the same error message
Meriem, long T of at least 30 years.
@@CrunchEconometrix hi maam ,
do you have any reference regarding this?
For reference, search the Stata HELP menu for xtpmg syntax.
Thanks Prof. xtpmg d.gdpgr d.lndcf d.lnexp d.lntr, lr(l.gdpgr lndcf lnexp lntr) ec(ECT) replace pmg In this code, d.gdpgr mean first difference of dependent variable (no log)? within the parenthesis of long-run code, what does mean by l.gdpgr? Is it log of dependent variable?
Hi Mohd, that is the 1st LAG of the depvar.
@@CrunchEconometrix Thanks again. xtpmg dlnY dlnX1 dlnX2 dlnX3, lr( lnY lnX1 lnX2 lngX3) ec(ECT) replace pmg Here, I created first-difference variable: gen dX= d.X Using these codes, I find positive Error Correction Term (ECT). According to PMG approach, ECT should range from any negative value to zero. What is the reason behind positive ECT in this code?
Positive ECT in this code OR in your output?
@@CrunchEconometrix In my output
Mohd, getting a positive ECT is study-specific. Implies the model is explosive. Changing variables and augmenting lags may reverse the position.
excuse me, Mam, IS it possible that we get r square value for MG and PMG in short-run?
Hi Arjun, did you get that when you did your estimation?
No madam, I didn't . In your estimation also I couldn't see it. That's why I asked. How I can get that? Kindly lead me.
@@arjunkrishna9619 I know you didn't, I deliberately asked. Simply report what you have or you might use EViews to know if you can get the Rsq.
hello dr and good afternoon, please i have tried estimating the hausman test command but i keep on getting "not sorted as results" kindly help me out in this thanks
You have to run the xtset command first. I mentioned that.
I did that before starting the descriptive statistics and corrections including other test but for the mg and pmg cannot be estimated.
@@dorstellgh6238 Why not follow the steps as outlined in my dofile?
Hi there
When i attempt to run the pmg, it shows Hessian has become unstable and asymmetric and no result is shown, may i knoq how to solve it?
Hi ZK, did you follow the procedures from the onset? Did you watch the preceding videos?
@@CrunchEconometrix yes。。but as a beginner.. I not sure which part i messed up which resulting in this error message....
I can't exactly point out the problem but I believe if your data structure is right and you follow the guides, there shouldn't be issues. You may have to watch the series all over and kindly pen down some notes while at it. Thanks.
@@CrunchEconometrix thank you. Btw, when i am trying to estimate the optimal lag, it keeps showing that collinear variable detected. However, the correlation matrix shows there is no two variable with a correlation of equal or greater than 0.8
@@zkc2230 What is your panel structure?
By the way, the code you provided is for ardl (1 1 1 1) not (1 0 0 0). You should simply reply you don't know the code or don't have the code. I see other people here asked the same question but didn't get an answer.
Esmaeil, I clearly demonstrated the lag generating process and provided the code for replication. Surmising to ARDL (1 0 0 0) did not come abstractly. Kindly watch the clip again and adapt. You can also do further online search on the procedure. Thanks.
please help me i have same problem..command should be modified according to optimal lag. I have (2,1,2) lag then what should be the command.
@@CrunchEconometrix Professor, in the Stata Journal on Estimation of nonstationary heterogeneous panels (Blackburne & Frank, 2007) the same specification of the xtpmg command as you use, is described as an ARDL(1,1,1) model. This makes sense, since you also include the first differences of all the short run parameters, and hence the lags are included in the estimation.
If you say so.
Hi Mam, how the cross-sectional dependence can be handled in PMG estimation?
Hi Kamrul, PMG uses a combination of differencing and lags which takes care of CSD. Or better still, use CCE estimator.
Mam please can you give me Stata do file for all this?
Due to abuse, Stata dofiles used in my videos are no longer free but available on my website upon payment cruncheconometrix.com.ng/shop
Is it Ardl (1, 0, 0, 0) or (1, 1, 1, 1) model?
ARDL (1,0,0,0)
CrunchEconometrix Professor, I request you to think once again.
Pradeep, I've seen your several queries on Fb regarding panel ARDL which no one has helped you out, except with hints from me. To date, my TH-cam Channel provides the most information about this technique. So, watch the my panel ARDL videos again to understand how I got the lag structure of ARDL(1,0,0,0). Thanks.
where's the t-statistic ?
Use the "z".