Announcement

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

  • #16
    Code:
     
     regress lIntrestIncome_w lPF_w lPL_w  lequity_asset_w  lCapitaladequacyratio lasset lPK_w
    also I tried with the below command
    Code:
     
     statsby, by(Banks year) clear : regress lIntrestIncome_w lPF_w lPL_w lequity_asset_w lCapitaladequacyratio lasset lPK_w
    so the result I got after running the command was
    Code:
    -> banks = KOTAK , Year = 2005
    insufficient observations
    
    ---------------------------------------------------------------------------------------------------
    -> banks = KOTAK, Year = 2006
    insufficient observations
    
    ---------------------------------------------------------------------------------------------------
    -> banks = KOTAK , Year = 2007
    insufficient observations
    
    ---------------------------------------------------------------------------------------------------
    -> banks = KOTAK , Year = 2008
    insufficient observations
    So I have formulated this analysis based on the research paper.In the paper also they had 1347 panel observations for 20 years .the peculiarity of the data is if a bank open in 2010,I will only have data from 2010 and eventhough my analysis focus from 2005 to 19.Is there any way I can tackle this issue while running the analysis.

    Comment


    • #17

      You can do this

      Code:
      egen group = group(Banks Year)  
       statsby, by(group) clear : regress
      with -- naturally -- your variables mentioned after regress. That will reduce your problem as regress will not be asked to work on (Banks, year) pairs that do not occur in your dataset.

      Comment


      • #18
        I am getting some error like below
        Code:
        statsby, by(group) clear : reg lIntrestIncome_w lPF_w lPL_w lequity_asset_w lCapitaladequacyratio lasset lPK_w
        Statsby groups
        ----+--- 1 ---+--- 2 ---+--- 3 ---+--- 4 ---+--- 5 
        xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx    50
        xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx   100
        xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx   150
        xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx   200
        xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx   250
        xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx   300
        xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx   350
        xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx   400
        xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx   450
        xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx   500
        xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx   550
        xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx   600
        xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx   650
        xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx   700
        xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx   750
        xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx   800
        xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx   850
        xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx   900
        xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx   950
        xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx  1000
        xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx  1050
        xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx  1100
        xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx  1150
        xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

        Comment


        • #19
          If you have standard panel data, then you have one observation each year for each bank. In that case the variable group will just identify a single observation. You can never do any regression on a single observation. So I don't think your data is compatible with the advice in #17. (I can't be sure. The only example data you posted in this thread does not contain a year variable, so I am just assuming you have only one observation per year per bank because you have described it as panel data, and that is the usual arrangement.)

          I suggest you do the following:
          Code:
          regress lIntrestIncome_w lPF_w lPL_w lequity_asset_w lCapitaladequacyratio lasset lPK_w
          tab Bank if e(sample)
          (Do not use any -by- or -statsby- or -runby- with the above -regress-. Just run it plain.

          The table will then show you how many observations each bank can contribute to the estimation. My guess, based on the results you are getting, is that the table itself will not appear and you will be told that there are no observations. That means that the number of observations in each bank is too small to support a regression with that many variables. If you do get a table, it will show you which banks have enough observations to undergo that analysis, and how many observations each such bank makes available to it. If you have no banks with enough observations, or too few for your purposes, the only solutions to that are to get more data, or, simplify the analysis by removing variables from the regression until you can run it on a sufficient number of banks. Once you have done that, any of the solutions offered earlier in this thread should serve.

          Comment


          • #20
            Thanks a lot @Cylde Schechter
            Actullay I have run the regression after incorporating your sugggestions
            Code:
            tab Bank if e(sample)
            
                                              Banks |      Freq.     Percent        Cum.
            ----------------------------------------+-----------------------------------
                          AB BANK LIMITED           |         15        1.41        1.41
                     ABU DHABI COMMERCIAL BANK      |         15        1.41        2.81
                     ALLAHABAD BANK                 |         15        1.41        4.22
                     AMERICAN EXPRESS BANKING CORP. |         14        1.31        5.53
                     ANDHRA BANK                    |         15        1.41        6.94
                                          AXIS BANK |         15        1.41        8.35
                               BANK OF AMERICA N.A. |         15        1.41        9.76
                    BANK OF BAHRAIN & KUWAIT B.S.C. |         15        1.41       11.16
                                     BANK OF BARODA |         15        1.41       12.57
                                     BANK OF CEYLON |         15        1.41       13.98
                                      BANK OF INDIA |         15        1.41       15.38
                                BANK OF MAHARASHTRA |         15        1.41       16.79
                                BANK OF NOVA SCOTIA |         15        1.41       18.20
                                  BARCLAYS BANK PLC |         15        1.41       19.61
                                        BNP PARIBAS |         15        1.41       21.01
                     CANARA BANK                    |         15        1.41       22.42
                           CATHOLIC SYRIAN BANK LTD |         15        1.41       23.83
                              CENTRAL BANK OF INDIA |         14        1.31       25.14
                                      CITIBANK N.A. |         15        1.41       26.55
                            CITY UNION BANK LIMITED |         15        1.41       27.95
                     CORPORATION BANK               |         15        1.41       29.36
            CREDIT AGRICOLE CORPORATE AND INVESTM.. |         15        1.41       30.77
                                         CTBC BANK  |         15        1.41       32.18
                                DBS BANK INDIA LTD. |         15        1.41       33.58
                            DCB BANK LIMITED        |         15        1.41       34.99
                     DENA BANK                      |         15        1.41       36.40
                                   DEUTSCHE BANK AG |         15        1.41       37.80
                                     DHANLAXMI BANK |         15        1.41       39.21
                                       FEDERAL BANK |         15        1.41       40.62
                                         HDFC BANK  |         15        1.41       42.03
            HONGKONG AND SHANGHAI BANKING CORPN.L.. |         15        1.41       43.43
                            HSBC BANK OMAN S.A.O.G. |         11        1.03       44.47
                                         ICICI BANK |         15        1.41       45.87
                                  IDBI BANK LIMITED |         15        1.41       47.28
                     INDIAN BANK                    |         15        1.41       48.69
                     INDIAN OVERSEAS BANK           |         15        1.41       50.09
                                     INDUSIND BANK  |         15        1.41       51.50
                                     ING VYSYA BANK |         11        1.03       52.53
                           JAMMU & KASHMIR BANK LTD |         15        1.41       53.94
                          JP MORGAN CHASE BANK N.A. |         11        1.03       54.97
                                 KARNATAKA BANK LTD |         15        1.41       56.38
                                   KARUR VYSYA BANK |         15        1.41       57.79
                                        KBC BANK NV |         11        1.03       58.82
                            KOTAK MAHINDRA BANK LTD |         15        1.41       60.23
             KRUNG THAI BANK PUBLIC COMPANY LIMITED |         15        1.41       61.63
                                 LAKSHMI VILAS BANK |         15        1.41       63.04
                                   MASHREQ BANK PSC |         15        1.41       64.45
                            MIZUHO BANK LTD         |         15        1.41       65.85
                                    MUFG BANK, LTD. |         15        1.41       67.26
                         NAINITAL BANK              |         15        1.41       68.67
                          ORIENTAL BANK OF COMMERCE |         15        1.41       70.08
                   PUNJAB AND SIND BANK             |         14        1.31       71.39
                     PUNJAB NATIONAL BANK           |         15        1.41       72.80
                                                RBL |         15        1.41       74.20
                               SBM BANK (INDIA) LTD |         15        1.41       75.61
                                       SHINHAN BANK |         15        1.41       77.02
                     SOCIETE GENERALE               |         15        1.41       78.42
                     SONALI BANK                    |         15        1.41       79.83
                                  SOUTH INDIAN BANK |         15        1.41       81.24
                     STANDARD CHARTERED BANK        |         15        1.41       82.65
                     STATE BANK OF BIKANER & JAIPUR |         13        1.22       83.86
                            STATE BANK OF HYDERABAD |         13        1.22       85.08
                                STATE BANK OF INDIA |         15        1.41       86.49
                               STATE BANK OF MYSORE |         13        1.22       87.71
                              STATE BANK OF PATIALA |         13        1.22       88.93
                           STATE BANK OF TRAVANC |         13        1.22       90.15
                     SYNDICATE                              |         15        1.41       91.56
                       TAMILNAD  |                                    15        1.41       92.96
                                           UCO  |                       15        1.41       94.37
                                UNION BANK  |            15        1.41       95.78
                               UNITED BANK |           15        1.41       97.19
                     VIJAYA                  |                15        1.41       98.59
                                      YES . |                 15        1.41      100.00
            but after running the statsby command ,all my coefficients are the same,but it shouldnt be the results.Each coeeficients has to be diffrent,Can you please guide me if any solution exsiists
            Code:
            _
            egen group = group(Banks Year)  
            
            .  statsby, by(group) clear : regress
            (running regress on estimation sample)
            
                  command:  regress
                       by:  group
            
            
            b_PK    _b_PF    _b_PL    _b_lnAsset    _b_lCRAR    _b_lnLAn    _b_lnEQ    _b_cons
            .1490786    -.0414518    -.0090536    .9952633    .075631    .1098127    -.131868    -2.62189
            .1490786    -.0414518    -.0090536    .9952633    .075631    .1098127    -.131868    -2.62189
            .1490786    -.0414518    -.0090536    .9952633    .075631    .1098127    -.131868    -2.62189
            .1490786    -.0414518    -.0090536    .9952633    .075631    .1098127    -.131868    -2.62189
            .1490786    -.0414518    -.0090536    .9952633    .075631    .1098127    -.131868    -2.62189
            .1490786    -.0414518    -.0090536    .9952633    .075631    .1098127    -.131868    -2.62189
            .1490786    -.0414518    -.0090536    .9952633    .075631    .1098127    -.131868    -2.62189
            .1490786    -.0414518    -.0090536    .9952633    .075631    .1098127    -.131868    -2.62189
            .1490786    -.0414518    -.0090536    .9952633    .075631    .1098127    -.131868    -2.62189
            .1490786    -.0414518    -.0090536    .9952633    .075631    .1098127    -.131868    -2.62189

            Comment


            • #21
              The command -statsby, by(group) clear : regress- makes no sense. It contains no variables at all! To be honest, I don't understand why it produces any results at all. But given that it did, I wouldn't expect them to make any sense. Also, as I tried to make clear in #19, you should not be doing this by bank and year: your data, I believe, have only one observation per bank and year. (You describe your data as running from 2005 to 2019, which is 15 years, and looking at the output of the -tab- command it is clear that the number of observations per Bank is always 15 or fewer. So unless you have a very unusual kind of data set, you have one observation per year per bank (with some banks missing some years). You should be doing it only by Bank.

              So
              Code:
              statsby, by(Bank) clear: regress lIntrestIncome_w lPF_w lPL_w lequity_asset_w lCapitaladequacyratio lasset lPK_w
              should run and produce results for those Banks that appear in the -tab- output you show above. If it does not, then you need to post back with example data from the actual data set you are using (the example data earlier in this thread doesn't even contain these variables), and show the exact code you tried and the exact results you get in the Results window. Also use -dataex- to show the what the data set in memory after -statsby- looks like.

              Now, that said, with 15 or fewer data points per bank 6 predictor variables, these individual bank regressions are going to be of very limited usefulness in their own right. You really need a much larger amount of data per bank to fit a regression with so many variables and have the results be reliable.

              Comment


              • #22
                Thankyou so much.I will try to incorporate the your valuable suggestions.

                Comment

                Working...
                X