Saturday, August 21, 2010

Drawing contour plots z = f(x,y) using R

Our equation contour plot drawing page requires an equation of the form z = f(x,y). Colors may be assigned to the levels of Z.

This solver page allows setup of the following parameters.

  • gx, gy - rectangular dimension width, height in inches of contour plot.
  • xlo, xhi, nx - lower and upper limits for x and number of points for x.
  • ylo, yhi, ny - lower and upper limits for x and number of points for x.
  • colors - choices are [gray|rainbow|topo.color|terrain.color|heat.color}
  • equation - the formula for z as a function of both x and y.
  • image - whether to display plain level-curves only or colored contours.
  • levels - maximum number of levels to display.
  • Title-title of plot

Here is an output for contour plot whose equation is $$z = exp((sin(x))^2+ cos(y).$$

No comments:

Post a Comment