scoreEquations requires a matrix or a list of sample data as part of the default input. Setting scoreEquations(...,SampleData=>...) to false allows the user to enter a sample covariance matrix instead of sample data. It must be a symmetric matrix.
i1 : G = mixedGraph(digraph {{1,2},{1,3},{2,3},{3,4}},bigraph {{3,4}});
|
i2 : R=gaussianRing(G); |
i3 : U = matrix{{6, 10, 1/3, 1}, {3/5, 3, 1/2, 1}, {4/5, 3/2, 9/8, 3/10}, {10/7, 2/3,1, 8/3}}
o3 = | 6 10 1/3 1 |
| 3/5 3 1/2 1 |
| 4/5 3/2 9/8 3/10 |
| 10/7 2/3 1 8/3 |
4 4
o3 : Matrix QQ <--- QQ
|
i4 : J=scoreEquations(R,U,SampleData=>true)
o4 = ideal (192199680p - 99333449, 267221621760p - 849243924773, 1353974896462794079472640p - 142165262245288892244817,
3,4 4,4 3,3
----------------------------------------------------------------------------------------------------------------------------
6898968p - 11533057, 19600p - 95819, 20855l + 90447, 146915678869660815915l - 4228634793402814499,
2,2 1,1 3,4 2,3
----------------------------------------------------------------------------------------------------------------------------
58766271547864326366l + 4167005135395196717, 574914l - 896035)
1,3 1,2
o4 : Ideal of QQ[l ..l , l , l , p , p , p , p , p ]
1,2 1,3 2,3 3,4 1,1 2,2 3,3 4,4 3,4
|
i5 : V=sampleCovarianceMatrix(U)
o5 = | 95819/19600 25601/3360 -2129/4480 -1313/16800 |
| 25601/3360 867/64 -2321/2304 -173/192 |
| -2129/4480 -2321/2304 337/3072 473/11520 |
| -1313/16800 -173/192 473/11520 3641/4800 |
4 4
o5 : Matrix QQ <--- QQ
|
i6 : I=scoreEquations(R,V,SampleData=>false)
o6 = ideal (192199680p - 99333449, 267221621760p - 849243924773, 1353974896462794079472640p - 142165262245288892244817,
3,4 4,4 3,3
----------------------------------------------------------------------------------------------------------------------------
6898968p - 11533057, 19600p - 95819, 20855l + 90447, 146915678869660815915l - 4228634793402814499,
2,2 1,1 3,4 2,3
----------------------------------------------------------------------------------------------------------------------------
58766271547864326366l + 4167005135395196717, 574914l - 896035)
1,3 1,2
o6 : Ideal of QQ[l ..l , l , l , p , p , p , p , p ]
1,2 1,3 2,3 3,4 1,1 2,2 3,3 4,4 3,4
|