Announcement

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

  • GMM maximization: estimating theta-vector which maximizes utility

    Good afternoon,

    I have a question regarding the maximization of a utility functions using Stata in a portfolio optimization setting.

    I would like to use the GMM command to optimize different utility functions (for example the objective function in the file attached), in a way similar to Brandt, Santa-Clara & Valkanov (2009). The goal is to find asset weights that maximize utility. However, my econometric knowledge is very limited and I have struggled with implementing the model for a long time. Therefore, I would like to ask if anyone knows how to form the expressions and how to format the data to make the GMM function in Stata perform the right actions.

    The variable I want to maximize is return. My variables in xi,t are std_BTM, std_log_ME, std_lreturn, std_vol, and std_dvrate, however these variables are not formatted as a maxtrix/vector (since I am not certain whether this is necessary or not). And the coefficients in theta are the ones I want to estimate (these are the ones being multiplied with xi,t).

    I have tried the following command, with gamma=2, and wb is the benchmark weight, in order to first estimate the coefficients for the first 10 years of data (in correspondence with the paper). Since stata.com states that GMM minimizes the function, I used a minus sign in front of the command, since I want the function to be maximized.:
    Code:
    by year: gmm (-(1/(1-2)*(wb*return + ({xb: std_BTM std_log_ME std_lreturn std_vol std_dvrate}*return))) if year<=1972, instruments(std_BTM std_log_ME std_lreturn std_vol std_dvrate) i
    However, I have some doubts about the correctness of this command. First of all, I read that the 'instruments'-option has got to do with endogenous vs. exogenous variables. Second of all, when using Stata's graphical interface (Statistics->Endogenous covariates->Generalized method of moments estimation), there is a tab 'optimization', where you need to enter initial values, for which I have no idea what to enter. Third of all, coefficients are not really consistent with empirical findings in the literature.

    Perhaps anyone can help me with the right command, or if not, recommend me some sort of novice guide as to how GMM optimization works. I have searched intensively for this kind of guide, but it is mostly about why you would want to use GMM and the underlying assumptions, and even proofs, while I'm looking for more of a 'how-to' guide.

    Thanks in advance.


    Martin Pott



    Attached Files

  • #2
    I noticed I made some mistakes. Of course, I want to maximize the entire function, so not just the variable 'return', as stated above.

    Furthermore, I forgot the quadratic part, the command I entered was supposed to be:
    Code:
    (-((1/(1-2)*(wb*return + ({xb: std_BTM std_log_ME std_lreturn std_vol std_dvrate}*return)))^(1-2)) if year<=1972, instruments(std_BTM std_log_ME std_lreturn std_vol std_dvrate) i
    However, this gives the following error: could not calculate numerical derivatives -- flat or discontinuous region encountered So this gives me an additional issue...

    Comment

    Working...
    X