LabDeck Notes for Python

LabDeck Notes is a document-oriented programming interface for interactive computing. LabDeck Notes allows the user to combine Python script, MatDeck script, Python files as well as GUI Toolboxes in one place with pristine presentation.

LabDeck Notes is a way to organize your ideas and concepts and to bring them to life into a document which can show them. Its main benefits are

  • Interactive computing: LabDeck Notes allow you to run code, see the results, and modify the code in a single environment, making it easy to test and debug your code.
  • Reproducibility: LabDeck Notes allow you to document your code, data, and results in a single place, making it easy to share and reproduce your work.
  • Ease of use: LabDeck Notes are user-friendly and have a simple, document-based interface that allows you to write and run code, add text and visualizations, and save and share your work.
  • Customisation: LabDeck Notes give you the option to tailor each part of your document from the code to the GUIs to the narrative text. Everything can be changed and customized toy your needs.

LabDeck Notes is available in all MD Products, however other MD Products come with other features such as IDEs and several GUI Designers while LabDeck Notes is focused on providing an interactive document rather than an environment strictly for programming.

MD Products also come with a larger array of LabDeck Notes features such as ArrayFire GPU Acceleration which is available in MatDeck or Exporting Documents as HTML with Visionary Deck and higher MD Products.

Combining Python functions with MatDeck features using the Call Function

In LabDeck Notes, we can use any Python functions that we have already made directly in our document, like a native MD function. This is done using the Call function, which allows you to integrate the Python function as a MD Function in the MD Document. This allows you to combine all your hard work in Python with all of our MD features, this includes 2D Graphs, 3D Graphs, SCADA and an assortment of toolkits.

python functions

As we can see here, the Python functions VecData1() and VecData2() are used in this example to import the data we have processed and organized in Python. Using this data, we can plot a graph in LabDeck Notes to visualize the relationship between height and weight.

However, we don’t not need to write a single line of code as LabDeck Notes allows you to combine your Python code with MD functions as well as Graphs and other Toolkits, this makes it easier and more intuitive to run things such as regressions and distributions.

linear regression

As you can see using just one line of code, we can apply a linear regression to our data as well as prepare it to be plotted inside our document. After all this we can once again use send data back to our Python program.

Using code in LabDeck Notes

LabDeck Notes allow you to have an explanation right alongside your code and solutions. Titles, Heading and Text can be easily customized just like Microsoft Word. You can code in Python, MatDeck Script as well as directly in the canvas.

mix and match coding languages

As you can see above, Python code can be added and executed in LabDeck Notes via text code. The same can go for MatDeck Script, as we can mix and match these two languages.

Using LabDeck Notes GUIs with Python and MD Script

MatDeck has a plethora of GUI which allows the users to reduce code and visualize their solution. However, the main benefit of using our GUIs is that they require no-code and save you time.

database toolbox

As you can see, our Database Toolbox will allow you to create custom tables with customized fields. We can also view data from any database, Execute SQL queries as well as read and write any data to and from any variable in both Python and MatDeck.

switching variables between different languages

They can be used along Python as well due to MatDeck’s ability to switch variables between different languages. This means that you can code in Python before switching effortlessly to use one of our GUI Toolboxes and then returning back to your Python code, or if you are looking for constant efficiency you can code in MatDeck Script the whole time.

Formula Templates

Formula Template are pre-made formulas that are ready to be used in LabDeck Notes, they allow users to insert Chemistry, Physics and DSP formulas and solutions directly into a document without the need of typing them up yourself.

Formula Templates allow users to only change one or two variable values to achieve their answer instead of having to write the whole formula from scratch. All part of a Formula Template is already defined and ready to be used straight away.

Embed 2D and 3D Graphs Natively.

LabDeck comes equipped with both 2D and 3D Graphs which are ready to be use, these graphs require no set up and accept multiple variable types and expressions. 2D graphs can plot set of co-ordinates, arrays, vectors, matrices, regressions, Distribution as well as any plottable expressions generated from a MD function or GUI.

2d graphs customisation

2D graphs also come with immense customisation without the need of any code. Lines, Curves, Axis, Titles and more can be changed in a few clicks allowing the user to best visualize what the graph is showing, we can see this below.

2d graphs customisation

The same goes for 3D Graphs, as they can be easily created and embedded in LabDeck Notes with up to 3 plots on one graph. Just like 2D graphs, our 3D Graphs are pre-made and od not requre you to code anything.

3d graphs customisation

3D Graphs also have their own interactive window for them to be viewed in.

3d graph interactive window

Just like this we can change ours plots colour as well as apply wireframes tangents and more.

Important Links

For tips and useful information on how to use the different features in MD Python, use the following manuals: