1
$\begingroup$

I want to model a stock's volatility with a proxy variable. Consider a standard GARCH(1,1) model: $$ \sigma^2_t=a+b \sigma^2_{t-1}+c r^2_{t-1}. $$ Classically, $r_{t}$ is the return of the stock at time $t$.

Instead of return of stock, I want to use a proxy variable. Let define it as $p$. So the model becomes: $$ \sigma^2_t=a+b \sigma^2_{t-1} + c p^2_{t-1}. $$ Namely, another variable is used instead of squared returns.

I want to estimate the parameters $a$, $b$ and $c$ using rugarch package in R.

How can I do this? I guess, $p$ will be defined as external variable.

Data is as below:

data<-structure(c(0.00240428226573286, 0.00718664351112785, 0.00417663958775449, 
            -0.0124234291416307, 0.00615240249156912, 0.0096846888172486, 
            0.0106526433200909, -0.00786660798829253, -0.0122874870756498, 
            -0.000314141256930967, 0.000471174886371273, -0.0208884504520821, 
            -0.0149969692551366, 0.0241492647161508, 0.00419227605454964, 
            0.0178426729434715, 0.00339145325161994, 0.00518480259013288, 
            0.0144432753009873, -0.000454914348644309, -0.0129016560881787, 
            0.0104447845272464, 0.0167547608104748, -0.00405921117604713, 
            -0.0300729637845212, -0.00822872240789607, 0.00278348586175703, 
            -0.00943594943234238, -5.99101840794702e-05, 0.000996016229104058, 
            -0.000829404324086624, 0.0258218725118393, 0.00877055916031999, 
            -0.00588618984169464, 0.0254017935654574, 0.00805703215794296, 
            -0.0191565531978934, 0.0152034393746021, -0.00363509820161312, 
            0.0117471147043791, 0.00185834076893698, 0.0109010059113128, 
            0.000525595380350907, 0.00471136142307849, 0.00378484394178535, 
            0.00256537092911024, 0.0134933997293825, 0.00363203707933835, 
            0.00448837964129467, 0.00916296013641471, -0.0135706087748861, 
            0.00426982136304233, 0.0249833876507619, 0.019064654422376, 0.00552211291815752, 
            -0.0198178211588615, -0.0170519265736608, 0.0120525451282543, 
            -2.37224843004924e-05, -0.000146280600871407, 0.00477158577627002, 
            0.014383729883134, 0.00421564947003716, -0.0109717193626331, 
            0.0182095942293206, -0.0108949339087712, -0.0176664501445263, 
            -0.00426136213898864, 0.0163439380148436, 0.0178444666710593, 
            -0.00319282678270305, 0.0233384597132087, 0.00102961481001707, 
            -0.00247084887334204, 0.00896252965220334, -0.00107396173656049, 
            -0.00815784718500012, 0.00140858905036012, 0.00184093926106854, 
            -0.00841584807540308, 0.0075738167721191, -0.00446712175714303, 
            0.00121321378245653, -0.00175673411449218, -0.0177111606464013, 
            -0.0334792540725228, -0.021030442634931, -0.00865103680757429, 
            -0.00421196940949287, 0.00881717323241915, -0.00329042016708669, 
            0.00285661638368673, -0.0091984467251045, -0.00635158904182198, 
            -0.0104482543279794, 0.00359730221733479, -0.000431138620978544, 
            -0.0115382875664558, 0.00533047803197206, 0.0341741617915705, 
            -0.0104470816276567, -0.00732144270561363, -8.62463751900577e-05, 
            0.00646817036545677, -0.00936218069462136, -0.00992630520256377, 
            -0.00995174579671421, 0.0241883533000227, 0.00578491104143275, 
            -0.00555291698752569, 0.00859969423753348, -0.0143210399197393, 
            -0.0106656279629131, -0.00460249153100456, -0.010173846679443, 
            0.00628725502787653, -0.0207505962948851, 0.0101111964328382, 
            0.0273637272462803, 0.000106801184665883, -0.00340971899708542, 
            0.00930603680385644, -0.0342227015274759, -0.00272057238669277, 
            0.0232516656596928, -0.00282957942797246, 0.00137068445465083, 
            0.0146662205383272, 0.00557236352191204, -0.00470848819449188, 
            0.01545895026171, 0.0237779175036614, 0.0022179786175851, 0.0154723164160355, 
            0.00284859279265781, -0.0734795439085705, -0.0101844065754371, 
            -0.0168785371789415, -0.0451668472504849, 0.00200162750463484, 
            0.0333872319914033, -0.00655444963038754, 0.0186375681927853, 
            0.00224002580098137, 0.00214365086334034, 0.01717336389666, -0.0119039720455039, 
            -0.0166511258509399, 0.0208862527198921, -0.000787824156615713, 
            0.0222754484996237, 0.00954288703328032, -0.00727556935841456, 
            0.0137326236782958, -0.0102379006489173, 0.00311433870608724, 
            -0.0098021206176373, 0.00565514504945241, -0.00226609648997211, 
            0.00223756041797607, -0.00246408074099946, -0.0079808840138309, 
            -0.0158660954154453, 0.00881042570067692, 0.00428512104701007, 
            -0.0130623086945807, -0.00198847471210328, -0.00151270842662043, 
            0.0135073344736334, 0.0117315016530082, 0.00260857338333409, 
            -0.00451831385594481, 0.00257655670181478, -0.0101997675299845, 
            -0.0135002265633961, 0.0214784602834559, -0.00461067140901328, 
            0.00776184432271698, 0.0238427144319235, -0.000495135212737807, 
            -0.0387403757953813, 0.00565275629502793, 0.00667937353452963, 
            -0.00776691741432067, -0.00766349350523576, 0.00958945509957054, 
            -0.00217288868014798, 0.0102753819264656, 0.000527389159218572, 
            0.00104278741483199, -0.00180603147915903, -0.0024659310273023, 
            -0.00235092677265314, -0.00843919357593137, 0.00963829977017916, 
            -0.00150498322541637, 0.0115911140449825, 0.0110373532490922, 
            0.000537162615545483, -0.00517091804718639, 0.013716249701627, 
            -0.00626535235492476, -0.00044537835702485, -0.00833167889318887, 
            -0.00517343387401326, 0.00259197243534537, -0.0142035782174386, 
            -0.00332432066398702, -0.00637259964301151, -0.0319897877349788, 
            0.0188708261874773, 0.00902118748854797, -0.00208183811690787, 
            0.00198454105666279, -0.0156560254475639, -0.0100950585869821, 
            0.00978093861225737, -0.00522315899479864, 0.00503232384557784, 
            0.00666876157161944, -0.00126191845920864, 0.00354688366125622, 
            -0.0102764670148119, -0.0113092429587738, 0.00229380810354662, 
            0.00839328069543654, -0.0105198364905359, -0.002837775658179, 
            -0.0201399087459038, 0.0119401772698691, 0.00284045488011309, 
            0.0246084027100704, 0.00788890594633074, -0.00133535072794366, 
            -0.00266444216114259, 0.00674294083180094, 0.00986258515676042, 
            -0.00148717060305792, 0.0103228516356264, -0.00114563042290783, 
            -0.00558149616106718, 0.00839029408001757, -0.00242454214368415, 
            -0.00277027874972191, -0.00560435091364653, 0.000731425659337148, 
            -0.00428107774040676, 0.0109993438147029, 0.0037087621145826, 
            0.00388281880721841, -0.00492902801425465, -0.0147212663223222, 
            -0.0062137466061678, 0.00318246089141461, 0.00938513022545173, 
            0.00372645244357095, -9.69066555711606e-06, 0.0035197962925686, 
            0.0406780148963204, 0.0077983167274418, 0.00229569544477393, 
            0.00793643833981328, 0.00504391169459417, -0.00580243023076754, 
            0.00927432095852687, -0.000232971205631927, 0.0138722766791695, 
            -0.0129039060692566, 0.00836494753892758, 1.01399352825382e-05, 
            0.0283457779811229, 0.00067442071407342, 0.00637900121597035, 
            0.00626980084182271, 0.0113243798290323, -0.0117401689487977, 
            0.00135979977779499, 0.00879045569253378, 0.00656352401512272, 
            -0.0153928479424028, 0.0125530726116168, -0.00561643658804734, 
            -0.00227591872884325, 0.0034633081250135, 0.00727107400641813, 
            -0.00273647607013316, 0.00425203735149005, -0.00488867171599416, 
            0.00683394561459849, -0.00992043957091049, -0.00560198247430499, 
            -0.00327635391489345, 0.0208371203446358, 0.00684650777054152, 
            -0.00235817540968775, 0.0146372216938975, -0.00254461570527909, 
            -0.0147392682797047, -0.00540476259961409, 0.00681741066701314, 
            -0.00202936679798782, -0.00328393800144688, 0.0034608210234186, 
            0.00915650804831181, 0.0024681397557007, 0.00452850517684666, 
            -0.00325770029997052, -0.00883931780571601, -0.000500965633410289, 
            0.00686775854728872, -0.00763740444788219, 0.00541127306787104, 
            -0.0101645080291242, 0.000140351294030339, -0.00375751614814845, 
            -0.00312954762505058, -0.000642140719694595, 0.0047835723077192, 
            -0.00403350849344264, -0.00205117718248182, 0.0305259473841222, 
            -0.00368893454833596, 0.000524259091893242, -0.0119619058683504, 
            0.00214533859236532, 0.00653076907380878, 0.00791071061486903, 
            -0.0062537972532688, 0.0135117597884715, 0.00416939885856848, 
            0.0148088851181498, 0.00883162254853787, -0.00119022679055902, 
            -0.00254082633103003, 0.00394659516152096, -0.003168068545504, 
            -0.00524040660809355, -0.00882022385438397, 0.00951940493577297, 
            -0.00101927410289804, 0.015761701773787, 0.00909395368709731, 
            -0.0112922617960063, -0.00123833318798283, 0.00620620396185423, 
            0.00598439589524169, -0.00455009463326661, -0.00605233754141565, 
            0.0130798753275556, 0.0135739452716361, 0.00608364063475264, 
            -0.00613010218358134, -0.00184034344641404, 0.00197347969190886, 
            -0.00387874641259245, 0.00199036225790472, -0.00180383171416842, 
            0.0153096987521142, -0.00686017554850871, 0.0014203900944505, 
            -0.00729808882639027, 0.00369152733962785, 0.00980434412762321, 
            0.00503305294462741, -0.00143341801999597, 0.00338400714536036, 
            -0.00906640410340387, -0.00552950392268947, 0.0115387367679265, 
            -0.000633026777244083, 0.00121665545139571, 0.00683871348798348, 
            -0.00434128430549308, 0.00977794561054779, -0.00425650993954818, 
            0.00249283999941774, 0.000815176235308357, 0.00679613674310175, 
            -0.00458861771460839, -0.001166401766314, -0.00540718042119614, 
            0.0100685043595448, 0.0204185872102673, 0.00605956410345243, 
            0.00385001917730676, 0.00922236514154662, 0.00985160106128902, 
            -0.00470606734079837, 0.01594519327646, -0.00636892362420838, 
            0.00100412807768002, -0.00123875407891383, 0.00308910806569429, 
            0.00154485396972071, 0.0109979003939937, -0.00640462572168055, 
            -0.0015637144202536, -0.0129542930903757, 0.0035548530292111, 
            0.00588116908225444, 0.0129026905494971, 0.0113209668876699, 
            -0.00129441124807883, -0.00846832936736064, -0.00844436119602499, 
            -0.00779763940020217, 0.023781763109044, -0.0242478267815525, 
            -0.000479662645538781, -0.000343118163115719, 0.00352384560039809, 
            0.0130894063298506, -0.000188021398532356, 0.00329381722090716, 
            0.0018447861748303, 0.0054929799543082, 0.00531453264371429, 
            0.000753024431418226, -0.00374371676477558, -0.0103937514181691, 
            0.0067629682572683, 0.0011958712688962, -0.0118359004134643, 
            0.00923609281688798, -0.00300438045761275, -0.00896634115784245, 
            0.000819686759950145, -0.00465327468340249, -0.0112668808388143, 
            -0.0152929145318392, 0.00386127972024042, -0.0126357426677117, 
            0.0011690144781813, -0.0179534149314371, 0.0160931118496812, 
            -0.0264315783876601, 0.0140562888877458, 0.00249690206283404, 
            0.000251696829239227, 0.00017522322072055, 0.000275363243167333, 
            0.000211105950690771, 0.000163839416020752, 0.000177902992174424, 
            6.59515569106677e-05, 0.000125476365474465, 0.000191536406751375, 
            3.25491953708898e-05, 7.69018038123833e-05, 0.000103732359318023, 
            0.000181203607121594, 9.567355632008e-05, 6.73704964044718e-05, 
            0.000262907836701601, 5.70646094548377e-05, 2.80184857933882e-05, 
            1.22050603124915e-05, 3.50465534454949e-05, 0.000132914077967553, 
            0.000177325167760662, 3.94445454935299e-05, 3.51131637087737e-05, 
            0.000471469128859536, 0.000144905501568129, 0.000136805944798802, 
            0.00014022907235976, 2.96864607926418e-05, 0.000329364618989424, 
            7.21229903662821e-05, 0.000339778319808316, 8.58031840053938e-05, 
            4.15770668836548e-05, 0.000115357565229386, 9.93179828939986e-05, 
            0.000206372940133756, 8.54154066453355e-05, 8.85452125772954e-05, 
            0.000149552602097445, 1.84189605691082e-05, 2.84284442258795e-05, 
            6.8520326605446e-05, 6.47293456606985e-05, 4.22289490031618e-05, 
            5.81466605094683e-05, 0.000106241118904363, 7.88018013506138e-05, 
            4.35120989998532e-05, 4.96716670653076e-05, 9.90941099809679e-05, 
            7.70396038803412e-05, 5.43616391654606e-05, 0.000158796018397317, 
            6.18992611437467e-05, 0.000187970881036946, 0.000134517428810996, 
            8.90045601947622e-05, 1.16607647227688e-05, 4.01664497528001e-05, 
            3.02826019527932e-05, 2.90468659792095e-05, 4.82900445848854e-05, 
            6.68076269632769e-05, 8.43702053437563e-05, 7.98257028283379e-05, 
            0.000122283923761186, 7.42674973783328e-05, 0.000154605029057066, 
            0.000168824990589982, 6.9767942080428e-05, 0.000162042970218633, 
            4.09403798935569e-05, 9.39788930749552e-05, 9.47721402729103e-05, 
            3.81254494638359e-05, 0.000134039295865642, 8.70010694063299e-05, 
            2.98882439265544e-05, 3.71624574372021e-05, 3.95719993032863e-05, 
            3.37886471651818e-05, 4.14174551011361e-05, 3.38931579571461e-05, 
            0.000107124213529608, 0.000613339396392203, 0.000218423481823372, 
            0.000332089337487209, 0.000150223120256456, 4.22226580635917e-05, 
            6.53852698628739e-05, 7.63504882597116e-05, 0.000101511288238334, 
            6.04889670561399e-05, 0.000135306909708342, 0.00010502445390268, 
            7.29813762018909e-05, 8.62596951298854e-05, 3.56768162059361e-05, 
            0.000550322998864941, 0.000104248623283486, 5.80545390044564e-05, 
            2.95757577033753e-05, 4.97201531315361e-05, 9.93636604470571e-05, 
            6.25207633380187e-05, 8.96769611037735e-05, 0.000239763626815782, 
            2.26154963531147e-05, 0.000113455569292049, 0.00010563989234135, 
            9.90417495742469e-05, 7.51785085665525e-05, 8.55815277260885e-05, 
            9.89695913602566e-05, 1.73847952242902e-05, 0.000127496737328366, 
            4.8918167639677e-05, 7.75073629546763e-05, 3.29754440787082e-05, 
            4.43662474332819e-05, 7.74413334957894e-05, 0.000147476111024546, 
            6.6791628560791e-05, 9.45609736158338e-05, 6.49057079913758e-05, 
            4.61885494925713e-05, 3.59631003246465e-05, 8.86167153380899e-06, 
            2.88228847294921e-05, 2.55469982842352e-05, 0.000200657200822739, 
            2.84560512922749e-05, 6.56165031993773e-05, 1.85095319693852e-05, 
            0.00190294782480662, 0.000375818744883927, 0.000301209827296353, 
            0.000480455271126961, 0.000397014708229449, 0.00025918313912419, 
            0.000173402100110612, 0.000113078806300364, 6.86429503060352e-05, 
            8.34387051768533e-05, 2.3670217640922e-05, 6.83066035346156e-05, 
            0.000180343224730863, 0.000223243234350127, 0.000166912276937141, 
            5.46484176131866e-05, 7.30516495659959e-05, 8.5218200541149e-05, 
            9.96516821371827e-05, 0.000103914634813067, 3.70030379934397e-05, 
            9.55510865907992e-05, 5.87885738004437e-05, 8.75067771417903e-05, 
            5.27720915053515e-05, 2.6419651275901e-05, 5.48094221227643e-05, 
            8.72405727827472e-05, 1.96560308229845e-05, 6.93817274648136e-05, 
            4.70674767653476e-05, 2.5907373486309e-05, 2.52971349586753e-05, 
            6.19496496600335e-05, 1.91894648039667e-05, 1.44011567821633e-05, 
            3.96944891245991e-05, 3.32237130167791e-05, 3.23655961168222e-05, 
            9.52041049972125e-05, 9.22140585500244e-05, 2.95601579995698e-05, 
            5.7298413655549e-05, 7.14545975181224e-05, 1.85021501488288e-05, 
            3.97889051134439e-05, 4.19969285326145e-05, 2.37757860999814e-05, 
            6.83550884886579e-05, 2.22313172550589e-05, 1.64109373863327e-05, 
            2.50069940816964e-05, 0.000133533632946732, 3.43344514436906e-05, 
            4.01942754137392e-05, 4.00875516703114e-05, 2.22432547040901e-05, 
            5.43845806877527e-05, 5.9418870478874e-05, 5.12875402735082e-05, 
            2.82467177617649e-05, 2.62091838093053e-05, 3.12080373188776e-05, 
            1.32047314044513e-05, 2.2453979579877e-05, 4.21337587707333e-05, 
            4.90212688538938e-05, 2.36981055735853e-05, 4.18197039400705e-05, 
            2.59711545037003e-05, 2.58342154246319e-05, 0.000147459370616682, 
            1.25317721108411e-05, 5.38933522750419e-05, 0.000196547057533799, 
            3.08240167594024e-05, 9.34139867094966e-05, 0.000194508541245898, 
            3.42414294074545e-05, 9.86528548649803e-05, 9.22178957487724e-05, 
            2.97663215467467e-05, 6.57718575849746e-05, 4.40737567982907e-05, 
            0.000105995440557507, 3.49751323240696e-05, 4.02114808912311e-05, 
            9.04095828425618e-05, 0.000199329360038168, 4.68432763072529e-05, 
            1.15898377680142e-05, 5.50531357702367e-05, 5.68853037889909e-05, 
            0.000208053135521747, 0.00020974116304657, 8.89272761075408e-05, 
            0.000136745788067257, 5.44581078541029e-05, 0.000113038126533384, 
            2.19813425832949e-05, 0.000111834450124839, 3.42978025654599e-05, 
            2.58992898017638e-05, 0.000123249431791024, 1.37017959331783e-05, 
            3.64182142079759e-05, 5.91927644927271e-05, 2.47363529761202e-05, 
            2.27547569361703e-05, 2.84558648810933e-05, 3.16997977682179e-06, 
            2.76175884125892e-05, 6.50968985734015e-05, 1.46697270313268e-05, 
            2.17641327381935e-05, 9.4933834637042e-06, 0.000107412534660489, 
            8.68052627803114e-05, 8.23442206285077e-05, 6.20309617700574e-05, 
            6.04407769982201e-05, 2.10410679101835e-05, 8.08957282902381e-05, 
            0.000581160293408342, 9.05216168882922e-05, 3.58498956154576e-05, 
            4.17979603816406e-05, 3.1888590680442e-05, 8.77226569442234e-05, 
            8.45051670313448e-05, 2.37705176179761e-05, 9.86391939149065e-05, 
            0.000111196053362138, 6.29384742590553e-05, 3.02581535758277e-05, 
            0.000345453433421844, 3.03586521519416e-05, 4.07730753344357e-05, 
            3.47026851439381e-05, 8.4428046020042e-05, 0.000222860337624946, 
            6.76557092786444e-05, 5.35171009261701e-05, 6.19228760921732e-05, 
            0.000194516476990722, 7.66618266042191e-05, 8.65312966088938e-05, 
            3.0754647695138e-05, 1.00788916857499e-05, 3.96856810899448e-05, 
            5.66122672529014e-05, 1.44202225767032e-05, 0.000122692445082544, 
            1.29905560674662e-05, 8.37799134847452e-05, 3.28651845529763e-05, 
            2.77344616080471e-05, 0.000133922438916515, 1.7548881551105e-05, 
            1.18841639375643e-05, 8.25134052825601e-05, 2.79252505882886e-05, 
            0.000149024714447796, 3.24693629084838e-05, 1.61948134168028e-05, 
            2.56757750198079e-05, 1.20022023145613e-05, 1.84331575331312e-05, 
            2.10329757885255e-05, 2.42187422599094e-05, 2.61033662863108e-05, 
            4.8683833737119e-05, 3.66736451965113e-05, 1.56569123184106e-05, 
            2.34140210939387e-05, 3.41944261637873e-05, 1.07669609833721e-05, 
            2.13159712542394e-05, 1.30652721592893e-05, 2.13248053164098e-05, 
            1.10989202936212e-05, 2.6334478933188e-05, 3.78561671279791e-05, 
            6.21969123364183e-06, 1.10119718300075e-05, 0.000303645486323138, 
            4.28617244240951e-05, 1.51135158814735e-05, 0.000105661522380075, 
            6.61841886292213e-05, 3.88521798109723e-05, 0.000108986943624248, 
            9.18023690068784e-05, 4.02916917750316e-05, 1.42812637717812e-05, 
            4.41487571637231e-05, 8.56025851377888e-05, 2.29176278548008e-05, 
            3.93726254330663e-05, 4.19972308951646e-05, 4.39408528363837e-05, 
            4.1480989312815e-05, 4.74928921013171e-05, 4.05891036460579e-05, 
            2.69528546909246e-05, 0.000113188710293188, 5.92874877910705e-05, 
            8.56545230702197e-05, 4.45389287385462e-05, 1.49224819308372e-05, 
            1.60844261431746e-05, 5.94261122246516e-05, 6.39321140846586e-05, 
            1.46646995926698e-05, 0.000102351777804229, 4.47366330784193e-05, 
            2.58807836130737e-05, 2.48883728985456e-05, 1.95443494029704e-05, 
            2.49419725044458e-05, 3.99730949590299e-05, 3.4334052855792e-05, 
            2.84969317437886e-05, 7.47011896110564e-05, 2.4958172467419e-05, 
            6.49490795459021e-05, 9.35876918743102e-06, 2.81441262165721e-05, 
            2.38018179081759e-05, 4.51645065052744e-05, 2.48153653068517e-05, 
            2.19133086248705e-05, 4.4331096434246e-05, 1.30708245176768e-05, 
            2.39958000762706e-05, 3.16210537922156e-05, 1.29897973950419e-05, 
            1.59501644154367e-05, 5.18424475433767e-05, 3.43933059234282e-05, 
            3.25316512235633e-05, 9.59276586584779e-06, 2.25044879921891e-05, 
            1.59048446587355e-05, 3.63040758361367e-05, 2.03327388129577e-05, 
            1.24317053781249e-05, 0.00022161287860766, 5.08065855722322e-05, 
            4.32004933767084e-05, 2.62095052621456e-05, 4.67218904970417e-05, 
            1.39483373696752e-05, 6.36885378756304e-05, 3.94711729731203e-05, 
            4.09316792298712e-05, 2.74252209954707e-05, 9.92229707550133e-06, 
            1.05318446840864e-05, 1.96029967402156e-05, 1.61167531099498e-05, 
            1.96553989691529e-05, 0.000114402900593077, 2.37332447126461e-05, 
            7.92572629418175e-06, 5.73721222022227e-05, 2.13554641110311e-05, 
            2.35349151201844e-05, 2.04451809559905e-05, 7.97304987239316e-05, 
            6.72201382801117e-05, 8.82487855431822e-05, 0.000337149060503328, 
            0.000283763875534853, 5.02492000483912e-05, 5.75935159270043e-05, 
            0.000133885480633097, 2.5902811707761e-05, 1.10307554157718e-05, 
            3.67190448310762e-05, 4.09980404152374e-05, 1.06602623727468e-05, 
            2.85704164595956e-05, 9.4298667580655e-06, 8.71484758815029e-05, 
            4.61528767616413e-05, 2.68856813898253e-05, 0.000107174505446985, 
            2.48112499399045e-05, 3.29821771639092e-05, 5.51938302016303e-05, 
            5.57698705374946e-05, 1.93908748677266e-05, 7.42236205690357e-05, 
            0.000144181296449081, 3.35710254658763e-05, 8.32441455033252e-05, 
            5.64578087018336e-05, 0.000126656066727925, 0.00010096108009589, 
            0.000271854655428855, 0.000131901108358219, 3.96100591203911e-05
), .Dim = c(438L, 2L), .Dimnames = list(NULL, c("return", "proxy"
)))

