Doug’s MATLAB Video Tutorials

July 10th, 2009

Basics: Visualizing a function of two variables

I was interested in visualizing isolines on a graph of BMI. This is a non-linear function of two variables. I thought the best way to visualize this would be with a contour plot.

This video is very basic, it starts by creating the vectors of inputs to this function and then making them into matrices. We then calculate the BMI and modify the contour plot to look more like we want.

Leave a Reply

Wrap code fragments inside <pre> tags, like this:

<pre class="code">
a = magic(3);
sum(a)
</pre>

If you have a "<" character in your code, either follow it with a space or replace it with "&lt;" (including the semicolon).


Doug Hull is a proud MathWorker who is on a mission to help you with MATLAB.

Doug's picture

These postings are the author's and don't necessarily represent the opinions of The MathWorks.