|
Dear molofishy!
> X = log10(1./(360*(1. - [0:1:(360*10-1)]/(360*10-1))));
> Y= 1:1:size(x, 2)
> Y1=Y-1
> Shading between these two plots doesn't seem to work:
> A=[X fliplr(X)]
> B=[Y fliplr(Y1)]
> fill[A, B, 'r']
>
> Yet the lines turn black, as opposed to the usual blue...so something is happening. I wanted the area between the lines to be shaded. I am relatively new to matlab. Thanks!
First of all I stuck at:
X = log10(1./(360*(1. - [0:1:(360*10-1)]/(360*10-1))))
Simpler:
X = log10(1 ./ (360:-360/3599:0))
This causes a division by zero. Never mind?!
Then "fill[A, B, 'r']" is not valid, I assume you want:
fill(A, B, 'r')
To my surprise FILL does not close this area, although the help text state this. Nevertheless, closing the shape manually works:
X = log10(1 ./ (360:-360/3599:0))
x(end) = 1; // Filll Inf value from div by 0
A = [X, fliplr(X), X(1)];
B = [Y, fliplr(Y1), Y(1)];
fill(A, B, 'r')
Now you get a red area surrounded by a black line, as I'd expect.
Finally: What do you expect? What do you mean by "shading"?
Jan
|