where proxy is in squared form $p^2_{t}$ and the data is in increasing time order.

My code is as below:

library(rugarch)
data<-as.data.frame(data)

modelp<-ugarchspec(variance.model=list(model="sGARCH",
                                                   garchOrder = c(0, 1),
                                                   external.regressors =matrix(data$proxy)),
                               mean.model=list(armaOrder=c(0,0), include.mean=FALSE),
                               distribution.model = "norm")

fitp<-ugarchfit(data=data$return,modelp)

However, the estimated volatility seems strange:

> head(sigma(fitp),20)
                          [,1]
1970-01-02 02:00:00 0.01157120
1970-01-03 02:00:00 0.01156687
1970-01-04 02:00:00 0.01156255
1970-01-05 02:00:00 0.01155823
1970-01-06 02:00:00 0.01155391
1970-01-07 02:00:00 0.01154959
1970-01-08 02:00:00 0.01154527
1970-01-09 02:00:00 0.01154095
1970-01-10 02:00:00 0.01153664
1970-01-11 02:00:00 0.01153233
1970-01-12 02:00:00 0.01152801
1970-01-13 02:00:00 0.01152370
1970-01-14 02:00:00 0.01151940
1970-01-15 02:00:00 0.01151509
1970-01-16 02:00:00 0.01151078
1970-01-17 02:00:00 0.01150648
1970-01-18 02:00:00 0.01150218
1970-01-19 02:00:00 0.01149788
1970-01-20 02:00:00 0.01149358
1970-01-21 02:00:00 0.01148928

