I = trekIdeal(R,G)
For mixed graphs, the ideal corresponding to all trek separation statements {A,B,CA,CB} (where A,B,CA,CB are disjoint lists of vertices of G) is generated by the r+1 x r+1 minors of the submatrix of the covariance matrix M = (s_{(i,j)}), whose rows are in A, and whose columns are in B, and where r = #CA+#CB.
This function is not yet implemented for mixed graphs with undirected edges.
These ideals are described in more detail by Sullivant, Talaska and Draisma in "Trek Separation for Gaussian Graphical Models" Annals of Statistics 38 no.3 (2010) 1665–1685 and give all determinantal constraints on the covariance matrix of a Gaussian graphical model.




For undirected graphs $G$, the trekIdeal(R,G) is the same as conditionalIndependenceIdeal(R,globalMarkov(G)). For directed graphs $G$, trekIdeal(R,G) is generally larger than conditionalIndependenceIdeal(R,globalMarkov(G)).










trekSeparation is currently only implemented with mixedGraphs that have directed and bidirected edges.
The object trekIdeal is a method function.