View source: R/regression_models.R

Non linear least squares regression for percentages or proportions | R Documentation |

Non linear least squares regression for percentages or proportions.

```
propols.reg(y, x, cov = FALSE, tol = 1e-07 ,maxiters = 100)
```

`y` |
The dependent variable, a numerical vector with percentages or proporions, including 0s and or 1s. |

`x` |
A matrix with the indendent variables. |

`cov` |
Should the sandwich covariance matrix and the standard errors be returned? If yes, set this equal to TRUE. |

`tol` |
The tolerance value to terminate the Newton-Raphson algorithm.
This is set to |

`maxiters` |
The maximum number of iterations that can take place during the fitting. |

The ordinary least squares between the observed and the fitted percentages is adopted as the objective function. This involves numerical optimization since the relationship is non-linear. There is no log-likelihood. This is the univariate version of the OLS regression for compositional data mentioned in Murteira and Ramalho (2016).

A list including:

`sse` |
The sum of squares of the raw residuals. |

`be` |
The beta coefficients. |

`seb` |
The sandwich standard errors of the beta coefficients, if the input argument argument was set to TRUE. |

`covb` |
The sandwich covariance matrix of the beta coefficients, if the input argument argument was set to TRUE. |

`iters` |
The number of iterations required by the Newton-Raphson algorithm. |

Michail Tsagris.

R implementation and documentation: Michail Tsagris mtsagris@uoc.gr.

Murteira, Jose MR, and Joaquim JS Ramalho 2016. Regression analysis of multivariate fractional data. Econometric Reviews 35(4): 515-552.

`prophelling.reg, simplex.mle, kumar.mle `

```
y <- rbeta(150, 3, 4)
x <- iris
a <- propols.reg(y, x)
```

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.