Quantcast
Channel: mongodb – SitePoint
Viewing all articles
Browse latest Browse all 37

Creating a Web App with MATLAB and the MEAN Stack

$
0
0

MATLAB is a high-level language used for technical computing. It integrates computation, visualization, and programming in an easy-to-use environment where problems and solutions are expressed in familiar mathematical notation. There are a lot of projects around the world that are written in MATLAB and developed by millions of scientists and engineers. The data of the various experiments and operations that people obtain from MATLAB can be used to power web applications but there are a couple of hurdles:

  • MATLAB understands matrix format data while web applications prefer data in JSON or XML.
  • Often the data are created and consumed inside a MATLAB program which limits the freedom that developers like to have regarding saving the data, using them, and so on

It'd be a lot easier to create applications if MATLAB provided data in JSON and a web application could use those JSON data from MATLAB to create something wonderful.

In this article we'll develop a small demo to demonstrate how to have MATLAB and the MEAN stack working together.

About the web Application

The web application will involve real-time transfer of data from MATLAB to the browser. For simplicity we'll transfer the current time from MATLAB and display it on the browser. We'll use JSONlab, a toolbox to encode/decode JSON files in MATLAB. The web application will be created using the MEAN stack. If you are not familiar with MEAN stack, I suggest you to read the article An Introduction to the MEAN Stack before moving forward.

Introduction to JSONlab

JSONlab is a free and open-source implementation of a JSON encoder/decoder for the MATLAB language. It can be used to convert a MATLAB data structure (array, struct, cell, struct array and cell array) into JSON formatted string, or decode a JSON file into MATLAB data.

Continue reading %Creating a Web App with MATLAB and the MEAN Stack%


Viewing all articles
Browse latest Browse all 37

Trending Articles