Continuing with the BF compiler, it’s time to look at how to create code targeting the CLR. As before, I will be using F# to generate the target MSIL.
So I thought to myself, what does the world need? Obviously another brainfuck (BF) compiler. In this series I will use F# and FParsec to compile BF source code into MSIL to run in Microsoft’s CLR. Honestly, this isn’t a particularly ground-breaking task, but it serves as a fun opportunity to showcase a popular parsing library. Beyond that, it shows how easy it is for F# to leverage various parts of the .NET ecosystem.
This post is a follow up to my previous look into Text Analytics. It will provide additional examples of how data can be pulled and processed in F#. I’ll also use this as an opportunity to draw more charts. For all this to happen, I’ll be doing light analysis of the full text of Mary Shelley’s “Frankenstein”.
Today I look into performing linear regression using F#. The implementations of interest will be the MathNet and Accord.NET libraries. I assume you already know what linear regression is, but in can you need a refresher: Linear Regression. My goal is to provide a simple explanation of how to leverage some existing F# accessible libraries. Once you know some of the basic calling functions, you can go crazy with some of the other options these libraries have to offer.