logit function to transform proportional data for regression

This function is used to transform proportional data between 0-1 to real values for statistical analysis such as regression
63 Descargas
Actualizado 16 ago 2023

Ver licencia

This function logit.m is used to transform proportional data between 0-1 to for statistical analysis such as regressions. The logit transform of x is defined as follows:
logit(x) = log(x/(1-x))
This function transforms the proportions between 0-1 into real numbers between -Inf and +Inf for use in regression analysis
This function uses an epsilon method to truncate the proportion data if there are occurrences of 0 and/or 1 values where epsilon is half of the lowest non-zero value of x (if there are 0 values but not 1 values) or epsilon is half of the difference between 1 and the highest non-one value of x (if there are 1 values but not 0 values) or the min of half of the lowest non-zero value of x and half of the difference between 1 and the highest non-one value of x (if there are 0 and 1 values but not 0 values) and epsilon is substituted for the zero values and 1-epsilon is substituted for the 1 values to truncate and maintain symmetry and shape of the logit distribution.
This function uses the following two other custom matlab functions by Jan Gläscher that are also in the mathworks file exchange repository named "NaN Suite" (available at https://www.mathworks.com/matlabcentral/fileexchange/6837-nan-suite):
- nanmin2 find the minimum value from a vector or array that may contain nan values
- nanmax2 find the maximum value from a vector or array that may contain nan values

Citar como

Gregory Pelletier (2024). logit function to transform proportional data for regression (https://www.mathworks.com/matlabcentral/fileexchange/131509-logit-function-to-transform-proportional-data-for-regression), MATLAB Central File Exchange. Recuperado .

Compatibilidad con la versión de MATLAB
Se creó con R2023a
Compatible con cualquier versión
Compatibilidad con las plataformas
Windows macOS Linux
Etiquetas Añadir etiquetas

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!
Versión Publicado Notas de la versión
1.0.1

epsilon logic update

1.0.0