Tag: F#
-
A safer way to use F# with SQL CLR
Every blog post I’ve read about using F# with SQL CLR involves turning off SQL CLR security for the entire database like so: alter database mydatabase set trustworthy on This is because there is not currently a “safe” FSharp.Core, and so even when building with –standalone you must load the assemblies in to SQL as…
-
Developing an Algorithm in F#: Fast Rotational Alignments with Gosper’s Hack
This post is for the 7th day of the 2014 F# Advent Calendar. It has been said that functional languages can’t be as fast as their imperative cousins because of all of the allocation and garbage collection, this is patently false (as far as F# is concerned at least) largely because the CLR has value types.…
-
My 2013 F# Year in Review
It’s been a great year for F# with the blossoming of the fsharp.org working groups. It’s been amazing watching the community come together to form a movement outside of Microsoft. This is most certainly the long term future of F#, protected from the whims of layer upon layer of management. Who knows, in the coming year we…
-
Setting up F# Interactive for Machine Learning with Large Datasets
Before getting started with Machine Learning in F# Interactive it’s best to prepare it for large datasets so you don’t get blindsided with strange errors when you happen to cross the line. The good news is it’s a simple process that should only take a few minutes. The first step is to go into the…
-
Levenshtein Distance and the Triangle Inequality
Levenshtein distance is one of my favorite algorithms. On the surface it seems so very simple, but when you spend some time thinking hard on it deep insights are waiting to be had. The first and most important thing about Levenshtein distance is it’s actually a metric distance. That is, it obeys the triangle inequality. For…
-
2011 In Retrospect: A Year of Writing F# Professionally
For the past year I’ve been working almost entirely in F# and have found the experience to be everything I hoped it to be and better. In just six months I was able to bring a research project to fruition which has since made our company millions of dollars. F#’s terseness made algorithms a joy…
-
Advice for Getting Started with F#
I had a great time at NYC Code Camp this last weekend. About half the people in my talk already knew F# and were there to talk about Type Providers, the other half just came to see what this F# thing was all about. This post is to help those in the second half begin their F#…
-
Record Linkage Algorithms in F# – Extensions to Jaro-Winkler Distance (Part 3)
While writing the previous article on tokenized matching I realized I left out some important background information on Jaro-Winkler distance. First, there’s something important to know about the Jaro-Winkler distance: it’s not a metric distance and so does not obey the triangle inequality. That is, if you found the JW distance between strings A and B, and then…
-
Imperative Pseudocode to Pure Functional Algorithm with Gale-Shapely and F#
Continuing from last time, let’s look at how one goes from imperative pseudocode to pure functional using Gale-Shapely as an example. Overall, to convert an algorithm from imperative to functional is a fairly simple process once you understand how to convert from a while loop to recursion with accumulators. This post is just a more advanced…
-
Record Linkage in F# – Token Matching, Stable Marriages and the Gale-Shapley algorithm
This post was originally published September 13th, 2011. Initially, one of the biggest problems I found when trying to marry records was the god awful quality of much of data I often have to work with. It’s mostly old mainframe and database data with truncated fields, limited character sets and fields with nonsensical contents. Even…