Displaying 20 results from an estimated 3000 matches similar to: "Polynomial lags"
2005 Aug 25
1
PDL model
Dear r-help team:
Is a package implemented in R which includes a function that calculates
polynomial distributed lag models (also: Almon models, pdl-model)? Provided
a pdl function is available, can it be applied to robust statistics like
MM-estimators?
Thanks in advance!
Best regards,
Carsten Colombier
Dr. Carsten Colombier
Economist
Group of Economic Advisers
Swiss Federal Finance
2000 May 10
0
Polynomial Distributed Lags?
Has anyone writtent an R function for estimating linear
models with polynomial distributed lags?
Thanks,
Barnet Wagman
wagman at enteract.com
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not
2004 Dec 03
3
Computing the minimal polynomial or, at least, its degree
Hi,
I would like to know whether there exist algorithms to compute the
coefficients or, at least, the degree of the minimal polynomial of a square
matrix A (over the field of complex numbers)? I don't know whether this
would require symbolic computation. If not, has any of the algorithms been
implemented in R?
Thanks very much,
Ravi.
P.S. Just for the sake of completeness, a
2007 Aug 15
1
Polynomial fitting
Hi everybody!
I'm looking some way to do in R a polynomial fit, say like polyfit
function of Octave/MATLAB.
For who don't know, c = polyfit(x,y,m) finds the coefficients of a
polynomial p(x) of degree m that fits the data, p(x[i]) to y[i], in a
least squares sense. The result c is a vector of length m+1 containing
the polynomial coefficients in descending powers:
p(x) = c[1]*x^n +
2008 Jan 07
3
Polynomial fitting
I wonder how one in R can fit a 3rd degree polynomial to some data?
Say the data is:
y <- c(15.51, 12.44, 31.5, 21.5, 17.89, 27.09, 15.02, 13.43, 18.18, 11.32)
x <- seq(3.75, 6, 0.25)
And resulting degrees of polynomial are:
5.8007 -91.6339 472.1726 -774.2584
THanks in advance!
--
Jonas Malmros
Stockholm University
Stockholm, Sweden
2013 Apr 27
2
Polynomial Regression and NA coefficients in R
Hey all,
I'm performing polynomial regression. I'm simulating x values using runif() and y values using a deterministic function of x and rnorm().
When I perform polynomial regression like this:
fit_poly <- lm(y ~ poly(x,11,raw = TRUE))
I get some NA coefficients. I think this is due to the high correlation between say x and x^2 if x is distributed uniformly on the unit interval
2010 Oct 05
2
Using as.polynomial() over a matrix
Hello All
First - a warning. I'm not very R or programming savvy.
I am trying to do something without much luck, and have scoured help-pages, but nothing has come up. Here it is:
I have a matrix (m) of approx 40,000 rows and 3 columns, filled with numbers.
I would like to convert the contents of this matrix into another matrix (m_p), where the numbers of (m) have been coerced into a
2003 Nov 03
1
svm in e1071 package: polynomial vs linear kernel
I am trying to understand what is the difference between linear and
polynomial kernel:
linear: u'*v
polynomial: (gamma*u'*v + coef0)^degree
It would seem that polynomial kernel with gamma = 1; coef0 = 0 and degree
= 1
should be identical to linear kernel, however it gives me significantly
different results for very simple
data set, with linear kernel
2011 Feb 02
2
unequally spaced factor levels orthogonal polynomial contrasts coefficients trend analysis
Hello [R]-help
I am trying to find
> a package where you can do ANOVA based trend analysis on grouped data
> using orthogonal polynomial contrasts coefficients, for unequally
> spaced factor levels. The closest hit I've had is from this web site:
>(http://webcache.googleusercontent.com/search?q=cache:xN4K_KGuYGcJ:www.datavis.ca/sasmac/orpoly.html+Orthogonal+polynomial
>l
but I
2011 Jul 07
1
Polynomial fitting
Hello,
i'm fairly familiar with R and use it every now and then for math related
tasks.
I have a simple non polynomial function that i would like to approximate
with a polynomial. I already looked into poly, but was unable to understand
what to do with it. So my problem is this. I can generate virtually any
number of datapoints and would like to find the coeffs a1, a2, ... up to a
given
2010 May 17
2
best polynomial approximation
Dear R-users,
I learned today that there exists an interesting topic in numerical
analysis names "best polynomial approximation" (BSA). Given a function
f the BSA of degree k, say pk, is the polynomial such that
pk=arginf sup(|f-pk|)
Although given some regularity condition of f, pk is unique, pk IS NOT
calculated with least square. A quick google tour show a rich field of
research
2009 Sep 28
2
Polynomial Fitting
Hello All,
This might seem elementary to everyone, but please bear with me. I've
just spent some time fitting poly functions to time series data in R
using lm() and predict(). I want to analyze the functions once I've
fit them to the various data I'm studying. However, after pulling the
first function into Octave (just by plotting the polynomial function
using fplot() over
2006 Oct 09
1
Coefficients of a factorized polynomial
Hi all,
starting from a vector "v[1:n]" I would like to compute the coefficients
of the polynomial (1+x^v[1])*(1+x^v[2])*...*(1+x^v[n]). The following
code works but is extremely slow for a large "n" due to, I believe, the
polynomial being factorized. I wanted to try the package "polynom"
command "unclass" but I could not figure out how to input a
2012 Apr 19
1
How to find a root for a polynomial between [-inf, -3]?
Hi all,
I have a polynomial (a big one) and I would like to find a root of it
between [-inf, -3] (it's known there is one root in this interval)...
How to find that root?
In using "uniroot" I need to supply the bounds....
In using "polyroot" I need to write it in the strict sens polynomial
format... but I cannot... i.e. the polynomial is implicit...
Thank you!
2012 Apr 18
3
Is there a way to find all roots of a polynomial equation in R?
Is there a way to find all roots of a polynomial equation?
Lets say
x^5+a*x^4+b*x^3+c*x^2+d*x+e=0
how to find its all roots?
[[alternative HTML version deleted]]
2003 Apr 29
1
polynomial fitting
I'm trying to find a way to fit a polynomial of degree n in x and y to
a set of x, y, and z data that I have and obtain the coefficients for
the terms of the fitted polynomial. However, when I try to use the
surf.ls function I'm getting odd results.
> x <- seq(0, 10, length=50)
> y <- x
> f <- function (x, y) {x^2 + y}
> library(spatial)
> test <-
2005 Jun 14
2
ordinary polynomial coefficients from orthogonal polynomials?
How can ordinary polynomial coefficients be calculated
from an orthogonal polynomial fit?
I'm trying to do something like find a,b,c,d from
lm(billions ~ a+b*decade+c*decade^2+d*decade^3)
but that gives: "Error in eval(expr, envir, enclos) :
Object "a" not found"
> decade <- c(1950, 1960, 1970, 1980, 1990)
> billions <- c(3.5, 5, 7.5, 13, 40)
> #
2009 Jul 04
1
Plot 2-d Polynomial without solving it
Hi,
I want to plot a polynomial in the form like ax^2 + bxy + cy^2 + dx + ey + f
=0 without solving it(since I may have 3 or 4 dimensional polynomial and
it's really hard to solve). Is there any way to plot this kind of
polynomial?
Thanks a lot!
--
View this message in context: http://www.nabble.com/Plot-2-d-Polynomial-without-solving-it-tp24331313p24331313.html
Sent from the R help
2003 Jun 23
1
precision matrix for polynomial growth curves
What does the warning message
"1: Singular precision matrix in level -1, block 1" mean?
I get this warning 50+ times when I try to fit the following
model
lme( response ~ covariateA + poly(covariateB,3), ~poly(covariateB,3)|group )
It's not a small dataset - a set of up to 20 blood pressure
readings on just over 2000 people, and I don't get the error
message when I try to fit
2009 Sep 17
1
Problems with the commands FUNCTION and DERIV to build a polynomial
Hi all,
I need to automate a process in order to prepare a a big loop in the future
but I have a problem with the *command function*
First I fit a model with lm
>
model1<-lm(data2[,2]~data2[,1]+I(data2[,1]^2)+I(data2[,1]^3)+I(data2[,1]^4))
I extract the coefficients to build the polynomial.
coef<-as.matrix(model1$coefficients)
In the next step I need to define the polynomial to