I just pasted first 20 fits. The estimates are linearly decreasing.

The estimated coefficients are as below:

> fitp

*---------------------------------*
*          GARCH Model Fit        *
*---------------------------------*

Conditional Variance Dynamics   
-----------------------------------
GARCH Model : sGARCH(0,1)
Mean Model  : ARFIMA(0,0,0)
Distribution    : norm 

Optimal Parameters
------------------------------------
        Estimate  Std. Error    t value Pr(>|t|)
omega    0.00000       1e-06 0.0000e+00  1.00000
beta1    0.99925       2e-06 4.1511e+05  0.00000
vxreg1   0.00000       6e-06 1.6560e-03  0.99868

Robust Standard Errors:
        Estimate  Std. Error   t value Pr(>|t|)
omega    0.00000       8e-06 0.000e+00  1.00000
beta1    0.99925       4e-06 2.583e+05  0.00000
vxreg1   0.00000       6e-06 1.686e-03  0.99865

Where am I doing wrong? I will be very glad for any help. Thanks a lot.

I did the same analysis using Eviews. The resutls are as below:

Dependent Variable: RETURN                                                                                              
Method: ML ARCH - Normal distribution (BFGS / Marquardt steps)                                                                                              
Date: 11/01/17   Time: 20:04                                                                                                
Sample: 1 438                                                                                               
Included observations: 438                                                                                              
Convergence achieved after 19 iterations                                                                                                
Coefficient covariance computed using outer product of gradients                                                                                                
Presample variance: backcast (parameter = 0.7)                                                                                              
GARCH = C(1) + C(2)*GARCH(-1) + C(3)*PROXY                                                                                              

