<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: Interpolation in MATLAB</title>
	<atom:link href="http://blogs.mathworks.com/loren/2008/06/11/interpolation-in-matlab/feed/" rel="self" type="application/rss+xml" />
	<link>http://blogs.mathworks.com/loren/2008/06/11/interpolation-in-matlab/</link>
	<description>Loren Shure works on design of the MATLAB language at MathWorks. She writes here about once a week on MATLAB programming and related topics.</description>
	<lastBuildDate>Mon, 13 Feb 2012 13:24:10 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
	<item>
		<title>By: John Gunn</title>
		<link>http://blogs.mathworks.com/loren/2008/06/11/interpolation-in-matlab/#comment-32413</link>
		<dc:creator>John Gunn</dc:creator>
		<pubDate>Thu, 04 Aug 2011 21:38:45 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.mathworks.com/loren/2008/06/11/interpolation-in-matlab/#comment-32413</guid>
		<description>Hello,
I am not sure if this blog is still active but I hope it is.

I am looking at interpolating a rather simple set of data. I have a matrix of weekly data (dates and values) for one year in the past. For the last week (say 24th Jul to 30th July), I need to interpolate values for each day, based on available past data.

How can I do this in matlab?

Regards.</description>
		<content:encoded><![CDATA[<p>Hello,<br />
I am not sure if this blog is still active but I hope it is.</p>
<p>I am looking at interpolating a rather simple set of data. I have a matrix of weekly data (dates and values) for one year in the past. For the last week (say 24th Jul to 30th July), I need to interpolate values for each day, based on available past data.</p>
<p>How can I do this in matlab?</p>
<p>Regards.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Loren</title>
		<link>http://blogs.mathworks.com/loren/2008/06/11/interpolation-in-matlab/#comment-32398</link>
		<dc:creator>Loren</dc:creator>
		<pubDate>Thu, 28 Jul 2011 20:47:47 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.mathworks.com/loren/2008/06/11/interpolation-in-matlab/#comment-32398</guid>
		<description>Marc-

John elected to remove some of this files from the file exchange.

--Loren</description>
		<content:encoded><![CDATA[<p>Marc-</p>
<p>John elected to remove some of this files from the file exchange.</p>
<p>&#8211;Loren</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Marc Oldenhof</title>
		<link>http://blogs.mathworks.com/loren/2008/06/11/interpolation-in-matlab/#comment-32397</link>
		<dc:creator>Marc Oldenhof</dc:creator>
		<pubDate>Thu, 28 Jul 2011 11:31:03 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.mathworks.com/loren/2008/06/11/interpolation-in-matlab/#comment-32397</guid>
		<description>Hello John,

It seems the link to polyfitn is invalid. Could you please post a valid link?

Thanks,
Marc</description>
		<content:encoded><![CDATA[<p>Hello John,</p>
<p>It seems the link to polyfitn is invalid. Could you please post a valid link?</p>
<p>Thanks,<br />
Marc</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Anda</title>
		<link>http://blogs.mathworks.com/loren/2008/06/11/interpolation-in-matlab/#comment-31859</link>
		<dc:creator>Anda</dc:creator>
		<pubDate>Fri, 19 Nov 2010 11:45:30 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.mathworks.com/loren/2008/06/11/interpolation-in-matlab/#comment-31859</guid>
		<description>hello ..a have a question..how do i write Ferguson and Hermite-Coons interpolator in matlab,for conditions: r0:=[1,2,3]; r1:=[2,5,1]; r`0:=[0,-1,0]; r`1:=[1,0,1]? thanks</description>
		<content:encoded><![CDATA[<p>hello ..a have a question..how do i write Ferguson and Hermite-Coons interpolator in matlab,for conditions: r0:=[1,2,3]; r1:=[2,5,1]; r`0:=[0,-1,0]; r`1:=[1,0,1]? thanks</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: John D'Errico</title>
		<link>http://blogs.mathworks.com/loren/2008/06/11/interpolation-in-matlab/#comment-31569</link>
		<dc:creator>John D'Errico</dc:creator>
		<pubDate>Mon, 09 Aug 2010 11:53:03 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.mathworks.com/loren/2008/06/11/interpolation-in-matlab/#comment-31569</guid>
		<description>Hi Golnaz,

Given those values of xmin and xmax, try changing inrnd to 10000. Then add this line near the end, but before you pother to try fitting any models.

&lt;pre&gt;
plot3(ptr(:,1),ptr(:,2),ttr&#039;,&#039;.&#039;)
&lt;/pre&gt;

Rotate this plot around, and look at it carefully. First of all, does this look like something that a quadratic model would generate? Recall that a quadratic model as you will form it will take a parabolic shape, with two independent variables. This data is not remotely parabolic. It has a singularity at (0,0), something that no polynomial model will ever yield.

Worse that that, the surface is actually rather bumpy, not at all smooth like a low order polynomial will yield. In fact, it is rather complex.

I&#039;m sorry to say that no simple model will allow you to easily approximate your surface, although you might find some other modeling technique to be of utility. As an offhand idea, perhaps wavelets might be of value.

John</description>
		<content:encoded><![CDATA[<p>Hi Golnaz,</p>
<p>Given those values of xmin and xmax, try changing inrnd to 10000. Then add this line near the end, but before you pother to try fitting any models.</p>
<pre>
plot3(ptr(:,1),ptr(:,2),ttr','.')
</pre>
<p>Rotate this plot around, and look at it carefully. First of all, does this look like something that a quadratic model would generate? Recall that a quadratic model as you will form it will take a parabolic shape, with two independent variables. This data is not remotely parabolic. It has a singularity at (0,0), something that no polynomial model will ever yield.</p>
<p>Worse that that, the surface is actually rather bumpy, not at all smooth like a low order polynomial will yield. In fact, it is rather complex.</p>
<p>I&#8217;m sorry to say that no simple model will allow you to easily approximate your surface, although you might find some other modeling technique to be of utility. As an offhand idea, perhaps wavelets might be of value.</p>
<p>John</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Golnaz Mir</title>
		<link>http://blogs.mathworks.com/loren/2008/06/11/interpolation-in-matlab/#comment-31567</link>
		<dc:creator>Golnaz Mir</dc:creator>
		<pubDate>Sun, 08 Aug 2010 14:34:10 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.mathworks.com/loren/2008/06/11/interpolation-in-matlab/#comment-31567</guid>
		<description>Hello Dear John

Well first thanks a lot for answering me,
Actually I forgot to specify the parameters for you, Xmin=-5 and Xmax=5 and N=2, I used the polyfitn toolbox from matlab exchange files in Mathwork.com.
 
Best Regards,
Golnaz Mir</description>
		<content:encoded><![CDATA[<p>Hello Dear John</p>
<p>Well first thanks a lot for answering me,<br />
Actually I forgot to specify the parameters for you, Xmin=-5 and Xmax=5 and N=2, I used the polyfitn toolbox from matlab exchange files in Mathwork.com.</p>
<p>Best Regards,<br />
Golnaz Mir</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: John D'Errico</title>
		<link>http://blogs.mathworks.com/loren/2008/06/11/interpolation-in-matlab/#comment-31562</link>
		<dc:creator>John D'Errico</dc:creator>
		<pubDate>Thu, 05 Aug 2010 13:49:07 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.mathworks.com/loren/2008/06/11/interpolation-in-matlab/#comment-31562</guid>
		<description>This is a hard one for me to answer, since I don&#039;t know the values of some of your parameters. What are N, xmin, and xmax? A wild guess is that N = 2, since you are talking about 2 dimensions in this example. But what are xmin, xmax?

I also don&#039;t have the neural net toolbox, so I can&#039;t test your code. A check online tells me that mapstd shifts and scale the columns of your array to have mean 0, standard deviation 1. And since I don&#039;t have the communications toolbox, I don&#039;t have randint either, but that too I was able to replace.

Finally, I tried N = 2, xmin = -1, xmax = 1. These seemed like good, generic numbers, although I have no idea if they are reasonable or correct. When I did that, and wrote a simple version of mapstd of my own, the very first thing I tried was to plot what you are trying to fit.

NEVER, EVER just blindly fit a function without plotting it if you can do so, without knowing what you are trying to fit, and without thinking about whether the model you pose is meaningful for that data.

&lt;pre&gt;
plot3(ptr(:,1),ptr(:,2),ttr&#039;,&#039;o&#039;)
&lt;/pre&gt;

When I do so, I see something that is wildly NOT a polynomial. And worse, it is surely not even close to being something that a low order (quadratic) polynomial could ever fit. It has what appears to be possibly a singularity at (0,0). No polynomial model exists that has a singularity in it.

So, no, you cannot use polyfitn for this problem, with ANY order of polynomial model.

If I have tried the wrong parameters and so am wrong about what I&#039;ve seen, please ask again.

John</description>
		<content:encoded><![CDATA[<p>This is a hard one for me to answer, since I don&#8217;t know the values of some of your parameters. What are N, xmin, and xmax? A wild guess is that N = 2, since you are talking about 2 dimensions in this example. But what are xmin, xmax?</p>
<p>I also don&#8217;t have the neural net toolbox, so I can&#8217;t test your code. A check online tells me that mapstd shifts and scale the columns of your array to have mean 0, standard deviation 1. And since I don&#8217;t have the communications toolbox, I don&#8217;t have randint either, but that too I was able to replace.</p>
<p>Finally, I tried N = 2, xmin = -1, xmax = 1. These seemed like good, generic numbers, although I have no idea if they are reasonable or correct. When I did that, and wrote a simple version of mapstd of my own, the very first thing I tried was to plot what you are trying to fit.</p>
<p>NEVER, EVER just blindly fit a function without plotting it if you can do so, without knowing what you are trying to fit, and without thinking about whether the model you pose is meaningful for that data.</p>
<pre>
plot3(ptr(:,1),ptr(:,2),ttr','o')
</pre>
<p>When I do so, I see something that is wildly NOT a polynomial. And worse, it is surely not even close to being something that a low order (quadratic) polynomial could ever fit. It has what appears to be possibly a singularity at (0,0). No polynomial model exists that has a singularity in it.</p>
<p>So, no, you cannot use polyfitn for this problem, with ANY order of polynomial model.</p>
<p>If I have tried the wrong parameters and so am wrong about what I&#8217;ve seen, please ask again.</p>
<p>John</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Golnaz Mir</title>
		<link>http://blogs.mathworks.com/loren/2008/06/11/interpolation-in-matlab/#comment-31559</link>
		<dc:creator>Golnaz Mir</dc:creator>
		<pubDate>Wed, 04 Aug 2010 07:27:53 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.mathworks.com/loren/2008/06/11/interpolation-in-matlab/#comment-31559</guid>
		<description>Hello Dear John

Several months ago I have asked you a question about approximation of Ackley’s function; actually I would like to use the polynomial approximated form of Ackley as a meta-model in an optimization problem.
As you recommended I used the “polyfitn” tool for approximation, the second order polynomial was my choice in both 2 and 10 dimensional problem, but even for 2 dimensional Ackley I could not get good results.
The code I used for 2 dim approximations was this:
inrnd =200; % Number of initial random data generation for the first meta-modelling
p(:,:) = xmin*ones(N,inrnd)+(xmax-xmin)*rand(N,inrnd);
t(:,:) = 20-20*exp(-0.2*sqrt(1/N*sum(p(:,1:inrnd).^2)))-exp(1/N*sum(cos(2*pi*p(:,1:inrnd))))+exp(1);
inrnallb = 10; 
p(:,inrnd+1:inrnd+inrnallb) = xmin*ones(N,inrnallb)+(xmax-xmin)*randint(N,inrnallb,[0,1]);
t(:,inrnd+1:inrnd+inrnallb) = 20-20*exp(-0.2*sqrt(1/N*sum(p(:,inrnd+1:inrnd+inrnallb).^2)))-exp(1/N*sum(cos(2*pi*p(:,inrnd+1:inrnd+inrnallb))))+exp(1);
inrnoneb = 20; % Each variable has its boundary
for i = (inrnallb+inrnd+1) : (inrnallb+inrnd+N*inrnoneb) 
    st = ceil((i-(inrnallb+inrnd))/inrnoneb);
    if st == 1
        p(1,i) = xmin*ones(1,1)+(xmax-xmin)*randint(1,1,[0,1]);
    else
        p(1,i) = xmin*ones(1,1)+(xmax-xmin)*rand(1,1);
    end
    if st == 2
        p(2,i) = xmin*ones(1,1)+(xmax-xmin)*randint(1,1,[0,1]);
    else
        p(2,i) = xmin*ones(1,1)+(xmax-xmin)*rand(1,1);
    end
   
    
    t(:,i) = 20-20*exp(-0.2*sqrt(1/N*sum(p(:,i).^2)))-exp(1/N*sum(cos(2*pi*p(:,i))))+exp(1);
end
w=size(t);
[ptn,ps] = mapstd(p);
[tn,ts] = mapstd(t);
[R,Q(1)] = size(ptn);
numexactfiteval = Q(1);
iitr = [1:5:Q(1) 2:5:Q(1) 3:5:Q(1) 4:5:Q(1) 5:5:Q(1)];
ptr = ptn(:,iitr); ttr = tn(:,iitr);
 
 
 
%.................function approximation................
ptr=ptr&#039;;
modelterms = [0 0 ;1  0;0 1;1 1;2 0;1 2];
polymodel = polyfitn(ptr,ttr,modelterms);
zn=polyvaln(polymodel,ptr);
z=mapstd(&#039;reverse&#039;,zn,ts);
z=z&#039;;
 
for i=1:1
    figure(i)
    [m(i),b(i),r(i)] = postreg(z(i,:),t(i,:)); % regression khati beine natayeje shabake asabi va maghadire asli(target)
    pause(1);
end

I would like to know if I have made any mistakes in using “polyfitn” tools?

Thanks,
Best  Regards,
Golnaz mir.</description>
		<content:encoded><![CDATA[<p>Hello Dear John</p>
<p>Several months ago I have asked you a question about approximation of Ackley’s function; actually I would like to use the polynomial approximated form of Ackley as a meta-model in an optimization problem.<br />
As you recommended I used the “polyfitn” tool for approximation, the second order polynomial was my choice in both 2 and 10 dimensional problem, but even for 2 dimensional Ackley I could not get good results.<br />
The code I used for 2 dim approximations was this:<br />
inrnd =200; % Number of initial random data generation for the first meta-modelling<br />
p(:,:) = xmin*ones(N,inrnd)+(xmax-xmin)*rand(N,inrnd);<br />
t(:,:) = 20-20*exp(-0.2*sqrt(1/N*sum(p(:,1:inrnd).^2)))-exp(1/N*sum(cos(2*pi*p(:,1:inrnd))))+exp(1);<br />
inrnallb = 10;<br />
p(:,inrnd+1:inrnd+inrnallb) = xmin*ones(N,inrnallb)+(xmax-xmin)*randint(N,inrnallb,[0,1]);<br />
t(:,inrnd+1:inrnd+inrnallb) = 20-20*exp(-0.2*sqrt(1/N*sum(p(:,inrnd+1:inrnd+inrnallb).^2)))-exp(1/N*sum(cos(2*pi*p(:,inrnd+1:inrnd+inrnallb))))+exp(1);<br />
inrnoneb = 20; % Each variable has its boundary<br />
for i = (inrnallb+inrnd+1) : (inrnallb+inrnd+N*inrnoneb)<br />
    st = ceil((i-(inrnallb+inrnd))/inrnoneb);<br />
    if st == 1<br />
        p(1,i) = xmin*ones(1,1)+(xmax-xmin)*randint(1,1,[0,1]);<br />
    else<br />
        p(1,i) = xmin*ones(1,1)+(xmax-xmin)*rand(1,1);<br />
    end<br />
    if st == 2<br />
        p(2,i) = xmin*ones(1,1)+(xmax-xmin)*randint(1,1,[0,1]);<br />
    else<br />
        p(2,i) = xmin*ones(1,1)+(xmax-xmin)*rand(1,1);<br />
    end</p>
<p>    t(:,i) = 20-20*exp(-0.2*sqrt(1/N*sum(p(:,i).^2)))-exp(1/N*sum(cos(2*pi*p(:,i))))+exp(1);<br />
end<br />
w=size(t);<br />
[ptn,ps] = mapstd(p);<br />
[tn,ts] = mapstd(t);<br />
[R,Q(1)] = size(ptn);<br />
numexactfiteval = Q(1);<br />
iitr = [1:5:Q(1) 2:5:Q(1) 3:5:Q(1) 4:5:Q(1) 5:5:Q(1)];<br />
ptr = ptn(:,iitr); ttr = tn(:,iitr);</p>
<p>%&#8230;&#8230;&#8230;&#8230;&#8230;..function approximation&#8230;&#8230;&#8230;&#8230;&#8230;.<br />
ptr=ptr&#8217;;<br />
modelterms = [0 0 ;1  0;0 1;1 1;2 0;1 2];<br />
polymodel = polyfitn(ptr,ttr,modelterms);<br />
zn=polyvaln(polymodel,ptr);<br />
z=mapstd(&#8216;reverse&#8217;,zn,ts);<br />
z=z&#8217;;</p>
<p>for i=1:1<br />
    figure(i)<br />
    [m(i),b(i),r(i)] = postreg(z(i,:),t(i,:)); % regression khati beine natayeje shabake asabi va maghadire asli(target)<br />
    pause(1);<br />
end</p>
<p>I would like to know if I have made any mistakes in using “polyfitn” tools?</p>
<p>Thanks,<br />
Best  Regards,<br />
Golnaz mir.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: John D'Errico</title>
		<link>http://blogs.mathworks.com/loren/2008/06/11/interpolation-in-matlab/#comment-31232</link>
		<dc:creator>John D'Errico</dc:creator>
		<pubDate>Thu, 01 Apr 2010 03:32:26 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.mathworks.com/loren/2008/06/11/interpolation-in-matlab/#comment-31232</guid>
		<description>A few extra thoughts after my last response as a cautionary tale...

Too often I see people decide to use a polynomial mode without understanding what they are doing, who have no idea what order model they should use. So they fit a low order model, and it does not give them as good a fit as they want/hope to see. So they try a higher order model. It fits a bit better, so then they decide to fit a really high order model. Of course at some point they end up with such a high order model that it fits the data points perfectly, yet what they don&#039;t realize is this high order model is usually completely meaningless. They have managed to over-fit their data so horrendously that while the polynomial passes through the data points, it also has so much flexibility that it does all sorts of crazy things between the data points. 

Polynomial modeling is both easy to do and difficult, since it is so easy to over-fit your data. Which terms belong in the model? How high an order do you use?

For these reasons I rarely ever recommend fitting a high order polynomial model. Stick with the low order polynomials, linear, quadratics, cubics where necessary. In several dimensions even a full cubic model has many terms in it. If you need more flexibility that that, then it is often a good idea to look at spline models, the shape of which can be controlled using the right tools. Alternatively, look into nonlinear model that have the desired shape built right into the model.</description>
		<content:encoded><![CDATA[<p>A few extra thoughts after my last response as a cautionary tale&#8230;</p>
<p>Too often I see people decide to use a polynomial mode without understanding what they are doing, who have no idea what order model they should use. So they fit a low order model, and it does not give them as good a fit as they want/hope to see. So they try a higher order model. It fits a bit better, so then they decide to fit a really high order model. Of course at some point they end up with such a high order model that it fits the data points perfectly, yet what they don&#8217;t realize is this high order model is usually completely meaningless. They have managed to over-fit their data so horrendously that while the polynomial passes through the data points, it also has so much flexibility that it does all sorts of crazy things between the data points. </p>
<p>Polynomial modeling is both easy to do and difficult, since it is so easy to over-fit your data. Which terms belong in the model? How high an order do you use?</p>
<p>For these reasons I rarely ever recommend fitting a high order polynomial model. Stick with the low order polynomials, linear, quadratics, cubics where necessary. In several dimensions even a full cubic model has many terms in it. If you need more flexibility that that, then it is often a good idea to look at spline models, the shape of which can be controlled using the right tools. Alternatively, look into nonlinear model that have the desired shape built right into the model.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: John D'Errico</title>
		<link>http://blogs.mathworks.com/loren/2008/06/11/interpolation-in-matlab/#comment-31229</link>
		<dc:creator>John D'Errico</dc:creator>
		<pubDate>Wed, 31 Mar 2010 20:32:13 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.mathworks.com/loren/2008/06/11/interpolation-in-matlab/#comment-31229</guid>
		<description>Hi Golnaz,

There are many ways to do this in matlab. If you have the statistics toolbox, then the regress function is available. Or, if that is not an option, then the optimization toolbox (use lsqlin) or the curve fitting toolboxes can help. In matlab itself, there is lscov, or just the backslash operator.

Any of those tools CAN solve the problem, but they will all require you to build the matrix that defines your model. If you don&#039;t know much about regression modeling, this is not a bad thing to learn, at least if you will solve this class of problem again in the future.

This design matrix is a matrix with one column for each term in your model. For example, a linear model in x and y (where x and y are column vectors) would have you build the matrix A:

&lt;pre&gt;
n = numel(x);
A = [ones(n,1),x,y];
&lt;/pre&gt;

And then solve the problem as

&lt;pre&gt;
coef = A\z;
&lt;/pre&gt;

The column of ones in A corresponds to the constant term in the model.

You can build the design matrix A for more complex polynomial models too of course. However, rather than force people to know how to do all of this, as well as go through the effort of building these matrices, I posted a function several years ago on the file exchange to help them with this task. It is called polyfitn, which suggests that it is just an extension of polyfit to problems with several independent variables. You can download it from this link:

http://www.mathworks.com/matlabcentral/fileexchange/10065

Polyfitn will allow you to estimate any simple polynomial model as you need to build. Of course, polyfitn will not help you to decide what order polynomial mode to use. That is a problem that usually requires knowledge of your system, in terms of how much noise is present in the data. It also requires some appreciation of your goals in the process, and what you will do with the model. How accurately do you need to fit the data? Will you need to use it for extrapolation?</description>
		<content:encoded><![CDATA[<p>Hi Golnaz,</p>
<p>There are many ways to do this in matlab. If you have the statistics toolbox, then the regress function is available. Or, if that is not an option, then the optimization toolbox (use lsqlin) or the curve fitting toolboxes can help. In matlab itself, there is lscov, or just the backslash operator.</p>
<p>Any of those tools CAN solve the problem, but they will all require you to build the matrix that defines your model. If you don&#8217;t know much about regression modeling, this is not a bad thing to learn, at least if you will solve this class of problem again in the future.</p>
<p>This design matrix is a matrix with one column for each term in your model. For example, a linear model in x and y (where x and y are column vectors) would have you build the matrix A:</p>
<pre>
n = numel(x);
A = [ones(n,1),x,y];
</pre>
<p>And then solve the problem as</p>
<pre>
coef = A\z;
</pre>
<p>The column of ones in A corresponds to the constant term in the model.</p>
<p>You can build the design matrix A for more complex polynomial models too of course. However, rather than force people to know how to do all of this, as well as go through the effort of building these matrices, I posted a function several years ago on the file exchange to help them with this task. It is called polyfitn, which suggests that it is just an extension of polyfit to problems with several independent variables. You can download it from this link:</p>
<p><a href="http://www.mathworks.com/matlabcentral/fileexchange/10065" rel="nofollow">http://www.mathworks.com/matlabcentral/fileexchange/10065</a></p>
<p>Polyfitn will allow you to estimate any simple polynomial model as you need to build. Of course, polyfitn will not help you to decide what order polynomial mode to use. That is a problem that usually requires knowledge of your system, in terms of how much noise is present in the data. It also requires some appreciation of your goals in the process, and what you will do with the model. How accurately do you need to fit the data? Will you need to use it for extrapolation?</p>
]]></content:encoded>
	</item>
</channel>
</rss>

