Plotting is discussed in a separate chapter in this book. However, plotting is a very important part of any interactive computing system. Also ScalaLab is not a Scala library per se. It does own thing but uses Scala as a scripting language. As such, we will discuss ScalaLab's plotting here briefly. Hopefully, this will make explorative computing with ScalaLab much more interesting. Plus, ScalaLab supports a fairly extensive plotting API modeled after MATLAB. An example is shown in the following screenshot:
Let's see how to create a simple plot. We use the
plot method to plot a sinusoid as well as well as the
title method to ...