help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: contourf


From: Henry F. Mollet
Subject: Re: contourf
Date: Fri, 15 Jul 2005 18:56:14 -0700
User-agent: Microsoft-Entourage/11.1.0.040913

1. I had the same problem with the example given for contourf.
Even more unexpected a plot appeared in Preview at an intermediate stage in
B&W quickly (see attached) while the plot in AquaTerm took considerably
longer.

2. Colors are selected for the different contours by default. I have no idea
how to control them.

3. Contourf(z) appears to take a categorical variable from 0 to 200 for both
x and y (I was going to attach a pdf but it is ~2MB, I can send it
separately upon request).

4. Contour (x,y,z) will use the actual values for x and y (I was going to
attach a pdf but it is ~2MB. I can send it separately upon request).
I'm attaching a simpler pdf for z = sinc(sqrt(x.^2 + y.^2)) which is only
100 kB.
Henry

Coding:
octave:8> [x,y] = meshgrid(linspace(-2,2,200));
octave:9> whos
octave:10> z = sinc(sqrt(x.^2 + y.^2)) + 0.5*randn(size(x));
octave:11> contourf(z);
error: expecting integer index, found 7.300000
error: evaluating argument list element number 1
error: called from `contourf' in file
`/usr/local/share/octave/2.1.71/site/m/octave-forge/plot/contourf.m'
octave:11> whos
octave:12> [x,y] = meshgrid(linspace(-2,2,200));
octave:13> z = sinc(sqrt(x.^2 + y.^2)) + 0.5*randn(size(x));
octave:14> contourf(z);
octave:15> contour(z)

octave:28> clear all
octave:29> x = linspace(-2,2,200);
octave:30> y =x;
octave:31> [xx,yy]=meshgrid(x,y);
octave:32>  z = sinc(sqrt(xx.^2 + yy.^2)) + 0.5*randn(size(xx));
octave:33> whos
octave:34> contour(x,y,z)

N.B. I'm in the process of transferring contour and other plots from Octave
2.1.46/Gnuplot 3.8 to Octave 2.1.71/Gnuplot 4.0 and it appears to be no
picnic. What I've tried so far did not work even after some modifications.

on 7/15/05 3:10 AM, Carine Simon at address@hidden wrote:

> 
> Hi all,
> 
> I don't understand how to include colours in a contourf plot. Is it possible ?
> Another thing is: is there a way to do as Matlab i.e. precise the axes for
> contourf. For example doing something like contourf(xaxis, yaxis, matrix)
> A last point is that sometimes when I use contourf I get some errors like:
> error: expecting integer index, found 2.291667
> error: evaluating argument list element number 1
> error: called from `contourf' in file
> `/usr/share/octave/2.1.71/site/m/octave-forge/plot/contourf.m'
> 
> then I juste type the same contourf command and everything works.
> 
> I am using octave 2.1.71 with the last octave-forge on Linux Fedora Core 3.
> A last point by the way: is it normal that each time I start octave I get the
> following warnings:
> warning: gset is deprecated and will be removed from a future
> warning: version of Octave.
> warning: You should use the higher-level plot functions
> warning: ("plot", "mesh", "semilogx", etc.) instead
> warning: of the low-level plotting commands.
> warning: If you absolutely must use this function, use the
> warning: internal version __gnuplot_set__ instead.
> 
> Cheers,
> Carine.
> 
> -------------------------------------------------
> This mail sent through IMP: http://horde.org/imp/
> 
> 
> 
> -------------------------------------------------------------
> Octave is freely available under the terms of the GNU GPL.
> 
> Octave's home on the web:  http://www.octave.org
> How to fund new projects:  http://www.octave.org/funding.html
> Subscription information:  http://www.octave.org/archive.html
> -------------------------------------------------------------
> 

Attachment: oct-3Dbxx3.jpg
Description: Binary data

Attachment: Figure 2Simplified.pdf
Description: Binary data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]