skip to main content
research-article

Algorithm 1017: fuzzyreg: An R Package for Fitting Fuzzy Regression Models

Published:26 June 2021Publication History
Skip Abstract Section

Abstract

Fuzzy regression provides an alternative to statistical regression when the model is indefinite, the relationships between model parameters are vague, the sample size is low, or the data are hierarchically structured. Such cases allow to consider the choice of a regression model based on the fuzzy set theory. In fuzzyreg, we implement fuzzy linear regression methods that differ in the expectations of observational data types, outlier handling, and parameter estimation method. We provide a wrapper function that prepares data for fitting fuzzy linear models with the respective methods from a syntax established in R for fitting regression models. The function fuzzylm thus provides a novel functionality for R through standardized operations with fuzzy numbers. Additional functions allow for conversion of real-value variables to be fuzzy numbers, printing, summarizing, model plotting, and calculation of model predictions from new data using supporting functions that perform arithmetic operations with triangular fuzzy numbers. Goodness of fit and total error of the fit measures allow model comparisons. The package contains a dataset named bats with measurements of temperatures of hibernating bats and the mean annual surface temperature reflecting the climate at the sampling sites. The predictions from fuzzy linear models fitted to this dataset correspond well to the observed biological phenomenon. Fuzzy linear regression has great potential in predictive modeling where the data structure prevents statistical analysis and the modeled process exhibits inherent fuzziness.

Skip Supplemental Material Section

Supplemental Material