Variable    Coefficient    Std. Error   z-Statistic Prob.                                                                               

C          1.60E-05         7.38E-06    2.161932    0.0306                                                                              
GARCH(-1)  -0.082888        0.032435    -2.555532   0.0106                                                                              
PROXY      1.409768         0.188990    7.459494    0.0000                                                                              

R-squared   -0.005593       Mean dependent var      0.000863                                                                                
Adjusted R-squared  -0.003297       S.D. dependent var      0.011552                                                                                
S.E. of regression  0.011571        Akaike info criterion   -6.525471                                                                               
Sum squared resid   0.058645        Schwarz criterion       -6.497511                                                                               
Log likelihood  1432.078            Hannan-Quinn criter.    -6.514439                                                                               
Durbin-Watson stat  1.965053                                                                                            

These results are close to my expectation.

Able to find the problem in this subject, I opened the below topic:

GARCH estimates differ in rugarch (R) vs. EViews

In that topic, @BayerSe mentioned that the backcasting parameter in EViews is 0.7 as default. However, rugarch uses 1 as backcasting parameter. I thank @BayerSe, his analysis was very clear.

In EViews, it is possible to determine the backcasting parameter. Then I set it as 1, which is as same as rugarch. Because of the char. limit of I can't paste the results, but the values didn't change much.

