Re: graphs and scale factor



My questions regarding the curve fitting to images using the hold method have got much things to do with the scaling issue I realize.

So how can I get help.

The problems is as follows:

The image is generated using for ex: ( 809x 100) matrix.The command is : figure,pcolor();shading interp;

Then the values in the original data is summed to get a (1 x 809) matrix. That is all rows added. This one row , 809 column matrix is plotted using 'plot'. Here the y axis is in the range
( - 5.25x10^5 to -5.65x10^5 ). How to change the y axis for this existing range to the new range of 1 to 100 WITHOUT ofcourse any change in the shape or size of the curve because , ultimately I want to bring upon this curve on the
pcolor() image using ' hold ' command.

Walter Roberson <roberson@xxxxxxxxxxxx> wrote in message <lcMJk.12872$vs7.7224@xxxxxxxxxxxx>...
O G wrote:

When I plot a figure, often times MATLAB will automatically scale the y-axis data and put
something like 'x 10^5' just above the y-axis. Is there a way I can control this behavior.
I'd like to be able to turn it off/on, and also adjust the scale factor to something else.
I know that I can always modify the data directly, but I wanted to control this with plot
function options.

The behaviour is completely automatic (at least up to R2007a). You cannot deliberately
turn it on, and you cannot adjust the scale factor.

What you can do is force it to be off, by

h = plot(x,y);
for K=1:length(h)
set(h(K),'YLabel',num2str(get(h(K),'YTick')))
end

That is, supplying your own formatted text strings for the YLabel turns off the
automatic scaling indicator.

If you -want- to use scaling, then you will need to set the YLabel to the text of
the scaled values, and you will have to text() the scale factor into some
appropriate position.
.



Relevant Pages

  • Re: Scale a vector
    ... The trasformation is like a zoom on images but I need on a vector. ... However, there is a Matrix class; if you already know M and N, and your vector is a 2-dimensional vector, you could initialize a Matrix instance with the scaling factor of M/N along the diagonal and then use the Matrix.TransformVectorsmethod to scale your vector. ...
    (microsoft.public.dotnet.languages.csharp)
  • Re: 120dpi setting for windows and dynamic added controls
    ... The scaling example is fine. ... dependent on the Windows default font used for the UI, ... This method calculated the relative scale sizes from ... user controls would scale correctly ...
    (microsoft.public.dotnet.framework.windowsforms)
  • AffineTransformation (spell checked)
    ... I am trying to scale a series of vertices that have been selected on ... The vertices could be any place on the sphere, ... The scaling is set to 0.5f. ... pRotationCenter, ...
    (microsoft.public.win32.programmer.directx.graphics)
  • Re: Button doesnt have to resize when the screen resolution is changed
    ... isn't telling the truth about it and that breaks the scaling. ... same size on screen, but the pictures that we ... made for the buttons don't scale to fit the button's size. ... Fonts do scale because they are vector based for modern ...
    (comp.lang.tcl)
  • Re: Windows Forms: Control.Scale(SizeF) does not work?
    ... I had a similar problem understanding Scale. ... the dimensions of everything that one time, ... since they will all be created before the first layout, ... After scaling happens, the original components will have their height ...
    (microsoft.public.dotnet.framework.compactframework)

Loading