I'm working on a project that involves calculating statistical distance between the elements of a set. This is conceptually like a distance chart between cities that often appears on a travel map, or even a child's multiplication table with the numbers 1 - 10 running across the top and down the left of the table and the products of the numbers in the middle.
All the sample code I've seen for doing something like this is imperative: an outer loop running over the whole set of items, and an inner loop running over the items between the outer loop's item and the end of the set. The calculated distance between the outer loop's current item and the inner loop's current item gets stuck in a 2-D array. I know it's possible to do something like this by going down to java interop, but I feel there must be a more appropriately Clojure way to handle this. I'm not sure how to find it, though. It seems like a math or statistics problem that must be common enough that there is a right way to tackle it. Do any of you laziness and FP wizards have suggestions? Thanks! Michael -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en