$\endgroup$
  • $\begingroup$ You may see my answer to this question for a clue for what can happen in a GARCH(0,1) model and why the model does not make sense. However, this is for the case without the external variable. I will try to think about you particular case, too, and perhaps come up with an answer later on. By the way, it does not look from your code as if you had omitted the intercept in the conditional variance equation. $\endgroup$ – Richard Hardy Oct 29 '17 at 8:31
  • $\begingroup$ @RichardHardy, I edited my question after your comment. I added the intercept term to the model. Thanks a lot. $\endgroup$ – oercim Oct 29 '17 at 8:41
  • $\begingroup$ Could you include the results/printout of the fitted GARCH model? I.e. the table with the estimated coefficients (you can leave out the diagnostic tests that are printed after the coefficient table by default). $\endgroup$ – Richard Hardy Oct 29 '17 at 9:08
  • $\begingroup$ @RichardHardy, I added the coefficient estimates. beta1 is almost 1. Is that the problem? $\endgroup$ – oercim Oct 29 '17 at 9:15
  • $\begingroup$ Check out my edit to see how to use MathJax for better-looking formulas. $\endgroup$ – Richard Hardy Oct 29 '17 at 10:15
1
$\begingroup$

Your estimated conditional variance equation is approximately $\sigma^2_t=\sigma^2_{t-1}$, i.e. the conditional variance is a constant. The estimate of beta1 is forced into the stationary region during fitting because of your model specification, but in reality it could be exactly equal to one. You say you observe a linearly decreasing fitted conditional variance, but look at the scale and notice that the slope is very close to 1. The estimated equation shows the external variable has essentially no influence on the conditional variance because the fitted coefficient value is approximately zero. This is the situation depicted in the top-row middle-column graph in Richard Hardy's answer in this thread.

