transform {dsfa} R Documentation

## transform

### Description

Transforms a matrix via the specified function.

### Usage

transform(x, type, par, deriv_order)


### Arguments

 x numeric matrix to be transformed. type string, specifies the transformation function. Available are: identity: f(x)=x. exp: f(x)=\exp\{x\}. log: f(x)=\log\{x\}. glogit: f(x)=\log\{(-x + min)/(x - max), where par=c(min, max). glogitinv: f(x)=\exp\{x\} \cdot (max + min)/(1 + \exp\{x\}) , where par=c(min, max). inv: f(x)=\frac{1}{x}. pnorm: f(x)=\Phi(x). qnorm: f(x)=\Phi^{-1}(x). mexp: f(x)=-\exp\{x\}. zeta: f(x)=\log\{2 \cdot \Phi(x)\}. constant: f(x)=c. chainrule_utility: f(x)=f'(x)=f''(x)=f'''(x)=f''''(x). onemx: 1-x par numeric vector, additional parameters, e.g. min and max for glogit. deriv_order integer; maximum order of derivative. Available are 0,2 and 4.

### Details

Takes the numeric matrix x as an input for the function specified by type and evaluates it together with the derivatives.

### Value

Returns an object of class derivs.

### Examples

A<-matrix(c(1:9)/10, ncol=3)
A_mat<-list2derivs(list(A, A^0, A^2, A^3, A^4), deriv_order=4)
transform(x=transform(x = A, type="exp", par=0, deriv_order=4), type="log", deriv_order=4, par = 0)



[Package dsfa version 2.0.1 Index]