Re: [R] first and second derivative calculation

2012-10-08 Thread jeemba2012
I have a similar problem . Here are functions I know that work properly ## PAnnuity function definition PAnnuity - function(A,y,m,n) { f-(A/(y/m))*(1-1/((1+y/m)^n)) } ##BondPrice function BondPrice - function(c,y,m,n) { B -100 f-PAnnuity((c/m)*B,y,m,n) + B /((1+y/m)^n) } My function of

Re: [R] first and second derivative calculation

2010-01-23 Thread Adaikalavan Ramasamy
* (2 * t) - 6 * 2 -Original Message- From: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org ] On Behalf Of Marlin Keith Cox Sent: Friday, January 22, 2010 4:37 PM To: r-help@r-project.org Subject: [R] first and second derivative calculation I would like to calculate

[R] first and second derivative calculation

2010-01-22 Thread Marlin Keith Cox
I would like to calculate a first and second derivative and am having problems finding a simple solution. My syntax may be off as I am not a mathematician, so pardon ahead of time. data: t-seq(0,4, by=.1) The function is: H(t) = t^3-6*t^2+5*t + 30 from here I plot the curve: plot(x,y

Re: [R] first and second derivative calculation

2010-01-22 Thread Doran, Harold
4:37 PM To: r-help@r-project.org Subject: [R] first and second derivative calculation I would like to calculate a first and second derivative and am having problems finding a simple solution. My syntax may be off as I am not a mathematician, so pardon ahead of time. data: t-seq(0,4, by=.1

Re: [R] first and second derivative calculation

2010-01-22 Thread Marlin Keith Cox
] On Behalf Of Marlin Keith Cox Sent: Friday, January 22, 2010 4:37 PM To: r-help@r-project.org Subject: [R] first and second derivative calculation I would like to calculate a first and second derivative and am having problems finding a simple solution. My syntax may be off as I am

Re: [R] first and second derivative calculation

2010-01-22 Thread David Winsemius
[mailto:r-help-boun...@r-project.org ] On Behalf Of Marlin Keith Cox Sent: Friday, January 22, 2010 4:37 PM To: r-help@r-project.org Subject: [R] first and second derivative calculation I would like to calculate a first and second derivative and am having problems finding a simple solution. My syntax