Coordinate Transforms in .Net Core 3 with MathNet

Coordinate Transforms in .Net Core 3 with MathNet

Sometimes you will need to convert between two coordinate systems. In this case, we are going to transform the coordinates using .Net Core 3.0 and MathNet. The MathNet assemblies can be download from NuGet; I am using MathNet 4.8.1, which is the latest version at the time of writing and is already compatible with .Net Core 3.0. In my example, I have two coordinate systems, one starting at point 0,0 and with a max x and y of 600 and…

Read More Read More

Protein Visualization in VSCode

Protein Visualization in VSCode

VSCode Python add-in now supports ipywidgets in Jupyter Notebooks so you can view a protein or molecule visualization directly within the VSCode environment. First, we need to load the nglview library into the Jupyter Notebook environment. To do this, I am going to use anaconda. Quick note, the first time I tried to install the packages, I got several errors; however, after updating to the latest stable versions of anaconda and node, everything ran a lot smoother. I am using…

Read More Read More

Connecting VSCode to a Jupyter Notebook

Connecting VSCode to a Jupyter Notebook

I have been working a lot in Jupyter notebooks; however, as a coding environment, it lacks many of the bells and whistles that you get with an IDE. With the latest version of the VSCode Python plugin, you work directly with the Jupyter Notebook from within the IDE. The extension provides Intellisene support and the ability to run the Python code within the page. For example, here is the previous code I used to demonstrate RDKit running in my Jupyter…

Read More Read More

RDKit in Jupyter Notebooks

RDKit in Jupyter Notebooks

The Jupyter Notebook is an open-source web application that allows the creation and sharing of documents that can contain embedded Python code, and, data visualizations in SVG (Scalable Vector Graphics), and text. When analyzing data that has an associated molecular structure, it would be useful to visualize the structure within the current Jupyter notebook page rather than finding the record in the dataset and copy/pasting the raw structure format into another application. RDKit is an open source cheminformatics software toolkit…

Read More Read More

Windows Mixed Reality Developers Edition

Windows Mixed Reality Developers Edition

The developer’s editor VR (Virtual Reality) hardware was announced at Build 2017 however since the announcement very little information has been released. The dev kits started to ship two month ago; this article is my impression of the hardware and software based on the Acre Developers Edition headset. As this is a developers release, you would expect some rough edges and “issues”. The instructions for getting the headset up and running are straightforward, they equated to open the box and…

Read More Read More

Microsoft and the R(evolution)

Microsoft and the R(evolution)

Over the last few years Microsoft have been building infrastructure to support the R language within a number of tools, technologies and platforms. Microsoft R Open Initially distributed by Revolution as Revolution R Open and after acquisition in 2015 the free to own and distribute version of R was rebranded Microsoft R Open. The current release is based on R-3.3.3 (with new distributions coming out a month following the CRAN version update). In addition to the total compatibility with the…

Read More Read More

Reading and Writing Delimited Files in .Net Core

Reading and Writing Delimited Files in .Net Core

I often need to read and write files in delimited files from within a .Net Core application. It seems that there is no inbuilt parser for doing this so I wrote one. The code consists of a single static class “DelimtedFile” that has two methods, one to read a delimited file and one to write one.

“Error in editor” using swirl in R Studio.

“Error in editor” using swirl in R Studio.

When R Studio is running the swirl package and the swirl tutorial attempts to open an editor containing a code snippet, the following error is displayed and swirl will exit. Error in editor(file = file, title = title) : argument “name” is missing, with no default | Leaving swirl now. Type swirl() to resume. Before you restart the swirl tutorial type the following command at the prompt. options(editor = “internal”) Now when you restart the tutorial the editor will be…

Read More Read More

Creating an R Package with Native Code using Rcpp.

Creating an R Package with Native Code using Rcpp.

There does not appear to be a good set of instructions on getting a new custom R Package (utilizing Rcpp to call C++ from R) so given that I have gone through the pain of configuring this for a project I am working on I decided to write down some instructions on what I did. Initial Set-up I have the following pieces of software installed. R Studio – 0.99.902 R Version – 3.3.0 R Tools – 3.3.0.1959 As getting R…

Read More Read More

The Age of the Connected Scientist.

The Age of the Connected Scientist.

Paper, Paper everywhere as far as the eye can see. When I first started working in a lab fresh out of university everything was recorded in paper notebooks (OK I might be dating myself here). At the end of each day we wrote up the days experiment, pasted in printouts from balances, signed across the printout and the page (to ensure that the printout was not tampered with) and signed the bottom of each page. At the end of the week…

Read More Read More