References

  1. G. Badino. 2004. Cave temperatures and global climatic change. International Journal of Speleology 33 (2004), 103–114. DOI:https://doi.org/10.5038/1827-806X.33.1.10Google ScholarGoogle ScholarCross RefCross Ref
  2. S. Bhavyashree, M. Mishra, and G. C. Girisha. 2017. Fuzzy regression and multiple linear regression models for predicting mulberry leaf yield: A comparative study. International Journal of Agricultural and Statistical Sciences 13 (2017), 149–152.Google ScholarGoogle Scholar
  3. Amory Bisserier, Reda Boukezzoula, and Sylvie Galichet. 2010. A revisited approach to linear fuzzy regression using trapezoidal fuzzy intervals. Information Sciences 180 (2010), 3653–3673. DOI:https://doi.org/10.1016/j.ins.2010.06.017Google ScholarGoogle ScholarDigital LibraryDigital Library
  4. Süleyman Çakır. 2017. Measuring logistics performance of OECD countries via fuzzy linear regression. Journal of Multi-Criteria Decision Analysis 24 (2017), 177–186. DOI:https://doi.org/10.1002/mcda.1601Google ScholarGoogle ScholarCross RefCross Ref
  5. Kit Yan Chan and Ulrich Engelke. 2015. Fuzzy regression for perceptual image quality assessment. Engineering Applications of Artificial Intelligence 43 (2015), 102–110. DOI:https://doi.org/10.1016/j.engappai.2015.04.007Google ScholarGoogle ScholarDigital LibraryDigital Library
  6. K. Y. Chan and U. Engelke. 2017. Varying spread fuzzy regression for affective quality estimation. IEEE Transactions on Fuzzy Systems 25 (2017), 594–613. DOI:https://doi.org/10.1109/TFUZZ.2016.2566812Google ScholarGoogle ScholarDigital LibraryDigital Library
  7. Kit Yan Chan, C. K. Kwong, and M. C. Law. 2014. A fuzzy ordinary regression method for modeling customer preference in tea maker design. Neurocomputing 142 (2014), 147–154. DOI:https://doi.org/10.1016/j.neucom.2013.12.056Google ScholarGoogle ScholarDigital LibraryDigital Library
  8. M. Delnavaz, H. Zangooei, and M. Zangooei. 2016. Application of mathematical models and fuzzy regression analysis to determine the microbial growth kinetic coefficients and predicting quality of treated wastewater. Nature Environment and Pollution Technology 15 (2016), 43–50.Google ScholarGoogle Scholar
  9. P. Diamond. 1988. Fuzzy least squares. Information Sciences 46, 3 (1988), 141–157. DOI:https://doi.org/10.1016/0020-0255(88)90047-3Google ScholarGoogle ScholarDigital LibraryDigital Library
  10. Terry E. Dielman. 1986. A comparison of forecasts from least absolute value and least squares regression. Journal of Forecasting 5 (1986), 189–195. DOI:https://doi.org/10.1002/for.3980050305Google ScholarGoogle ScholarCross RefCross Ref
  11. Leandro D. S. Duarte, Vanderlei J. Debastiani, André V. L. Freitas, Valério D. Pillar, and Pedro Peres-Neto. 2016. Dissecting phylogenetic fuzzy weighting: Theory and application in metacommunity phylogenetics. Methods in Ecology and Evolution 7 (2016), 937–946. DOI:https://doi.org/10.1111/2041-210x.12547Google ScholarGoogle ScholarCross RefCross Ref
  12. D. Dubois and H. Prade. 1993. Fuzzy sets and probability: Misunderstandings, bridges and gaps. In Proceedings of the 2nd IEEE International Conference on Fuzzy Systems, Vol. 2. IEEE, San Francisco, CA, 1059–1068. DOI:https://doi.org/10.1109/FUZZY.1993.327367Google ScholarGoogle Scholar
  13. Marek Gagolewski and Jan Caha. 2018. FuzzyNumbers Package: Tools to Deal with Fuzzy Numbers in R. http://FuzzyNumbers.rexamine.com/.Google ScholarGoogle Scholar
  14. Y. Gao and Q. Lu. 2018. A fuzzy logistic regression model based on the least squares estimation. Computational and Applied Mathematics 37, 3 (2018), 3562–3579. DOI:https://doi.org/10.1007/s40314-017-0531-0Google ScholarGoogle ScholarCross RefCross Ref
  15. Jon Garibaldi, Chao Chen, and Tajul Razak. 2017. FuzzyR: Fuzzy Logic Toolkit for R. https://CRAN.R-project.org/package=FuzzyR R package version 2.1.Google ScholarGoogle Scholar
  16. Zhiqiang Geng, Ju Bai, Deyang Jiang, and Yongming Han. 2018. Energy structure analysis and energy saving of complex chemical industries: A novel fuzzy interpretative structural model. Applied Thermal Engineering 142 (2018), 433–443. DOI:https://doi.org/10.1016/j.applthermaleng.2018.07.030Google ScholarGoogle ScholarCross RefCross Ref
  17. Ö. Görgülü and A. Akilli. 2018. Estimation of 305-days milk yield using fuzzy linear regression in jersey dairy cattle. Journal of Animal and Plant Sciences 28 (2018), 1174–1181.Google ScholarGoogle Scholar
  18. Yu-Lin He, Cheng-Hao Wei, Hao Long, Rana Aamir Raza Ashfaq, and Joshua Zhexue Huang. 2018. Random weight network-based fuzzy nonlinear regression for trapezoidal fuzzy number data. Applied Soft Computing 70 (2018), 959–979. DOI:https://doi.org/10.1016/j.asoc.2017.08.006Google ScholarGoogle ScholarCross RefCross Ref
  19. Eyke Hüllermeier. 2015. Does machine learning need fuzzy logic? Fuzzy Sets and Systems 281 (2015), 292–299. DOI:https://doi.org/10.1016/j.fss.2015.09.001Google ScholarGoogle ScholarDigital LibraryDigital Library
  20. W.-L. Hung and M.-S. Yang. 2006. An omission approach for detecting outliers in fuzzy regression models. Fuzzy Sets and Systems 157 (2006), 3109–3122. DOI:https://doi.org/10.1016/j.fss.2006.08.004Google ScholarGoogle ScholarCross RefCross Ref
  21. Maurycy Ignaczak and Tomasz Postawa. 2017. Protection of the Szachownica cave as an example of saving a valuable bat wintering shelter. Proceedings of the Theriological School 15 (2017), 67–74. DOI:https://doi.org/10.15407/ptt2017.15.067Google ScholarGoogle ScholarCross RefCross Ref
  22. H. Jiang, C. K. Kwong, and Woo-Yong Park. 2017. Probabilistic fuzzy regression approach for preference modeling. Engineering Applications of Artificial Intelligence 64 (2017), 286–294. DOI:https://doi.org/10.1016/j.engappai.2017.06.019Google ScholarGoogle ScholarDigital LibraryDigital Library
  23. Usman T. Khan and Caterina Valeo. 2015. A new fuzzy linear regression approach for dissolved oxygen prediction. Hydrological Sciences Journal 60 (2015), 1096–1119. DOI:https://doi.org/10.1080/02626667.2014.900558Google ScholarGoogle ScholarCross RefCross Ref
  24. B. Kim and R. R. Bishu. 1998. Evaluation of fuzzy linear regression models by comparing membership functions. Fuzzy Sets and Systems 100 (1998), 343–352.Google ScholarGoogle ScholarDigital LibraryDigital Library
  25. K. J. Kim, H. Moskowitz, and M. Koksalan. 1996. Fuzzy versus statistical linear regression. European Journal of Operational Research 92 (1996), 417–434. DOI:https://doi.org/10.1016/0377-2217(94)00352-1Google ScholarGoogle ScholarCross RefCross Ref
  26. Vasileios Kitsikoudis, Mike Spiliotis, and Vlassios Hrissanthou. 2016. Fuzzy regression analysis for sediment incipient motion under turbulent flow conditions. Environmental Processes 3 (2016), 663–679. DOI:https://doi.org/10.1007/s40710-016-0154-2Google ScholarGoogle ScholarCross RefCross Ref
  27. Dilek İmren Koç and Mehmet Levent Koç. 2016. Fuzzy viscometric analysis of polymer-polymer miscibility based on fuzzy regression. Chemometrics and Intelligent Laboratory Systems 157 (2016), 58–66. DOI:https://doi.org/10.1016/j.chemolab.2016.06.019Google ScholarGoogle ScholarCross RefCross Ref
  28. H. Lee and H. Tanaka. 1999. Fuzzy approximations with non-symmetric fuzzy parameters in fuzzy regression analysis. Journal of Operations Research 42 (1999), 98–112. DOI:https://doi.org/10.15807/jorsj.42.98Google ScholarGoogle Scholar
  29. Junhong Li, Wenyi Zeng, Jianjun Xie, and Qian Yin. 2016. A new fuzzy regression model based on least absolute deviation. Engineering Applications of Artificial Intelligence 52 (2016), 54–64. DOI:https://doi.org/10.1016/j.engappai.2016.02.009Google ScholarGoogle ScholarDigital LibraryDigital Library
  30. Asun Lubiano and Sara de la Rosa de Saa. 2017. FuzzyStatTra: Statistical Methods for Trapezoidal Fuzzy Numbers. https://CRAN.R-project.org/package=FuzzyStatTra R package version 1.0.Google ScholarGoogle Scholar
  31. Renan Maestri, Leandro Rabello Monteiro, Rodrigo Fornel, Thales Renato Ochotorena de Freitas, and Bruce D. Patterson. 2018. Geometric morphometrics meets metacommunity ecology: Environment and lineage distribution affects spatial variation in shape. Ecography 41 (2018), 90–100. DOI:https://doi.org/10.1111/ecog.03001Google ScholarGoogle ScholarCross RefCross Ref
  32. Ioannis N. Markou, Dimitrios N. Christodoulou, and Basil K. Papadopoulos. 2015. Penetrability of microfine cement grouts: Experimental investigation and fuzzy regression modeling. Canadian Geotechnical Journal 52 (2015), 868–882. DOI:https://doi.org/10.1139/cgj-2013-0297Google ScholarGoogle ScholarCross RefCross Ref
  33. Natália Martínková, Stuart J. E. Baird, Vlastislav Káňa, and Jan Zima. 2020. Bat population recoveries give insight into clustering strategies during hibernation. Frontiers in Zoology 17 (2020), 26. DOI:https://doi.org/10.1186/s12983-020-00370-0Google ScholarGoogle ScholarCross RefCross Ref
  34. N. Martínková, J. Pikula, J. Zukal, V. Kovacova, H. Bandouchova, T. Bartonička, A. D. Botvinkin, J. Brichta, H. Dundarova, T. Kokurewicz, N. R. Irwin, P. Linhart, O. L. Orlov, V. Piacek, P. Škrabánek, M. P. Tiunov, and A. Zahradníková Jr. 2018. Hibernation temperature-dependent Pseudogymnoascus destructans infection intensity in Palearctic bats. Virulence 9 (2018), 1734–1750. DOI:https://doi.org/10.1080/21505594.2018.1548685Google ScholarGoogle ScholarCross RefCross Ref
  35. David Meyer and Kurt Hornik. 2009. Generalized and customizable sets in R. Journal of Statistical Software 31, 2 (2009), 1–27. DOI:https://doi.org/10.18637/jss.v031.i02Google ScholarGoogle ScholarCross RefCross Ref
  36. J. Mohammadi and M. Taheri. 2004. Pedomodels fitting with fuzzy least squares regression. Iranian Journal of Fuzzy Systems 1 (2004), 45–61. DOI:https://doi.org/10.22111/IJFS.2004.505Google ScholarGoogle Scholar
  37. M. Mosleh, M. Otadi, and S. Abbasbandy. 2011. Fuzzy polynomial regression with fuzzy neural networks. Applied Mathematical Modelling 35, 11 (2011), 5400–5412. DOI:https://doi.org/10.1016/j.apm.2011.04.039Google ScholarGoogle ScholarCross RefCross Ref
  38. M. Namdari, J. H. Yoon, A. Abadi, S. M. Taheri, and S. H. Choi. 2015. Fuzzy logistic regression with least absolute deviations estimators. Soft Computing 19, 4 (2015), 909–917. DOI:https://doi.org/10.1007/s00500-014-1418-2Google ScholarGoogle ScholarDigital LibraryDigital Library
  39. M. M. Nasrabadi, E. Nasrabadi, and A. R. Nasrabady. 2005. Fuzzy linear regression analysis: A multi-objective programming approach. Applied Mathematics and Computation 163 (2005), 245–251. DOI:https://doi.org/10.1016/j.amc.2004.02.008Google ScholarGoogle ScholarDigital LibraryDigital Library
  40. Roya Nikbakht and Abbas Bahrampour. 2017. Determining factors influencing survival of breast cancer by fuzzy logistic regression model. Journal of Research in Medical Sciences 22 (2017), 135. DOI:https://doi.org/10.4103/jrms.JRMS_405_17Google ScholarGoogle ScholarCross RefCross Ref
  41. Ertunga C. Özelkan and Lucien Duckstein. 2000. Multi-objective fuzzy regression: A general framework. Computers & Operations Research 27 (2000), 635–652. DOI:https://doi.org/10.1016/S0305-0548(99)00110-0Google ScholarGoogle ScholarDigital LibraryDigital Library
  42. Nang-Fei Pan, Tzu-Chieh Lin, and Nai-Hsin Pan. 2009. Estimating bridge performance based on a matrix-driven fuzzy linear regression model. Automation in Construction 18 (2009), 578–586. DOI:https://doi.org/10.1016/j.autcon.2008.12.005Google ScholarGoogle ScholarCross RefCross Ref
  43. A. M. Pashayev, R. A. Sadykhov, and S. B. Habibullayev. 2017. Modeling, reproduction, and mapping of geofields with and without measurement noise. Part 4. Spline, geostatistical, and fuzzy regression analysis techniques. Measurement Techniques 60 (2017), 432–442. DOI:https://doi.org/10.1007/s11018-017-1214-3Google ScholarGoogle ScholarCross RefCross Ref
  44. R Core Team. 2019. R: A Language and Environment for Statistical Computing. R Foundation for Statistical Computing, Vienna, Austria. https://www.R-project.org/.Google ScholarGoogle Scholar
  45. Lala Septem Riza, Christoph Bergmeir, Francisco Herrera, and José Manuel Benítez. 2015. frbs: Fuzzy rule-based systems for classification and regression in R. Journal of Statistical Software 65, 6 (2015), 1–30. http://www.jstatsoft.org/v65/i06/.Google ScholarGoogle ScholarCross RefCross Ref
  46. H. Romo, E. García-Barros, A. L. Márquez, J. C. Moreno, and R. Real. 2014. Effects of climate change on the distribution of ecologically interacting species: Butterflies and their main food plants in Spain. Ecography 37 (2014), 1063–1072. DOI:https://doi.org/10.1111/ecog.00706Google ScholarGoogle Scholar
  47. D. K. Sambariya and R. Prasad. 2017. Selection of membership functions based on fuzzy rules to design an efficient power system stabilizer. International Journal of Fuzzy Systems 19 (2017), 813–828. DOI:https://doi.org/10.1007/s40815-016-0197-6Google ScholarGoogle ScholarCross RefCross Ref
  48. M. A. Shafi and M. S. Rusiman. 2015. The use of fuzzy linear regression models for tumor size in colorectal cancer in hospital of Malaysia. Applied Mathematical Sciences 9 (2015), 2749–2759. DOI:https://doi.org/10.12988/ams.2015.5175Google ScholarGoogle ScholarCross RefCross Ref
  49. Karline Soetaert, Karel Van den Meersche, and Dick van Oevelen. 2009. limSolve: Solving Linear Inverse Models. https://CRAN.R-project.org/package=limSolve R package 1.5.1.Google ScholarGoogle Scholar
  50. So Young Sohn, Dong Ha Kim, and Jin Hee Yoon. 2016. Technology credit scoring model with fuzzy logistic regression. Applied Soft Computing 43 (2016), 150–158. DOI:https://doi.org/10.1016/j.asoc.2016.02.025Google ScholarGoogle ScholarDigital LibraryDigital Library
  51. H. Tanaka, I. Hayashi, and J. Watada. 1989. Possibilistic linear regression analysis for fuzzy data. European Journal of Operational Research 40 (1989), 389–396. DOI:https://doi.org/10.1016/0377-2217(89)90431-1Google ScholarGoogle ScholarCross RefCross Ref
  52. Y. Toyoura, J. Watada, M. Khalid, and R. Yusof. 2004. Formulation of linguistic regression model based on natural words. Soft Computing 8 (2004), 681–688. DOI:https://doi.org/10.1007/s00500-003-0326-7Google ScholarGoogle ScholarDigital LibraryDigital Library
  53. J. W. Tukey. 1977. Exploratory Data Analysis. Addison-Wesley Publishing Company, Reading, PA.Google ScholarGoogle Scholar
  54. Berwin A. Turlach and Andreas Weingessel. 2013. quadprog: Functions to Solve Quadratic Programming Problems. https://CRAN.R-project.org/package=quadprog R package version 1.5-5.Google ScholarGoogle Scholar
  55. Venkatesh Uddameri, E. Annette Hernandez, and Felipe Estrada. 2014. A multidimensional fuzzy least-squares regression approach for estimating hydraulic gradients in unconfined aquifer formations and its application to the Gulf Coast Aquifer in Goliad County, Texas. Environmental Earth Sciences 71 (2014), 2641–2651. DOI:https://doi.org/10.1007/s12665-013-2890-1Google ScholarGoogle ScholarCross RefCross Ref
  56. Michał K. Urbański and Janusz Waşowski. 2008. Fuzzy measurement theory. Measurement 41 (2008), 391–402. DOI:https://doi.org/10.1016/j.measurement.2007.02.006Google ScholarGoogle ScholarCross RefCross Ref
  57. P. Škrabánek and J. Marek. 2018. Models used in fuzzy linear regression. In 17th Conference on Applied Mathematics (Aplimat ’18). Slovak University of Technology in Bratislava, Bratislava, Slovakia, 955–964.Google ScholarGoogle Scholar
  58. N. Wang, W.-X. Zhang, and C.-L. Mei. 2007. Fuzzy nonparametric regression based on local linear smoothing technique. Information Sciences 177 (2007), 3882–3900. DOI:https://doi.org/10.1016/j.ins.2007.03.002Google ScholarGoogle ScholarDigital LibraryDigital Library
  59. Ronald R. Yager. 1982. Fuzzy prediction based on regression models. Information Sciences 26 (1982), 45–63. DOI:https://doi.org/10.1016/0020-0255(82)90043-3Google ScholarGoogle ScholarCross RefCross Ref
  60. Xin Yan and Xiao Gang Su. 2009. Linear Regression Analysis: Theory and Computing. World Scientific Publishing Co., Inc., River Edge, NJ.Google ScholarGoogle Scholar
  61. L. A. Zadeh. 1965. Fuzzy sets. Information and Control 8 (1965), 338–353.Google ScholarGoogle ScholarCross RefCross Ref
  62. Wenyi Zeng, Qilei Feng, and Junhong Li. 2017. Fuzzy least absolute linear regression. Applied Soft Computing 52 (2017), 1009–1019. DOI:https://doi.org/10.1016/j.asoc.2016.09.029Google ScholarGoogle ScholarCross RefCross Ref
  63. P. Zhou and K. C. C. Chan. 2018. Fuzzy feature extraction for multichannel EEG classification. IEEE Transactions on Cognitive and Developmental Systems 10 (2018), 267–279. DOI:https://doi.org/10.1109/TCDS.2016.2632130Google ScholarGoogle ScholarCross RefCross Ref
  64. Zahra Sadat Zolfaghari, Mohebbat Mohebbi, and Marzieh Najariyan. 2014. Application of fuzzy linear regression method for sensory evaluation of fried donut. Applied Soft Computing 22 (2014), 417–423. DOI:https://doi.org/10.1016/j.asoc.2014.03.010Google ScholarGoogle ScholarDigital LibraryDigital Library

Index Terms

  1. Algorithm 1017: fuzzyreg: An R Package for Fitting Fuzzy Regression Models

        Recommendations

        Comments

        Login options

        Check if you have access through your login credentials or your institution to get full access on this article.

        Sign in

        Full Access

        • Published in

          cover image ACM Transactions on Mathematical Software
          ACM Transactions on Mathematical Software  Volume 47, Issue 3
          September 2021
          251 pages
          ISSN:0098-3500
          EISSN:1557-7295
          DOI:10.1145/3472960
          Issue’s Table of Contents

          Copyright © 2021 ACM

          Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than ACM must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected]

          Publisher

          Association for Computing Machinery

          New York, NY, United States

          Publication History

          • Published: 26 June 2021
          • Accepted: 1 February 2021
          • Revised: 1 September 2020
          • Received: 1 August 2019
          Published in toms Volume 47, Issue 3

          Permissions

          Request permissions about this article.

          Request Permissions

          Check for updates

          Qualifiers

          • research-article
          • Research
          • Refereed

        PDF Format

        View or Download as a PDF file.

        PDF

        eReader

        View online with eReader.

        eReader

        HTML Format

        View this article in HTML Format .

        View HTML Format