Skip to content

Commit

Permalink
estats cluster plot takes distance function -- faces needs MinDist, n…
Browse files Browse the repository at this point in the history
…ot ContrastDist
  • Loading branch information
rcoreilly committed Oct 8, 2024
1 parent f166ecf commit 3335d57
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions estats/plots.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,12 +27,12 @@ func ConfigPCAPlot(plt *plotcore.PlotEditor, dt *table.Table, nm string) {

// ClusterPlot does one cluster plot on given table column name
// and label name
func ClusterPlot(plt *plotcore.PlotEditor, ix *table.IndexView, colNm, lblNm string) {
func ClusterPlot(plt *plotcore.PlotEditor, ix *table.IndexView, colNm, lblNm string, dfunc clust.DistFunc) {
nm, _ := ix.Table.MetaData["name"]
smat := &simat.SimMat{}
smat.TableColumnStd(ix, colNm, lblNm, false, metric.Euclidean)
pt := &table.Table{}
clust.Plot(pt, clust.Glom(smat, clust.ContrastDist), smat)
clust.Plot(pt, clust.Glom(smat, dfunc), smat)
plt.Name = colNm
plt.Options.Title = "Cluster Plot of: " + nm + " " + colNm
plt.Options.XAxis = "X"
Expand Down

0 comments on commit 3335d57

Please sign in to comment.