Blundell Bond estimator を使用して gmm モデルを確立したので、個人をグループにクラスタリングしたいと思います。データセットには既に変数があります (例: 値 1 ~ 4)。目的は、このクラスターの観測されていない不均一性を捉えることです。
- pgmm関数でデータをクラスタ化することはできますか?
- コード関数にクラスターを追加するにはどうすればよいですか?
ここに私のデータがあります:
data<-structure(list(id = structure(c(1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 3L, 3L, 3L, 3L, 3L, 3L,
3L, 3L, 3L, 3L, 3L, 3L, 3L, 3L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L,
4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L,
4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 5L, 5L, 5L, 5L, 5L,
5L, 5L, 5L, 5L, 5L, 5L, 5L, 5L, 5L, 5L, 5L, 5L, 5L, 5L, 5L, 5L,
5L, 5L, 5L, 5L, 5L, 5L, 5L, 5L, 5L, 5L, 5L, 5L, 5L, 5L, 5L, 5L,
5L, 5L, 5L, 5L, 5L, 5L, 6L, 6L, 6L, 6L, 6L, 6L, 6L, 6L, 6L, 6L,
6L, 6L, 6L, 6L, 6L, 6L, 6L, 6L, 6L, 6L, 6L, 6L, 6L, 6L, 6L, 6L,
6L, 6L, 6L, 6L, 6L, 6L, 6L, 6L, 6L, 6L, 6L, 6L, 6L, 6L, 6L, 6L,
6L, 6L, 7L, 7L, 7L, 7L, 7L, 7L, 7L, 7L, 7L, 7L, 7L, 7L, 7L, 7L,
7L, 7L, 7L, 7L, 7L, 8L, 8L, 8L, 8L, 8L, 8L, 8L, 8L, 8L, 8L, 8L,
8L, 8L, 8L, 8L, 8L, 8L, 8L, 8L, 8L, 8L, 8L, 8L, 8L, 8L, 8L, 8L,
8L, 9L, 9L, 9L, 9L, 9L, 9L, 9L, 9L, 9L, 9L, 9L, 9L, 9L, 9L, 9L,
9L, 9L, 9L, 9L, 9L, 9L, 9L, 9L, 9L, 9L, 10L, 10L, 10L, 10L, 10L,
10L, 10L, 10L, 10L, 10L, 10L, 10L, 10L, 10L, 10L, 10L, 10L, 10L,
10L, 10L, 10L, 10L, 10L, 10L, 10L, 10L, 10L, 10L, 10L, 10L, 10L,
10L, 10L, 10L, 10L, 10L, 10L, 10L, 10L, 10L, 10L, 10L, 10L, 10L,
10L, 10L, 10L, 11L, 11L, 11L, 11L, 11L, 11L, 11L, 11L, 11L, 11L,
11L, 11L, 11L, 11L, 11L, 11L, 11L, 11L, 11L, 11L, 11L, 11L, 11L,
11L, 11L, 11L, 11L, 11L, 11L, 11L, 11L, 11L, 11L, 11L, 11L, 11L,
11L, 11L, 11L, 11L, 11L, 11L, 11L, 11L, 11L, 12L, 12L, 12L, 12L,
12L, 12L, 12L, 12L, 12L, 12L, 12L, 12L, 12L, 12L, 12L, 12L, 12L,
12L, 12L, 12L, 12L, 12L, 12L, 12L, 12L, 12L, 12L, 12L, 12L, 12L,
12L, 12L, 12L, 12L, 12L, 12L, 12L, 12L, 12L, 12L, 12L, 12L, 12L,
12L, 12L, 12L, 12L, 12L, 12L, 13L, 13L, 13L, 13L, 13L, 13L, 13L,
13L, 13L, 13L, 13L, 13L, 13L, 13L, 13L, 13L, 13L, 13L, 13L, 13L,
13L, 14L, 14L, 14L, 14L, 14L, 14L, 14L, 14L, 14L, 14L, 14L, 14L,
14L, 14L, 14L, 14L, 14L, 14L, 14L, 14L, 14L, 14L, 14L, 14L, 14L,
14L, 14L, 14L, 14L, 14L), .Label = c("1", "2", "3", "4", "5",
"6", "7", "8", "9", "10", "11", "12", "13", "14", "15", "16",
"17", "18", "19", "20", "21", "22", "23", "24", "25", "26", "27",
"28", "29", "30", "31", "32", "33", "34", "35", "36", "37", "38",
"39", "40", "41", "42", "43", "44", "45", "46", "47", "48", "49",
"50", "51", "52", "53", "54", "55", "56", "57", "58", "59", "60",
"61", "62", "63", "64", "65", "66", "67", "68", "69", "70", "71",
"72", "73", "74", "75", "76", "77", "78", "79", "80", "81", "82",
"83", "84", "85", "86", "87", "88", "89", "90", "91", "92", "93",
"94", "95", "96", "97", "98", "99", "100", "101", "102", "103",
"104", "105", "106", "107", "108", "109", "110", "111", "112",
"113", "114", "115", "116", "117", "118", "119", "120", "121",
"122", "123", "124", "125", "126", "127", "128", "129", "130",
"131", "132", "133", "134", "135", "136", "137", "138", "139",
"140", "141", "142", "143", "144", "145", "146", "147", "148",
"149", "150", "151", "152", "153", "154", "155", "156", "157",
"158", "159", "160", "161", "162", "163", "164", "165", "166",
"167", "168", "169", "170", "171", "172", "173", "174", "175",
"176", "177", "178", "179", "180", "181", "182", "183", "184",
"185", "186", "187", "188", "189", "190", "191", "192", "193",
"194", "195", "196", "197", "198", "199", "200", "201", "202",
"203", "204", "205", "206", "207", "208", "209", "210", "211",
"212", "213", "214", "215", "216", "217", "218", "219", "220",
"221", "222", "223", "224", "225", "226", "227", "228", "229",
"230", "231", "232", "233", "234", "235", "236", "237", "238",
"239", "240", "241", "242", "243", "244", "245", "246", "247",
"248", "249", "250", "254", "255", "256", "257", "258", "259",
"260", "261", "262", "263", "264", "265", "266", "267", "268",
"269", "270", "271", "272", "273", "274", "275", "276", "277",
"278", "279", "280", "281", "282", "283", "284", "285", "286",
"287", "288", "289", "290", "291", "292", "293", "294", "295",
"296", "297", "298", "299", "300", "301", "302", "303", "304",
"305", "306", "307", "308", "309", "310", "311", "312", "313",
"314", "315", "316", "317", "318", "319", "320", "321", "322",
"323", "324", "325", "326", "327", "328", "329", "330", "331",
"332", "333", "334", "335", "336", "337", "338", "339", "340",
"341", "342", "343", "344", "345", "346", "347", "348", "349",
"350", "351", "352", "353", "354", "355", "356", "357", "358",
"359", "360", "361", "362", "363", "364", "365", "366", "367",
"368", "369", "370", "371", "372", "373", "374", "375", "376",
"377", "378", "379", "380", "381", "382", "383", "384", "385",
"386", "387", "388", "389", "390", "391", "392", "393", "394",
"395", "396", "397", "398", "399", "400", "401", "402", "403",
"404", "405", "406", "407", "408", "409", "410", "411", "412",
"413", "414", "415", "416", "417", "418", "419", "420", "421",
"422", "423", "424", "425", "427", "428", "429", "430", "431",
"432", "433", "434", "435", "436"), class = "factor"), year = structure(c(1L,
2L, 3L, 4L, 5L, 6L, 7L, 8L, 9L, 10L, 11L, 12L, 13L, 14L, 15L,
16L, 17L, 1L, 2L, 3L, 4L, 5L, 6L, 7L, 8L, 9L, 10L, 11L, 12L,
13L, 14L, 15L, 16L, 17L, 18L, 19L, 20L, 21L, 22L, 23L, 24L, 25L,
26L, 27L, 28L, 29L, 30L, 31L, 32L, 33L, 1L, 2L, 3L, 4L, 5L, 6L,
7L, 8L, 9L, 10L, 11L, 12L, 13L, 14L, 1L, 2L, 3L, 4L, 5L, 6L,
7L, 8L, 9L, 10L, 11L, 12L, 13L, 14L, 15L, 16L, 17L, 18L, 19L,
20L, 21L, 22L, 23L, 24L, 25L, 26L, 27L, 28L, 29L, 30L, 31L, 32L,
33L, 34L, 35L, 1L, 2L, 3L, 4L, 5L, 6L, 7L, 8L, 9L, 10L, 11L,
12L, 13L, 14L, 15L, 16L, 17L, 18L, 19L, 20L, 21L, 22L, 23L, 24L,
25L, 26L, 27L, 28L, 29L, 30L, 31L, 32L, 33L, 34L, 35L, 36L, 37L,
38L, 39L, 40L, 41L, 42L, 43L, 1L, 2L, 3L, 4L, 5L, 6L, 7L, 8L,
9L, 10L, 11L, 12L, 13L, 14L, 15L, 16L, 17L, 18L, 19L, 20L, 21L,
22L, 23L, 24L, 25L, 26L, 27L, 28L, 29L, 30L, 31L, 32L, 33L, 34L,
35L, 36L, 37L, 38L, 39L, 40L, 41L, 42L, 43L, 44L, 1L, 2L, 3L,
4L, 5L, 6L, 7L, 8L, 9L, 10L, 11L, 12L, 13L, 14L, 15L, 16L, 17L,
18L, 19L, 1L, 2L, 3L, 4L, 5L, 6L, 7L, 8L, 9L, 10L, 11L, 12L,
13L, 14L, 15L, 16L, 17L, 18L, 19L, 20L, 21L, 22L, 23L, 24L, 25L,
26L, 27L, 28L, 1L, 2L, 3L, 4L, 5L, 6L, 7L, 8L, 9L, 10L, 11L,
12L, 13L, 14L, 15L, 16L, 17L, 18L, 19L, 20L, 21L, 22L, 23L, 24L,
25L, 1L, 2L, 3L, 4L, 5L, 6L, 7L, 8L, 9L, 10L, 11L, 12L, 13L,
14L, 15L, 16L, 17L, 18L, 19L, 20L, 21L, 22L, 23L, 24L, 25L, 26L,
27L, 28L, 29L, 30L, 31L, 32L, 33L, 34L, 35L, 36L, 37L, 38L, 39L,
40L, 41L, 42L, 43L, 44L, 45L, 46L, 47L, 1L, 2L, 3L, 4L, 5L, 6L,
7L, 8L, 9L, 10L, 11L, 12L, 13L, 14L, 15L, 16L, 17L, 18L, 19L,
20L, 21L, 22L, 23L, 24L, 25L, 26L, 27L, 28L, 29L, 30L, 31L, 32L,
33L, 34L, 35L, 36L, 37L, 38L, 39L, 40L, 41L, 42L, 43L, 44L, 45L,
1L, 2L, 3L, 4L, 5L, 6L, 7L, 8L, 9L, 10L, 11L, 12L, 13L, 14L,
15L, 16L, 17L, 18L, 19L, 20L, 21L, 22L, 23L, 24L, 25L, 26L, 27L,
28L, 29L, 30L, 31L, 32L, 33L, 34L, 35L, 36L, 37L, 38L, 39L, 40L,
41L, 42L, 43L, 44L, 45L, 46L, 47L, 48L, 49L, 1L, 2L, 3L, 4L,
5L, 6L, 7L, 8L, 9L, 10L, 11L, 12L, 13L, 14L, 15L, 16L, 17L, 18L,
19L, 20L, 21L, 1L, 2L, 3L, 4L, 5L, 6L, 7L, 8L, 9L, 10L, 11L,
12L, 13L, 14L, 15L, 16L, 17L, 18L, 19L, 20L, 21L, 22L, 23L, 24L,
25L, 26L, 27L, 28L, 29L, 30L), .Label = c("1", "2", "3", "4",
"5", "6", "7", "8", "9", "10", "11", "12", "13", "14", "15",
"16", "17", "18", "19", "20", "21", "22", "23", "24", "25", "26",
"27", "28", "29", "30", "31", "32", "33", "34", "35", "36", "37",
"38", "39", "40", "41", "42", "43", "44", "45", "46", "47", "48",
"49", "50", "51", "52", "53", "54", "55", "56", "57", "58", "59",
"60"), class = "factor"), A = c(4.72947580347601, 6.8943168377758,
12.7629484858811, 23.1144507781772, 34.5485050833699, 43.6974340582264,
49.8349446587678, 54.7151893358877, 58.7128597780387, 62.1988800953951,
64.8636951165934, 66.6552983942346, 68.3225196145829, 70.6065251112773,
73.6243823108248, 77.0009106830125, 80.7328403191194, 0.78259279462847,
1.91265309286479, 2.30695074757949, 2.41558710033076, 2.72721166076995,
3.71647616603042, 5.79613925190112, 8.59086041041136, 15.150044968793,
19.5511564981921, 21.0006854462852, 21.9340700157861, 22.8529796974857,
23.6602981317699, 25.1316505171629, 26.8686868686869, 28.5796722286843,
30.2648263992137, 32.8632484267938, 35.42254384889, 39.2495452275085,
44.5595414119088, 51.5018239516889, 59.6527095354814, 67.3587233746234,
73.0134107354234, 75.8339722572885, 76.8614795580844, 77.2354812447547,
78.0635423609346, 79.5309075085135, 81.0802110457454, 82.6821439624762,
91.5291472344021, 104.96982594475, 118.216844807352, 129.426532502207,
138.152991683502, 145.386147662587, 151.449901178826, 156.664661040244,
160.772078816155, 163.73378188459, 166.191604685078, 168.779485826355,
171.268657077064, 173.457816013976, 0.143311272149029, 0.535336059690023,
1.11964297934756, 1.84034240553517, 2.64204876403015, 3.46985629996194,
4.26932884859064, 4.98650890570362, 5.59281630436019, 6.17807228706407,
6.86540669788292, 7.77677724972402, 8.7879381167342, 9.88445454009374,
11.3499525597016, 13.4651998809093, 16.3614884444052, 19.8619271699692,
23.784215632545, 27.9477114462841, 32.1120372715342, 36.4340083501781,
41.3266604607067, 47.1986291492766, 54.0075277699988, 61.5732500928243,
70.0926741830142, 79.7602459054177, 91.5291472344021, 104.96982594475,
118.216844807352, 129.426532502207, 138.152991683502, 145.386147662587,
151.449901178826, 2.64204876403015, 3.46985629996194, 4.26932884859064,
4.98650890570362, 5.59281630436019, 6.17807228706407, 6.86540669788292,
7.77677724972402, 8.7879381167342, 9.88445454009374, 11.3499525597016,
13.4651998809093, 16.3614884444052, 19.8619271699692, 23.784215632545,
27.9477114462841, 32.1120372715342, 36.4340083501781, 41.3266604607067,
47.1986291492766, 54.0075277699988, 61.5732500928243, 70.0926741830142,
79.7602459054177, 91.5291472344021, 104.96982594475, 118.216844807352,
129.426532502207, 138.152991683502, 145.386147662587, 151.449901178826,
156.664661040244, 160.772078816155, 163.73378188459, 166.191604685078,
168.779485826355, 171.268657077064, 173.457816013976, 176.010066142443,
179.58032670379, 184.965358463072, 191.58976220567, 198.057181462813,
1.84034240553517, 2.64204876403015, 3.46985629996194, 4.26932884859064,
4.98650890570362, 5.59281630436019, 6.17807228706407, 6.86540669788292,
7.77677724972402, 8.7879381167342, 9.88445454009374, 11.3499525597016,
13.4651998809093, 16.3614884444052, 19.8619271699692, 23.784215632545,
27.9477114462841, 32.1120372715342, 36.4340083501781, 41.3266604607067,
47.1986291492766, 54.0075277699988, 61.5732500928243, 70.0926741830142,
79.7602459054177, 91.5291472344021, 104.96982594475, 118.216844807352,
129.426532502207, 138.152991683502, 145.386147662587, 151.449901178826,
156.664661040244, 160.772078816155, 163.73378188459, 166.191604685078,
168.779485826355, 171.268657077064, 173.457816013976, 176.010066142443,
179.58032670379, 184.965358463072, 191.58976220567, 198.057181462813,
16.3614884444052, 19.8619271699692, 23.784215632545, 27.9477114462841,
32.1120372715342, 36.4340083501781, 41.3266604607067, 47.1986291492766,
54.0075277699988, 61.5732500928243, 70.0926741830142, 79.7602459054177,
91.5291472344021, 104.96982594475, 118.216844807352, 129.426532502207,
138.152991683502, 145.386147662587, 151.449901178826, 42.9166306171476,
49.2039291561106, 62.6115066682204, 75.0368382288027, 91.8646903096498,
105.075979101919, 128.045626339862, 152.038583416529, 178.958284952656,
197.85798258033, 216.66160215415, 242.222438972561, 259.471808586035,
278.701871960409, 296.139045141423, 312.556653326664, 324.786579588327,
334.159209459496, 340.838221191965, 344.783944836434, 347.047072175492,
348.31117919574, 347.406124517167, 344.193009041774, 345.001344520243,
342.828271816297, 345.797039385667, 346.350034479965, 178.958284952656,
197.85798258033, 216.66160215415, 242.222438972561, 259.471808586035,
278.701871960409, 296.139045141423, 312.556653326664, 324.786579588327,
334.159209459496, 340.838221191965, 344.783944836434, 347.047072175492,
348.31117919574, 347.406124517167, 344.193009041774, 345.001344520243,
342.828271816297, 345.797039385667, 346.350034479965, 350.709958474795,
352.728232775983, 352.389392036996, 351.490171322274, 350.530952864306,
1.84859013581303, 2.64781529463769, 4.39894487375493, 6.77335746070776,
9.25007863615553, 11.4214757466562, 13.1776537216201, 14.8779543050014,
17.3588889189776, 21.2237793755833, 24.919392068093, 28.6378442715748,
33.0831690479629, 34.7412882787751, 42.9166306171476, 49.2039291561106,
62.6115066682204, 75.0368382288027, 91.8646903096498, 105.075979101919,
128.045626339862, 152.038583416529, 178.958284952656, 197.85798258033,
216.66160215415, 242.222438972561, 259.471808586035, 278.701871960409,
296.139045141423, 312.556653326664, 324.786579588327, 334.159209459496,
340.838221191965, 344.783944836434, 347.047072175492, 348.31117919574,
347.406124517167, 344.193009041774, 345.001344520243, 342.828271816297,
345.797039385667, 346.350034479965, 350.709958474795, 352.728232775983,
352.389392036996, 351.490171322274, 350.530952864306, 4.39894487375493,
6.77335746070776, 9.25007863615553, 11.4214757466562, 13.1776537216201,
14.8779543050014, 17.3588889189776, 21.2237793755833, 24.919392068093,
28.6378442715748, 33.0831690479629, 34.7412882787751, 42.9166306171476,
49.2039291561106, 62.6115066682204, 75.0368382288027, 91.8646903096498,
105.075979101919, 128.045626339862, 152.038583416529, 178.958284952656,
197.85798258033, 216.66160215415, 242.222438972561, 259.471808586035,
278.701871960409, 296.139045141423, 312.556653326664, 324.786579588327,
334.159209459496, 340.838221191965, 344.783944836434, 347.047072175492,
348.31117919574, 347.406124517167, 344.193009041774, 345.001344520243,
342.828271816297, 345.797039385667, 346.350034479965, 350.709958474795,
352.728232775983, 352.389392036996, 351.490171322274, 350.530952864306,
0.340223969236442, 1.07876494201182, 1.84859013581303, 2.64781529463769,
4.39894487375493, 6.77335746070776, 9.25007863615553, 11.4214757466562,
13.1776537216201, 14.8779543050014, 17.3588889189776, 21.2237793755833,
24.919392068093, 28.6378442715748, 33.0831690479629, 34.7412882787751,
42.9166306171476, 49.2039291561106, 62.6115066682204, 75.0368382288027,
91.8646903096498, 105.075979101919, 128.045626339862, 152.038583416529,
178.958284952656, 197.85798258033, 216.66160215415, 242.222438972561,
259.471808586035, 278.701871960409, 296.139045141423, 312.556653326664,
324.786579588327, 334.159209459496, 340.838221191965, 344.783944836434,
347.047072175492, 348.31117919574, 347.406124517167, 344.193009041774,
345.001344520243, 342.828271816297, 345.797039385667, 346.350034479965,
350.709958474795, 352.728232775983, 352.389392036996, 351.490171322274,
350.530952864306, 259.471808586035, 278.701871960409, 296.139045141423,
312.556653326664, 324.786579588327, 334.159209459496, 340.838221191965,
344.783944836434, 347.047072175492, 348.31117919574, 347.406124517167,
344.193009041774, 345.001344520243, 342.828271816297, 345.797039385667,
346.350034479965, 350.709958474795, 352.728232775983, 352.389392036996,
351.490171322274, 350.530952864306, 51.3565239991261, 56.3417951650529,
61.2581743869212, 66.256874264841, 71.4833136332544, 76.5924992094336,
81.6372170972625, 87.3517606104839, 94.4627662209588, 103.390007300147,
113.651627523692, 124.617838469325, 135.655702881477, 146.937641224732,
158.64404432133, 170.16293221615, 180.925104532923, 190.951632309745,
200.554340632463, 209.617127838497, 217.985947769138, 225.678227607646,
232.740532460136, 239.054054078126, 244.518235057184, 248.800119902856,
252.074722206554, 255.003156679698, 258.235704504914, 261.676730230602
), B = c(3690, 3690, 3690, 3690, 3690, 3690, 3690, 3690, 3690,
4672.77, 5087.28, 5535, 6126.63, 5833.89, 6027, 6150, 6273, 1856.2002037284,
6634.10731859754, 13147.6811001334, 20210.8813038618, 26637.6676853087,
31242, 36900, 86100, 184500, 239850, 259530, 273060, 286590,
298890, 319800, 344400, 369000, 393600, 430500, 467400, 516600,
553500, 590400, 627300, 659280, 710940, 735540, 773670, 836400,
931110, 1002450, 1063950, 1125450, 7144.5703125, 23715.9375,
42420.5859375, 55965, 59040, 62730, 67650, 73800, 76260, 79950,
82410, 88560, 76260, 79950, 227.777777777778, 1822.22222222222,
6150, 21871.86, 23268.3231234815, 24057.0270959851, 26383.5,
52053.6, 61440.3222222222, 63716.2777777778, 65067, 66629.1,
74538, 84870, 95940, 107010, 119187, 119187, 150060, 163221,
178350, 210945, 244647, 262482, 282408, 307746, 334560, 358668,
391140, 421890, 451410, 515616, 547350, 608850, 664200, 3690,
9840, 23370, 28290, 30750, 33210, 34440, 52890, 57810, 66420,
76260, 31980, 98400, 115620, 136530, 156210, 167280, 195570,
231240, 277980, 300120, 369000, 461250, 562110, 645750, 740460,
832710, 963090, 1034430, 1109460, 1200480, 1281660, 1313640,
1365300, 1450170, 1504290, 1515360, 1567020, 1635900, 1697400,
1730610, 1792110, 1851150, 456.560625, 2215.23, 6316.05, 18696,
31448.64, 35055, 35297.31, 38772.06, 42312, 47152.05, 56080.62,
68748.39, 85283.28, 104237.58, 133086, 185361, 232273.2, 257316,
230477.4, 275421.6, 305040, 435174, 511557, 596673, 645750, 732711,
821271, 896178, 1019178, 1100481, 1200726, 1299249, 1343160,
1372065, 1398387, 1471449, 1534548, 1582026, 1644510, 1727781,
1786821, 1827411, 1878579, 1944507, 530.4375, 2644.5, 7126.3125,
14760, 30012, 45264, 65067, 84870, 112176, 135300, 159900, 180564,
196800, 218940, 238620, 296184, 324720, 341940, 362850, 33210,
39360, 45099.6138825, 55121.2783881, 76260, 88560, 103320, 176270.07,
189534.39, 202798.71, 217127.595, 231456.48, 234592.98, 237729.48,
243829.05, 249928.62, 257396.565, 264864.51, 279955.38, 286590,
285515.47938, 307005.89178, 314681.039136, 323123.70108, 327652.038084,
340316.031123, 407550.321381, 413997.445101, 455.555555555555,
3644.44444444444, 12300, 36900, 54120, 76260, 114390, 161130,
199260, 269370, 328410, 382530, 420660, 450180, 484620, 517830,
546120, 559650, 569490, 578100, 590400, 603930, 616230, 622380,
630990, 2919.2, 10233.6, 19778.4, 29388.8, 36900, 40134.4444444444,
42275.5555555556, 49200, 67650, 79950, 92250, 104550, 113160,
134070, 150060, 162360, 200859, 221400, 230010, 250920, 279210,
300120, 322260, 334560, 355470, 377610, 397290, 412050, 431730,
448950, 476010, 530130, 538740, 543660, 549810, 552270, 521520,
527670, 528900, 525210, 523980, 522750, 521520, 520290, 523980,
523980, 525210, 8393.52, 29756.16, 58361.04, 88481.28, 114390,
135300, 157440, 207870, 254610, 300120, 356700, 354240, 437880,
521520, 698640, 876990, 1105770, 1273050, 1583010, 1872060, 2285340,
2571274.41, 2841669, 3204396, 3462450, 3756420, 3963060, 4098360,
4218900, 4259490, 4360350, 4412010, 4413240, 4412010, 4409550,
4387410, 4414470, 4414470, 4421850, 4441099.5, 4459980, 4485834.6,
4471050, 4424310, 4399710, 2914.84375, 10420.8333333333, 20660.15625,
31775, 41907.5520833334, 49200, 53283.18359375, 55484.53125,
56491.11328125, 56990, 57668.26171875, 59212.96875, 62311.19140625,
67650, 78239.53125, 89790, 95940, 102090, 109470, 114144, 145140,
174660, 220170, 257070, 282613.41, 308155.59, 333699, 366294,
375150, 378840, 384990, 413280, 426810, 439110, 442800, 461250,
492000, 479700, 485850, 489540, 505530, 468630, 467400, 471520.5,
473550, 500585.4, 504300, 504300, 504300, 1951.91604166667, 6884.17333333333,
13411.535625, 20148.7666666667, 25710.6302083333, 28711.89, 26445,
24600, 23370, 21622.17, 20295, 18361.44, 16605, 15585.33, 14145,
13260.63, 12054, 11439, 11070, 10701, 10332, 636.181197916667,
2343.83333333334, 4821.61921875, 7768.20166666667, 10882.2434895833,
13862.4075, 17177.565, 20492.7225, 24422.88, 30750, 31365, 31980,
33210, 40590, 41820, 43050, 44280, 46740, 50430, 53505, 57810,
61500, 65190, 68880, 75030, 71340, 68880, 67650, 66420, 65190
)), .Names = c("id", "year", "A", "B"), row.names = c(NA, 450L
), class = c("plm.dim", "data.frame"))
ここに私のコードがあります:
library(plm)
data <- plm.data(data, index = c("id", "year"))
z3 <- pgmm(log(A) ~
lag(log(A),1)
+ B
| lag(log(A), 2:99)
, data = data, effect = "twoways", model = "onestep", transformation = "ld")