Whether this is what the data wants to tell you or is caused by an error in fitting is not clear to me. It might be that the ugarchspec and ugarchfit functions are not designed to work with models of the kind GARCH(0,$p$) which do not make sense as argued in the answer by Richard Hardy. They could make sense with external regressors, but perhaps this has been overlooked when designing the function ugarchfit that does the fitting. (This is just a guess, I have not looked at the likelihoods that are being maximized and how that is done. It is a bit too technical for me as the fitting is not coded in native R.)

$\endgroup$
  • $\begingroup$ Thanks a lot for the comments. I will try more on that problem. If I get some meaningful results, I will edit the problem. Thanks a lot again. $\endgroup$ – oercim Oct 29 '17 at 10:57
  • $\begingroup$ @oercim, Great. Remember that if your questions changes, you should post it anew. I have already invested my effort in answering the original one, and if you change the question, the answer might become redundant. $\endgroup$ – Richard Hardy Oct 29 '17 at 11:49
  • $\begingroup$ @oercim, how is the progress? Has this answer addressed your original question appropriately, or should I elaborate on anything? $\endgroup$ – Richard Hardy Nov 1 '17 at 8:30
  • $\begingroup$ I edited the subject. Because the character limit, I couldn't paste all results. But briefly, the situation is that: Eviews can make the desired analysis. However, I have to the analysis with rugarch. I posted the results to the author of the rugarch, and wanted help from him. I am waiting for his thoughts.When he returns, I will edit the subject. $\endgroup$ – oercim Nov 1 '17 at 17:32
  • $\begingroup$ @oercim, as I noted before, please post new questions as such. Otherwise the answers you get to the original question become redundant, which makes little sense. Also, after the edit I cannot really understand what your question is. I do not wish to pick on you, but it is better to be consistent and not blur the otherwise clear threads with incremental edits driving the questions into new directions. $\endgroup$ – Richard Hardy Nov 1 '17 at 18:43

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.