const fieldName = "theme"; // Your field with linksconst oldPrefix = "Thoughts/01 Themes/";const newPrefix = "Digital Garden/Topics/";const relatedLinks = dv.current()[fieldName];if (Array.isArray(relatedLinks)) { // Map over the links, replace the path, and output only clickable links dv.el("span", relatedLinks .map(link => { if (link && link.path) { let newPath = link.path.startsWith(oldPrefix) ? link.path.replace(oldPrefix, newPrefix) : link.path; return dv.fileLink(newPath); } }) .filter(Boolean).join(", ") // Remove any undefined/null items );} else { dv.el(dv.current().theme);}
Gram Matrix
Let v1,…,vn∈Fk be a (finite) collection of vectors in Fk, which has inner product⟨⋅,⋅′⟩. The Gram MatrixG of the vi is given by
Gij=⟨vi,vj⟩,G=V∗V
Where V is the matrix with vi as its ith column
Notes
The lengths of the vi are the entries along the diagonal
The angles between each pair are on the off-diagonal
This information describes the entire geometry of the set of vectors; If any other set of vectors u1,…,un has the same Gram matrix, then there must exist some Q∈O(k) such that Qvi=ui for all i.
In this case, it is possible to get from one point cloud to the other via some orthogonal transformation - this is an if and only if!