Hello

I am trying to get the eigen values and eigen vectors for conducting a PCA
on a covariance matrix which is given below. The results using the fnction
eigen sorts the eigen values and the vectors but I am unable to get the
column names along with it to know which factors explain the variances. Is
there a workaround or can anyone suggest a better package to do a PCA
analysis please? I am using this calculation for the HJM multi-factor model
to evolve forward rates using MC.

Many thanks and regards,
Raghu

dput(head(cov_mat))
structure(c(0.00156661649897028, 0.000376278095970815,
9.40043087417394e-05,
-3.91027833717052e-05, -3.02415415157699e-05, 2.53673930178148e-06,
0.000376278095970815, 0.00252998679753209, 0.00219567143517418,
0.00162065505089017, 0.00140024287670499, 0.00129810023491101,
9.40043087417394e-05, 0.00219567143517418, 0.00323193485803561,
0.00303051245292539, 0.00271150403934452, 0.00244156772923837,
-3.91027833717052e-05, 0.00162065505089017, 0.00303051245292539,
0.00319035442164058, 0.00297227890618637, 0.00272054252604778,
-3.02415415157699e-05, 0.00140024287670499, 0.00271150403934452,
0.00297227890618637, 0.00285306663126923, 0.00267658613210822,
2.53673930178148e-06, 0.00129810023491101, 0.00244156772923837,
0.00272054252604778, 0.00267658613210822, 0.0025732300320598,
3.32252737517998e-05, 0.00123509797957427, 0.00222574247233499,
0.00249827230070074, 0.0025102807360757, 0.00246797960641437,
5.61175776711312e-05, 0.00118382159885196, 0.00205104601738719,
0.00231161391025904, 0.00236553463637043, 0.00237219253014056,
7.17085790545051e-05, 0.00113558643988618, 0.00190652249243184,
0.00215536799033688, 0.00224085504837511, 0.00228620723286037,
8.11858022344755e-05, 0.00108741930726838, 0.00178467961516427,
0.0020238004356631, 0.00213290821034821, 0.00220835145972229,
8.58712633649974e-05, 0.00103873636227322, 0.00168044480389128,
0.00191203636784855, 0.00203841281111128, 0.0021366754615538,
8.70135450199272e-05, 0.000989955856817881, 0.00159023358581995,
0.00181607023812491, 0.00195448351043384, 0.00206936304350197,
8.56293339517203e-05, 0.000941676440116373, 0.00151133378161738,
0.00173264265070308, 0.00187868905337203, 0.00200484187113522,
8.24657452320842e-05, 0.00089424645116875, 0.00144146545935055,
0.00165901509556884, 0.00180893418157771, 0.00194171553430833,
7.82187616706446e-05, 0.000847969089662112, 0.00137861620514592,
0.0015927086645567, 0.00174330622133994, 0.00187873619985424,
7.34206595186322e-05, 0.00080293837640735, 0.00132103552265291,
0.00153161795383094, 0.00168020782000464, 0.00181492664838158,
6.84458323452263e-05, 0.000759130443718538, 0.00126727655510664,
0.00147405023414918, 0.00161842211931399, 0.00174966201061164,
6.35552373039637e-05, 0.00071642127294558, 0.00121611226527116,
0.0014186353712923, 0.00155705000639884, 0.00168262883186158,
5.88895233503303e-05, 0.000674638263729646, 0.00116656277681366,
0.00136436346465292, 0.00149555000083095, 0.00161385513297127,
5.452393582746e-05, 0.000633679348795005, 0.0011179572154345,
0.00131061759146919, 0.00143375786166422, 0.00154371754018389,
5.0482878387847e-05, 0.000593562667085323, 0.00106995660322272,
0.00125718245307614, 0.00137188256802279, 0.00147292133431514,
4.67737284101063e-05, 0.000554459365905882, 0.00102256401778711,
0.00120423336357391, 0.00131047986631302, 0.00140245804172554,
4.33750050332035e-05, 0.000516746299711986, 0.000976104624751568,
0.00115225448031408, 0.00125034269159519, 0.00133347653126852,
4.02406330307271e-05, 0.000480831945515331, 0.000931025690204452,
0.00110185080826596, 0.0011923253811288, 0.00126711446696206,
3.73134782322025e-05, 0.000447252821594548, 0.00088797786541555,
0.0010537716362484, 0.00113733817223681, 0.0012044772629689,
3.45090835922121e-05, 0.000416508582680918, 0.000847638307575302,
0.00100877450371524, 0.00108623891380097, 0.00114655161665639,
3.1805597598824e-05, 0.000389069114126897, 0.000810659389877811,
0.000967555430178078, 0.00103976938510116, 0.00109414818250693,
2.91861955231531e-05, 0.000365277978308324, 0.000777574305615641,
0.000930685945861819, 0.000998504977307534, 0.00104785624518023,
2.66353424006667e-05, 0.000345324625562382, 0.000748779956684214,
0.000898591659537003, 0.00096284056520079, 0.00100804477024725,
2.41602396976385e-05, 0.000329277032695183, 0.000724524676629233,
0.000871528972835027, 0.000932981588719668, 0.000974873080238128,
2.18159859521188e-05, 0.000317111243190218, 0.000704910024903443,
0.000849589330264498, 0.000908958567284253, 0.000948314945309718,
1.96785834841913e-05, 0.000308721378186575, 0.000689900956170003,
0.000832705672736791, 0.000890635687265649, 0.000928171286213506,
1.77973158529443e-05, 0.000303904147883212, 0.00067934529089213,
0.000820693051014077, 0.000877755502214002, 0.000914114826927761,
1.61997427192629e-05, 0.000302404780512352, 0.000673045826533214,
0.000813324516418908, 0.000870012619331225, 0.000905759761147136,
1.49094199069652e-05, 0.000303931081792975, 0.00067076258253308,
0.00081034159994045, 0.00086707436778119, 0.00090269213060411,
1.39360738988925e-05, 0.000308194917905174, 0.000672238852102111,
0.000811472366573508, 0.000868604266111317, 0.000904501545499573,
1.32829313862331e-05, 0.000314884255871188, 0.000677167366993932,
0.000816394224288532, 0.000874225852064107, 0.000910749023237429,
1.29556915642478e-05, 0.000323704385118746, 0.000685247231330798,
0.000824790172795173, 0.000883576775236633, 0.000921020965353272,
1.29742801121639e-05, 0.000334391836372029, 0.000696178607438389,
0.000836328820105411, 0.000896282784439498, 0.000934898548636007,
1.33579105319752e-05, 0.000346698554469507, 0.000709639039591056,
0.00085064502657751, 0.000911940958263408, 0.000951941732575215,
1.40921855167161e-05, 0.000360366454499725, 0.00072527301743789,
0.000867341425654652, 0.000930119199218286, 0.000971682661364485,
1.51283628387271e-05, 0.000375156371048061, 0.00074274728119305,
0.000886045945095226, 0.000950411585396377, 0.000993679671427741,
1.64086412109995e-05, 0.000390841700356703, 0.000761746112213096,
0.000906413473510349, 0.000972445999346527, 0.00101753047040848,
1.7880497067884e-05, 0.000407231584086262, 0.000781994650923767,
0.000928150942455405, 0.000995913232488212, 0.0010429053637649,
1.94984979873857e-05, 0.00042418339917928, 0.000803284047674769,
0.000951041169715997, 0.00102058934073214, 0.00106956926217307,
2.12310970564738e-05, 0.000441609461524403, 0.000825484776396804,
0.000974951045251249, 0.00104633761063204, 0.00109737770337995,
2.30580060365995e-05, 0.000459447380026377, 0.000848491349457904,
0.000999768079653752, 0.00107304225424432, 0.00112620820936271,
2.49646058170808e-05, 0.000477656645697504, 0.000872214955611117,
0.00102539305673635, 0.00110060064180262, 0.00115595202924147,
2.69388475420207e-05, 0.000496202224842003, 0.000896572115201702,
0.00105173083306456, 0.00112891366068801, 0.00118650362080674,
2.89688557307916e-05, 0.000515049458822506, 0.000921479951229104,
0.00107868674984624, 0.00115788251797123, 0.00121775760850426,
3.10417936910623e-05, 0.000534165595306912, 0.000946858794930037,
0.00110616883239322, 0.00118741028861386, 0.00124961004268288
), .Dim = c(6L, 51L), .Dimnames = list(c("X0.08", "X0.5", "X1",
"X1.5", "X2", "X2.5"), c("X0.08", "X0.5", "X1", "X1.5", "X2",
"X2.5", "X3", "X3.5", "X4", "X4.5", "X5", "X5.5", "X6", "X6.5",
"X7", "X7.5", "X8", "X8.5", "X9", "X9.5", "X10", "X10.5", "X11",
"X11.5", "X12", "X12.5", "X13", "X13.5", "X14", "X14.5", "X15",
"X15.5", "X16", "X16.5", "X17", "X17.5", "X18", "X18.5", "X19",
"X19.5", "X20", "X20.5", "X21", "X21.5", "X22", "X22.5", "X23",
"X23.5", "X24", "X24.5", "X25")))

	[[alternative HTML version deleted]]

