Displaying 1 result from an estimated 1 matches for "m_p1".
Did you mean:
__p1
2010 Oct 05
2
Using as.polynomial() over a matrix
...a.c dM_a.c.sq
[1,] -0.00593058 -0.000688 3.65e-05
[2,] -0.01913294 0.000103 1.41e-04
[3,] -0.01317958 -0.001190 1.49e-04
[4,] -0.02651112 -0.001550 2.37e-04
[5,] -0.01680289 -0.003520 2.86e-04
So - looks like the coercion hasn't worked. BUT, if I do things piecemeal - it looks ok..
> m_p1<-as.polynomial(m[1,])
> m_p1
-0.00593058 - 0.000688*x + 3.65e-05*x^2
--------------------------------
-------------------------------
2. This made me think I was making some wrong assumptions using apply(). So I wrote a function "test()", to take each row of (m) , use as.polynomial...