Package 'FuzzyStatTra'

Title: Statistical Methods for Trapezoidal Fuzzy Numbers
Description: The aim of the package is to provide some basic functions for doing statistics with trapezoidal fuzzy numbers. In particular, the package contains several functions for simulating trapezoidal fuzzy numbers, as well as for calculating some central tendency measures (mean and two types of median), some scale measures (variance, ADD, MDD, Sn, Qn, Tn and some M-estimators) and one diversity index and one inequality index. Moreover, functions for calculating the 1-norm distance, the mid/spr distance and the (phi,theta)-wabl/ldev/rdev distance between fuzzy numbers are included, and a function to calculate the value phi-wabl given a sample of trapezoidal fuzzy numbers.
Authors: Asun Lubiano <[email protected]>, Sara de la Rosa de Saa <[email protected]>
Maintainer: Asun Lubiano <[email protected]>
License: GPL (>= 2)
Version: 1.0
Built: 2024-11-01 11:42:07 UTC
Source: CRAN

Help Index


Statistical Methods for Trapezoidal Fuzzy Numbers

Description

The aim of the package is to provide some basic functions for doing statistics with trapezoidal fuzzy numbers.

Details

Package: FuzzyStatTra
Type: Package
Version: 1.0
Date: 2016-02-07
License: GPL (>=2)

The aim of the package is to provide some basic functions for doing statistics with trapezoidal fuzzy numbers. In particular, the package contains several functions for simulating trapezoidal fuzzy numbers, as well as for calculating some central tendency measures (mean and two types of median), some scale measures (variance, ADD, MDD, Sn, Qn, Tn and some M-estimators) and one diversity index and one inequality index. Moreover, functions for calculating the 1-norm distance, the mid/spr distance and the (φ,θ)(\varphi,\theta)-wabl/ldev/rdev distance between fuzzy numbers are included, and a function to calculate the value φ\varphi-wabl given a sample of trapezoidal fuzzy numbers.

Author(s)

Asun Lubiano <[email protected]>, Sara de la Rosa de Saa <[email protected]>

Maintainer: Asun Lubiano <[email protected]>

References

[1] Blanco-Fernandez, A.; Casals, R.M.; Colubi, A.; Corral, N.; Garcia-Barzana, M.; Gil, M.A.; Gonzalez-Rodriguez, G.; Lopez, M.T.; Lubiano, M.A.; Montenegro, M.; Ramos-Guajardo, A.B.; de la Rosa de Saa, S.; Sinova, B.: Random fuzzy sets: A mathematical tool to develop statistical fuzzy data analysis, Iranian Journal on Fuzzy Systems 10(2), pp. 1-28 (2013)

[2] De la Rosa de Saa, S.; Gil, M.A.; Gonzalez-Rodriguez, G.; Lopez, M.T.; Lubiano M.A.: Fuzzy rating scale-based questionnaires and their statistical analysis, IEEE Trans. Fuzzy Syst. 23(1), pp. 111-126 (2015)

[3] De la Rosa de Saa, S.; Lubiano M.A.; Sinova, B.; Filzmoser, P.: Robust scale estimators for fuzzy data, Advances in Data Analysis and Classification, pp. 1-28 (2015)

[4] Diamond, P.; Kloeden, P.: Metric spaces of fuzzy sets, Fuzzy Sets Syst. 35, pp. 241-249 (1990)

[5] Gil, M.A.; Lubiano, M.A.; De la Rosa de Saa, S.; Sinova, B.: Analyzing data from a fuzzy rating scale-based questionnaire. A case study, Psicothema 27(2), pp. 182-191 (2015)

[6] Lubiano, M.A.; Gil, M.A.: f-Inequality indices for fuzzy random variables, in Statistical Modeling, Analysis and Management of Fuzzy Data (Bertoluzza, C., Gil, M.A., Ralescu, D.A., Eds.), Physica-Verlag, pp. 43-63 (2002)

[7] Lubiano, M.A.; De la Rosa de Saa, S.; Montenegro, M.; Sinova, B.; Gil, M.A.: Descriptive analysis of responses to items in questionnaires. Why not a fuzzy rating scale?, Information Sciences 360, pp. 131-148 (2016)

[8] Lubiano, M.A.; Montenegro, M.; Sinova, B.; De la Rosa de Saa, S.; Gil, M.A.: Hypothesis testing for means in connection with fuzzy rating scale-based data: algorithms and applications, European Journal of Operational Research 251, pp. 918-929 (2016)

[9] Sinova, B.; Gil, M.A.; Colubi, A.; Van Aelst, S.: The median of a random fuzzy number. The 1-norm distance approach, Fuzzy Sets Syst. 200, pp. 99-115 (2012)

[10] Sinova, B.; de la Rosa de Saa, S.; Gil, M.A.: A generalized L1-type metric between fuzzy numbers for an approach to central tendency of fuzzy data, Information Sciences 242, pp. 22-34 (2013)

[11] Sinova, B.; Gil, M.A.; Lopez, M.T.; Van Aelst, S.: A parameterized L2 metric between fuzzy numbers and its parameter interpretation, Fuzzy Sets and Systems 245, pp. 101-115 (2014)

[12] Sinova, B.; De la Rosa de Saa, S.; Lubiano, M.A.; Gil, M.A.: An overview on the statistical central tendency for fuzzy datasets, International Journal of Uncertainty, Fuzziness and Knowledge-Based Systems 23 (Suppl. 1), pp. 105-132 (2015)

[13] Sinova, B.; Gil, M.A.; Van Aelst, S.: M-estimates of location for the robust central tendency of fuzzy data, IEEE Transactions on Fuzzy Systems 24(4), pp. 945-956 (2016)

See Also

http://bellman.ciencias.uniovi.es/SMIRE/


Average Distance Deviation of a trapezoidal fuzzy sample with respect to a fuzzy number

Description

This function calculates the scale measure Average Distance Deviation (ADD) for a matrix of trapezoidal fuzzy numbers F with respect to a fuzzy number U. The employed metric in the calculation can be the 1-norm distance, the mid/spr distance or the (φ,θ)(\varphi,\theta)-wabl/ldev/rdev distance. The function first checks if the input matrix F is given in the correct form (tested by checkingTra) and also the input fuzzy number U (tested by checking or checkingTra).

Usage

ADD(F, U, type, a = 1, b = 1, theta = 1/3)

Arguments

F

matrix of dimension n x 4 containing n trapezoidal fuzzy numbers characterized by their four values inf0,inf1,sup1,sup0. The function implicitly checks if the matrix is in the correct form (tested by checkingTra).

U

can be a matrix of dimension 1 x 4 (trapezoidal fuzzy number) or an array of dimension nl x 3 x 1 (general fuzzy number), where nl is the number of considered α\alpha-levels and 3 the number of columns of the array: the first column will be the α\alpha-levels, the second one their infimum values and the third one their supremum values. The function implicitly checks if the fuzzy number U is in the correct form (tested by checking if U is an array and tested by checkingTra if U is a matrix).

type

number 1, 2 or 3: if type==1, the 1-norm distance will be considered in the calculation of the measure ADD. If type==2, the mid/spr distance will be considered. By contrast, if type==3, the (φ,θ)(\varphi,\theta)-wabl/ldev/rdev distance will be used.

a

number >0, by default a=1. It is the first parameter of a beta distribution which corresponds to a weighting measure on [0,1] in the mid/spr distance or in the (φ,θ)(\varphi,\theta)-wabl/ldev/rdev distance.

b

number >0, by default b=1. It is the second parameter of a beta distribution which corresponds to a weighting measure on [0,1] in the mid/spr distance or in the (φ,θ)(\varphi,\theta)-wabl/ldev/rdev distance.

theta

number >0, by default theta=1/3. It is the weight of the spread in the mid/spr distance and the weight of the ldev and rdev in the (φ,θ)(\varphi,\theta)-wabl/ldev/rdev distance.

Details

See examples

Value

The function returns the scale measure ADD, which is a real number.

Note

In case you find (almost surely existing) bugs or have recommendations for improving the functions comments are welcome to the above mentioned mail addresses.

Author(s)

Asun Lubiano <[email protected]>, Sara de la Rosa de Saa <[email protected]>

References

[1] De la Rosa de Saa, S.; Lubiano M.A.; Sinova, B.; Filzmoser, P.: Robust scale estimators for fuzzy data, Advances in Data Analysis and Classification, pp. 1-28 (2015)

See Also

checkingTra, checking, TransfTra, Rho1Tra, Rho1, DthetaphiTra, Dthetaphi, DwablphiTra, Dwablphi

Examples

# Example 1:
F=SimulCASE1(10)
U=Mean(F)
ADD(F,U,1)

# Example 2:
F=SimulCASE1(100)
U=Median1norm(F)
ADD(F,U,2,2,1,1)

# Example 3:
F=SimulCASE1(100)
U=matrix(c(1,2,3,2),nrow=1)
ADD(F,U,1)

# Example 4:
F=matrix(1:4,nrow=2)
U=matrix(1:4,nrow=1)
ADD(F,U,3,1,1,1)

Checking correct data format (as array)

Description

The function checks if the input data are given in the correct form of an array of dimension nl x 3 x n containing n fuzzy numbers characterized by means of nl α\alpha-levels each. The following conditions have to be fulfilled: (1) the number of columns of the array must be 3 (the first column will be the α\alpha-levels, the second one their infimum values and the third one their supremum values), (2) all the fuzzy numbers must have the same column of α\alpha-levels, (3) the minimum α\alpha-level should be 0 y the maximum 1, (4) the α\alpha-levels have to increase from 0 to 1, (5) the infimum values have to be non-decreasing, (6) the supremum values have to be non-creasing, (7) the infimum value has to be smaller or equal than the supremum value for each α\alpha-level. This function is used internally in some of the other functions to do a preliminary checking if the input data are in the correct form.

Usage

checking(R)

Arguments

R

can be any array.

Details

See examples

Value

The function returns the value 1 if the input fulfills all conditions, if not, the value 0 is returned.

Note

In case you find (almost surely existing) bugs or have recommendations for improving the functions comments are welcome to the above mentioned mail addresses.

Author(s)

Asun Lubiano <[email protected]>, Sara de la Rosa de Saa <[email protected]>

See Also

checkingTra, filterNA

Examples

# Example 1:
F=SimulCASE1(10)
R=TransfTra(F)
c=checking(R)
c

# Example 2:
R=array(c(1:10),dim=c(2,1,2))
c=checking(R)
c

# Example 3:
R=array(c(1:10),dim=c(2,3,2))
c=checking(R)
c

# Example 4:
R=array(c(1,2,3,4,5,6,1,2,4,5,6,7),dim=c(2,3,2))
c=checking(R)
c

# Example 5:
R=array(c(0,0,1,2,3,4,5,0,1,0,0,1,7,8,9,19,30,3),dim=c(3,3,2))
c=checking(R)
c

# Example 6:
R=array(c(0,0.5,1,2,3,4,5,0,1,0,0.5,1,7,8,7,19,30,3),dim=c(3,3,2))
c=checking(R)
c

# Example 7:
R=array(c(0,0.5,1,2,3,4,5,0,1,0,0.5,1,7,8,9,19,30,3),dim=c(3,3,2))
c=checking(R)
c

# Example 8:
R=array(c(0,0.5,1,2,3,4,6,5,4,0,0.5,1,7,8,9,19,10,2),dim=c(3,3,2))
c=checking(R)
c

Checking correct data format (as matrix)

Description

The function checks if the input data are given in the correct form of a matrix of dimension n x 4 containing n trapezoidal fuzzy numbers characterized by their four values inf0,inf1,sup1,sup0 each. The following conditions have to be fulfilled: (1) the number of columns of the matrix must be 4 (the four values characterizing each trapezoidal fuzzy number), (2) the four values of each trapezoidal number have to be non-decreasing. This function is used internally in almost all the other functions to do a preliminary checking if the input data are in the correct form.

Usage

checkingTra(F)

Arguments

F

can be any matrix.

Details

See examples

Value

The function returns the value 1 if the input fulfills all conditions, if not, the value 0 is returned.

Note

In case you find (almost surely existing) bugs or have recommendations for improving the functions comments are welcome to the above mentioned mail addresses.

Author(s)

Asun Lubiano <[email protected]>, Sara de la Rosa de Saa <[email protected]>

See Also

checking, filterNA

Examples

# Example 1:
F=matrix(c(1,2,3,4),nrow=1)
c=checkingTra(F)
c

# Example 2:
F=matrix(c(1,2,3,4),nrow=2)
c=checkingTra(F)
c

# Example 3:
F=matrix(c(1,2,1,4),nrow=1)
c=checkingTra(F)
c

Mid/spr distance between fuzzy numbers

Description

This function calculates the mid/spr distance between the fuzzy numbers contained in two arrays, which should be given in the desired format. For this, the function first checks if the input arrays R and S are in the correct form (tested by checking) and if the α\alpha-levels of all fuzzy numbers coincide.

Usage

Dthetaphi(R, S, a = 1, b = 1, theta = 1/3)

Arguments

R

array of dimension nl x 3 x r containing r fuzzy numbers characterized by means of nl α\alpha-levels each. The function first calls checking to check if the array R has the correct format. Moreover, the α\alpha-levels of the array R should coincide with the ones of the array S (the function checks this condition).

S

array of dimension nl x 3 x s containing s fuzzy numbers characterized by means of nl α\alpha-levels each. The function first calls checking to check if the array S has the correct format. Moreover, the α\alpha-levels of the array S should coincide with the ones of the array R (the function checks this condition).

a

number >0, by default a=1. It is the first parameter of a beta distribution which corresponds to a weighting measure on [0,1].

b

number >0, by default b=1. It is the second parameter of a beta distribution which corresponds to a weighting measure on [0,1].

theta

number >0, by default theta=1/3. It is the weight of the spread in the mid/spr distance.

Details

See examples

Value

The function returns a matrix of dimension r x s containing the mid/spr distances between the fuzzy numbers of the array R and the fuzzy numbers of the array S .

Note

In case you find (almost surely existing) bugs or have recommendations for improving the functions comments are welcome to the above mentioned mail addresses.

Author(s)

Asun Lubiano <[email protected]>, Sara de la Rosa de Saa <[email protected]>

References

[1] Blanco-Fernandez, A.; Casals, R.M.; Colubi, A.; Corral, N.; Garcia-Barzana, M.; Gil, M.A.; Gonzalez-Rodriguez, G.; Lopez, M.T.; Lubiano, M.A.; Montenegro, M.; Ramos-Guajardo, A.B.; de la Rosa de Saa, S.; Sinova, B.: Random fuzzy sets: A mathematical tool to develop statistical fuzzy data analysis, Iranian Journal on Fuzzy Systems 10(2), pp. 1-28 (2013)

See Also

checking, DthetaphiTra

Examples

# Example 1:
F=SimulCASE1(10)
S=SimulCASE1(20)
F=TransfTra(F)
S=TransfTra(S)
Dthetaphi(F,S,1,5,1)

# Example 2:
F=SimulCASE1(10)
S=SimulCASE1(10)
Dthetaphi(F,S,2,1,1/3)

# Example 3:
F=SimulCASE1(10)
S=SimulCASE1(10)
F=TransfTra(F)
S=TransfTra(S,50)
Dthetaphi(F,S,2,1,1)

Mid/spr distance between trapezoidal fuzzy numbers

Description

This function calculates the mid/spr distance between the trapezoidal fuzzy numbers contained in two matrixes, which should be given in the desired format. For this, the function first checks if the input matrixes R and S are in the correct form (tested by checkingTra).

Usage

DthetaphiTra(R, S, a = 1, b = 1, theta = 1/3)

Arguments

R

matrix of dimension r x 4 containing r trapezoidal fuzzy numbers characterized by their four values inf0,inf1,sup1,sup0. The function first calls checkingTra to check if the matrix R has the correct format.

S

matrix of dimension s x 4 containing s trapezoidal fuzzy numbers characterized by their four values inf0,inf1,sup1,sup0. The function first calls checkingTra to check if the matrix S has the correct format.

a

number >0, by default a=1. It is the first parameter of a beta distribution which corresponds to a weighting measure on [0,1].

b

number >0, by default b=1. It is the second parameter of a beta distribution which corresponds to a weighting measure on [0,1].

theta

number >0, by default theta=1/3. It is the weight of the spread in the mid/spr distance.

Details

See examples

Value

The function returns a matrix of dimension r x s containing the mid/spr distances between the trapezoidal fuzzy numbers of the matrix R and the trapezoidal fuzzy numbers of the matrix S.

Note

In case you find (almost surely existing) bugs or have recommendations for improving the functions comments are welcome to the above mentioned mail addresses.

Author(s)

Asun Lubiano <[email protected]>, Sara de la Rosa de Saa <[email protected]>

References

[1] Lubiano, M.A.; Montenegro, M.; Sinova, B.; De la Rosa de Saa, S.; Gil, M.A.: Hypothesis testing for means in connection with fuzzy rating scale-based data: algorithms and applications, European Journal of Operational Research 251, pp. 918-929 (2016)

See Also

checkingTra, Dthetaphi

Examples

# Example 1:
F=SimulCASE1(6)
S=SimulCASE1(8)
DthetaphiTra(F,S)

# Example 2:
F=matrix(c(1,1,0,2,3,4,5,6),nrow=2)
S=SimulCASE1(8)
DthetaphiTra(F,S,1,1,1)

(φ,θ)(\varphi,\theta)-wabl/ldev/rdev distance between fuzzy numbers

Description

This function calculates the (φ,θ)(\varphi,\theta)-wabl/ldev/rdev distance between the fuzzy numbers contained in two arrays, which should be given in the desired format. For this, the function first checks if the input arrays R and S are in the correct form (tested by checking) and if the α\alpha-levels of all fuzzy numbers coincide.

Usage

Dwablphi(R, S, a = 1, b = 1, theta = 1)

Arguments

R

array of dimension nl x 3 x r containing r fuzzy numbers characterized by means of nl α\alpha-levels each. The function first calls checking to check if the array R has the correct format. Moreover, the α\alpha-levels of the array R should coincide with the ones of the array S (the function checks this condition).

S

array of dimension nl x 3 x s containing s fuzzy numbers characterized by means of nl α\alpha-levels each. The function first calls checking to check if the array S has the correct format. Moreover, the α\alpha-levels of the array S should coincide with the ones of the array R (the function checks this condition).

a

number >0, by default a=1. It is the first parameter of a beta distribution which corresponds to a weighting measure on [0,1].

b

number >0, by default b=1. It is the second parameter of a beta distribution which corresponds to a weighting measure on [0,1].

theta

number >0, by default theta=1. It is the weight of the ldev and rdev in the (φ,θ)(\varphi,\theta)-wabl/ldev/rdev distance.

Details

See examples

Value

The function returns a matrix of dimension r x s containing the (φ,θ)(\varphi,\theta)-wabl/ldev/rdev distances between the fuzzy numbers of the array R and the fuzzy numbers of the array S .

Note

In case you find (almost surely existing) bugs or have recommendations for improving the functions comments are welcome to the above mentioned mail addresses.

Author(s)

Asun Lubiano <[email protected]>, Sara de la Rosa de Saa <[email protected]>

References

[1] Sinova, B.; de la Rosa de Saa, S.; Gil, M.A.: A generalized L1-type metric between fuzzy numbers for an approach to central tendency of fuzzy data, Information Sciences 242, pp. 22-34 (2013)

[2] Sinova, B.; Gil, M.A.; Van Aelst, S.: M-estimates of location for the robust central tendency of fuzzy data, IEEE Transactions on Fuzzy Systems 24(4), pp. 945-956 (2016)

See Also

checking, DwablphiTra, Wablphi

Examples

# Example 1:
F=SimulCASE1(3)
S=SimulCASE1(4)
F=TransfTra(F)
S=TransfTra(S)
Dwablphi(F,S,2,1,1)

# Example 2:
F=SimulCASE1(10)
S=SimulCASE1(10)
Dwablphi(F,S)

# Example 3:
F=SimulCASE1(10)
S=SimulCASE1(10)
F=TransfTra(F)
S=TransfTra(S,50)
Dwablphi(F,S,2,1,1)

(φ,θ)(\varphi,\theta)-wabl/ldev/rdev distance between trapezoidal fuzzy numbers

Description

This function calculates the (φ,θ)(\varphi,\theta)-wabl/ldev/rdev distance between the trapezoidal fuzzy numbers contained in two matrixes, which should be given in the desired format. For this, the function first checks if the input matrixes R and S are in the correct form (tested by checkingTra).

Usage

DwablphiTra(R, S, a = 1, b = 1, theta = 1)

Arguments

R

matrix of dimension r x 4 containing r trapezoidal fuzzy numbers characterized by their four values inf0,inf1,sup1,sup0. The function first calls checkingTra to check if the matrix R has the correct format.

S

matrix of dimension s x 4 containing s trapezoidal fuzzy numbers characterized by their four values inf0,inf1,sup1,sup0. The function first calls checkingTra to check if the matrix S has the correct format.

a

number >0, by default a=1. It is the first parameter of a beta distribution which corresponds to a weighting measure on [0,1].

b

number >0, by default b=1. It is the second parameter of a beta distribution which corresponds to a weighting measure on [0,1].

theta

number >0, by default theta=1. It is the weight of the ldev and rdev in the (φ,θ)(\varphi,\theta)-wabl/ldev/rdev distance.

Details

See examples

Value

The function returns a matrix of dimension r x s containing the (φ,θ)(\varphi,\theta)-wabl/ldev/rdev distances between the trapezoidal fuzzy numbers of the matrix R and the trapezoidal fuzzy numbers of the matrix S.

Note

In case you find (almost surely existing) bugs or have recommendations for improving the functions comments are welcome to the above mentioned mail addresses.

Author(s)

Asun Lubiano <[email protected]>, Sara de la Rosa de Saa <[email protected]>

References

[1] Sinova, B.; de la Rosa de Saa, S.; Gil, M.A.: A generalized L1-type metric between fuzzy numbers for an approach to central tendency of fuzzy data, Information Sciences 242, pp. 22-34 (2013)

[2] Sinova, B.; Gil, M.A.; Van Aelst, S.: M-estimates of location for the robust central tendency of fuzzy data, IEEE Transactions on Fuzzy Systems 24(4), pp. 945-956 (2016)

See Also

checkingTra, Dwablphi, Wablphi

Examples

# Example 1:
F=SimulCASE1(10)
S=SimulCASE1(20)
DwablphiTra(F,S,5,1,1)


# Example 2:
F=matrix(c(1,1,0,2,3,4,5,6),nrow=2)
S=SimulCASE1(8)
DwablphiTra(F,S)

Deleting missing values

Description

Given any matrix, this function deletes those rows with missing values.

Usage

filterNA(F)

Arguments

F

can be any matrix.

Details

See examples

Value

The function returns a list with two components: the first one is a matrix identical to the input matrix F but without the rows containing missing values, and the second component is the number of rows of the input matrix without missing values.

Note

In case you find (almost surely existing) bugs or have recommendations for improving the functions comments are welcome to the above mentioned mail addresses.

Author(s)

Asun Lubiano <[email protected]>, Sara de la Rosa de Saa <[email protected]>

See Also

checkingTra, checking

Examples

# Example 1:
F=matrix(c(1,2,3,NA,5,4,7,2),nrow=2)
filterNA(F)

# Example 2:
F=matrix(c(1,2,3,NA,5,4,7,2,1,2,3,4),nrow=3)
filterNA(F)

# Example 3:
data(M2)
filterNA(M2)

Gini-Simpson diversity index of a trapezoidal fuzzy sample

Description

This function calculates the Gini-Simpson diversity index for a sample of trapezoidal fuzzy numbers contained in a matrix F. The function first checks if the input matrix F is given in the correct form (tested by checkingTra).

Usage

GSI(F)

Arguments

F

matrix of dimension n x 4 containing n trapezoidal fuzzy numbers characterized by their four values inf0,inf1,sup1,sup0. The function implicitly checks if the matrix is in the correct form (tested by checkingTra).

Details

See examples

Value

The function returns the Gini-Simpson diversity index, which is a real number.

Note

In case you find (almost surely existing) bugs or have recommendations for improving the functions comments are welcome to the above mentioned mail addresses.

Author(s)

Asun Lubiano <[email protected]>, Sara de la Rosa de Saa <[email protected]>

References

[1] De la Rosa de Saa, S.; Gil, M.A.; Gonzalez-Rodriguez, G.; Lopez, M.T.; Lubiano M.A.: Fuzzy rating scale-based questionnaires and their statistical analysis, IEEE Trans. Fuzzy Syst. 23(1), pp. 111-126 (2015)

See Also

checkingTra

Examples

# Example 1:
F=SimulCASE1(50)
GSI(F)

# Example 2:
F=matrix(c(1,0,2,3),nrow=1)
GSI(F)

Hyperbolic inequality index of a trapezoidal positive fuzzy sample

Description

This function calculates the hyperbolic inequality index for a sample of trapezoidal positive fuzzy numbers contained in a matrix F. The function first checks if the input matrix F is given in the correct form (tested by checkingTra).

Usage

HyperI(F, c = 0)

Arguments

F

matrix of dimension n x 4 containing n trapezoidal positive fuzzy numbers characterized by their four values inf0,inf1,sup1,sup0. The function implicitly checks if the matrix is in the correct form (tested by checkingTra).

c

number in [0,0.5]. The c*100% trimmed mean will be used in the calculation of the hyperbolic inequality index.

Details

See examples

Value

The function returns the hyperbolic inequality index, which is a real number.

Note

In case you find (almost surely existing) bugs or have recommendations for improving the functions comments are welcome to the above mentioned mail addresses.

Author(s)

Asun Lubiano <[email protected]>, Sara de la Rosa de Saa <[email protected]>

References

[1] Lubiano, M.A.; Gil, M.A.: f-Inequality indices for fuzzy random variables, in Statistical Modeling, Analysis and Management of Fuzzy Data (Bertoluzza, C., Gil, M.A., Ralescu, D.A., Eds.), Physica-Verlag, pp. 43-63 (2002)

[2] De la Rosa de Saa, S.; Gil, M.A.; Gonzalez-Rodriguez, G.; Lopez, M.T.; Lubiano M.A.: Fuzzy rating scale-based questionnaires and their statistical analysis, IEEE Trans. Fuzzy Syst. 23(1), pp. 111-126 (2015)

See Also

checkingTra

Examples

# Example 1:
F=SimulFRSTra(100,6,0.05,0.35,0.6,2,1)
HyperI(F)

# Example 2:
F=SimulCASE2(10)
HyperI(F,0.5)

M-estimator of scale of a trapezoidal fuzzy sample

Description

This function calculates the M-estimator of scale with loss function given in M for a matrix of trapezoidal fuzzy numbers F. For computing the M-estimator, a method called “iterative reweighting” is used. The employed metric in the M-equation can be the 1-norm distance, the mid/spr distance or the (φ,θ)(\varphi,\theta)-wabl/ldev/rdev distance. The function first checks if the input matrix F is given in the correct form (tested by checkingTra).

Usage

M.estimate(F, M, est_initial, delta, epsilon, type, a = 1, b = 1, theta = 1/3)

Arguments

F

matrix of dimension n x 4 containing n trapezoidal fuzzy numbers characterized by their four values inf0,inf1,sup1,sup0. The function implicitly checks if the matrix is in the correct form (tested by checkingTra).

M

name of the loss function. It can be “Huber”, “Tukey” or “Cauchy”.

est_initial

initial scale estimate.

delta

number in (0,1). It is present in the M-equation.

epsilon

number >0. It is the tolerance allowed in the algorithm.

type

number 1, 2 or 3: if type==1, the 1-norm distance will be considered in the calculation of the M-estimator. If type==2, the mid/spr distance will be considered. By contrast, if type==3, the (φ,θ)(\varphi,\theta)-wabl/ldev/rdev distance will be used.

a

number >0, by default a=1. It is the first parameter of a beta distribution which corresponds to a weighting measure on [0,1] in the mid/spr distance or in the (φ,θ)(\varphi,\theta)-wabl/ldev/rdev distance.

b

number >0, by default b=1. It is the second parameter of a beta distribution which corresponds to a weighting measure on [0,1] in the mid/spr distance or in the (φ,θ)(\varphi,\theta)-wabl/ldev/rdev distance.

theta

number >0, by default theta=1/3. It is the weight of the spread in the mid/spr distance and the weight of the ldev and rdev in the (φ,θ)(\varphi,\theta)-wabl/ldev/rdev distance.

Details

See examples

Value

The function returns the value of the M-estimator of scale, which is a real number.

Note

In case you find (almost surely existing) bugs or have recommendations for improving the functions comments are welcome to the above mentioned mail addresses.

Author(s)

Asun Lubiano <[email protected]>, Sara de la Rosa de Saa <[email protected]>

See Also

checkingTra, Rho1Tra, DthetaphiTra, DwablphiTra

Examples

# Example 1:
F=SimulCASE1(100)
U=Median1norm(F)
est_initial=MDD(F,U,1)
delta=0.5
epsilon=10^(-5)
M.estimate(F,"Huber",est_initial,delta,epsilon,1)

M1 dataset

Description

M1 is a matrix of dimension 69 x 4 containing 69 trapezoidal fuzzy rating responses, each of which is characterized by its four values inf0,inf1,sup1,sup0. The data correspond to the well-known questionnaire TIMSS-PIRLS2011. This questionnaire was adapted to allow a double-type response, namely, the original Likert and a fuzzy rating scale-based (to simplify, trapezoidal). The questionnaire was conducted on 69 fourth grade students from Colegio San Ignacio (Oviedo-Asturias, Spain). Trapezoidal fuzzy rating responses to the Question M1 "I like mathematics" are collected in this dataset.

Usage

data("M1")

Format

A matrix of dimension 69 x 4 containing 69 trapezoidal fuzzy rating responses, each of which is characterized by its four values inf0,inf1,sup1,sup0.

Details

See examples

Source

The complete dataset can be found in http://bellman.ciencias.uniovi.es/SMIRE/FuzzyRatingScaleQuestionnaire-SanIgnacio.html

References

[1] Gil, M.A.; Lubiano, M.A.; De la Rosa de Saa, S.; Sinova, B.: Analyzing data from a fuzzy rating scale-based questionnaire. A case study, Psicothema 27(2), pp. 182-191 (2015)

[2] Lubiano, M.A.; De la Rosa de Saa, S.; Montenegro, M.; Sinova, B.; Gil, M.A.: Descriptive analysis of responses to items in questionnaires. Why not a fuzzy rating scale?, Information Sciences 360, pp. 131-148 (2016)

[3] Lubiano, M.A.; Montenegro, M.; Sinova, B.; De la Rosa de Saa, S.; Gil, M.A.: Hypothesis testing for means in connection with fuzzy rating scale-based data: algorithms and applications, European Journal of Operational Research 251, pp. 918-929 (2016)

Examples

data(M1)
filterNA(M1)
F=filterNA(M1)[[1]]
Medianwabl(F)

M2 dataset

Description

M2 is a matrix of dimension 69 x 4 containing 69 trapezoidal fuzzy rating responses, each of which is characterized by its four values inf0,inf1,sup1,sup0. The data correspond to the well-known questionnaire TIMSS-PIRLS2011. This questionnaire was adapted to allow a double-type response, namely, the original Likert and a fuzzy rating scale-based (to simplify, trapezoidal). The questionnaire was conducted on 69 fourth grade students from Colegio San Ignacio (Oviedo-Asturias, Spain). Trapezoidal fuzzy rating responses to the Question M2 "My teacher is easy to understand" are collected in this dataset.

Usage

data("M2")

Format

A matrix of dimension 69 x 4 containing 69 trapezoidal fuzzy rating responses, each of which is characterized by its four values inf0,inf1,sup1,sup0.

Details

See examples

Source

The complete dataset can be found in http://bellman.ciencias.uniovi.es/SMIRE/FuzzyRatingScaleQuestionnaire-SanIgnacio.html

References

[1] Gil, M.A.; Lubiano, M.A.; De la Rosa de Saa, S.; Sinova, B.: Analyzing data from a fuzzy rating scale-based questionnaire. A case study, Psicothema 27(2), pp. 182-191 (2015)

[2] Lubiano, M.A.; De la Rosa de Saa, S.; Montenegro, M.; Sinova, B.; Gil, M.A.: Descriptive analysis of responses to items in questionnaires. Why not a fuzzy rating scale?, Information Sciences 360, pp. 131-148 (2016)

[3] Lubiano, M.A.; Montenegro, M.; Sinova, B.; De la Rosa de Saa, S.; Gil, M.A.: Hypothesis testing for means in connection with fuzzy rating scale-based data: algorithms and applications, European Journal of Operational Research 251, pp. 918-929 (2016)

Examples

data(M2)
filterNA(M2)
F=filterNA(M2)[[1]]
Mean(F)

M3 dataset

Description

M3 is a matrix of dimension 69 x 4 containing 69 trapezoidal fuzzy rating responses, each of which is characterized by its four values inf0,inf1,sup1,sup0. The data correspond to the well-known questionnaire TIMSS-PIRLS2011. This questionnaire was adapted to allow a double-type response, namely, the original Likert and a fuzzy rating scale-based (to simplify, trapezoidal). The questionnaire was conducted on 69 fourth grade students from Colegio San Ignacio (Oviedo-Asturias, Spain). Trapezoidal fuzzy rating responses to the Question M3 "Mathematics is harder for me than any other subject" are collected in this dataset.

Usage

data("M3")

Format

A matrix of dimension 69 x 4 containing 69 trapezoidal fuzzy rating responses, each of which is characterized by its four values inf0,inf1,sup1,sup0.

Details

See examples

Source

The complete dataset can be found in http://bellman.ciencias.uniovi.es/SMIRE/FuzzyRatingScaleQuestionnaire-SanIgnacio.html

References

[1] Gil, M.A.; Lubiano, M.A.; De la Rosa de Saa, S.; Sinova, B.: Analyzing data from a fuzzy rating scale-based questionnaire. A case study, Psicothema 27(2), pp. 182-191 (2015)

[2] Lubiano, M.A.; De la Rosa de Saa, S.; Montenegro, M.; Sinova, B.; Gil, M.A.: Descriptive analysis of responses to items in questionnaires. Why not a fuzzy rating scale?, Information Sciences 360, pp. 131-148 (2016)

[3] Lubiano, M.A.; Montenegro, M.; Sinova, B.; De la Rosa de Saa, S.; Gil, M.A.: Hypothesis testing for means in connection with fuzzy rating scale-based data: algorithms and applications, European Journal of Operational Research 251, pp. 918-929 (2016)

Examples

data(M3)
filterNA(M3)
F=filterNA(M3)[[1]]
Median1norm(F)

Median Distance Deviation of a trapezoidal fuzzy sample with respect to a fuzzy number

Description

This function calculates the scale measure Median Distance Deviation (MDD) for a matrix of trapezoidal fuzzy numbers F with respect to a fuzzy number U. The employed metric in the calculation can be the 1-norm distance, the mid/spr distance or the (φ,θ)(\varphi,\theta)-wabl/ldev/rdev distance. The function first checks if the input matrix F is given in the correct form (tested by checkingTra) and also the input fuzzy number U (tested by checking or checkingTra).

Usage

MDD(F, U, type, a = 1, b = 1, theta = 1/3)

Arguments

F

matrix of dimension n x 4 containing n trapezoidal fuzzy numbers characterized by their four values inf0,inf1,sup1,sup0. The function implicitly checks if the matrix is in the correct form (tested by checkingTra).

U

can be a matrix of dimension 1 x 4 (trapezoidal fuzzy number) or an array of dimension nl x 3 x 1 (general fuzzy number), where nl is the number of considered α\alpha-levels and 3 the number of columns of the array: the first column will be the α\alpha-levels, the second one their infimum values and the third one their supremum values. The function implicitly checks if the fuzzy number U is in the correct form (tested by checking if U is an array and tested by checkingTra if U is a matrix).

type

number 1, 2 or 3: if type==1, the 1-norm distance will be considered in the calculation of the measure MDD. If type==2, the mid/spr distance will be considered. By contrast, if type==3, the (φ,θ)(\varphi,\theta)-wabl/ldev/rdev distance will be used.

a

number >0, by default a=1. It is the first parameter of a beta distribution which corresponds to a weighting measure on [0,1] in the mid/spr distance or in the (φ,θ)(\varphi,\theta)-wabl/ldev/rdev distance.

b

number >0, by default b=1. It is the second parameter of a beta distribution which corresponds to a weighting measure on [0,1] in the mid/spr distance or in the (φ,θ)(\varphi,\theta)-wabl/ldev/rdev distance.

theta

number >0, by default theta=1/3. It is the weight of the spread in the mid/spr distance and the weight of the ldev and rdev in the (φ,θ)(\varphi,\theta)-wabl/ldev/rdev distance.

Details

See examples

Value

The function returns the scale measure MDD, which is a real number.

Note

In case you find (almost surely existing) bugs or have recommendations for improving the functions comments are welcome to the above mentioned mail addresses.

Author(s)

Asun Lubiano <[email protected]>, Sara de la Rosa de Saa <[email protected]>

References

[1] De la Rosa de Saa, S.; Lubiano M.A.; Sinova, B.; Filzmoser, P.: Robust scale estimators for fuzzy data, Advances in Data Analysis and Classification, pp. 1-28 (2015)

See Also

checkingTra, checking, TransfTra, Rho1Tra, Rho1, DthetaphiTra, Dthetaphi, DwablphiTra, Dwablphi

Examples

# Example 1:
F=SimulCASE3(10)
U=Mean(F)
MDD(F,U,3,1,2,1)

# Example 2:
F=SimulCASE2(10)
U=Median1norm(F)
MDD(F,U,2)

# Example 3:
F=SimulCASE1(100)
U=matrix(c(1,2,3,2),nrow=1)
MDD(F,U,1)

# Example 4:
F=SimulCASE1(100)
U=array(1:60,dim=c(10,2,3))
MDD(F,U,2,1,2,1)

Mean of a trapezoidal fuzzy sample

Description

Given a sample of trapezoidal fuzzy numbers contained in a matrix F, the function calculates the Aumann-type mean of these numbers (which is a trapezoidal fuzzy number too). The function first checks if the input matrix F is given in the correct form (tested by checkingTra).

Usage

Mean(F)

Arguments

F

matrix of dimension n x 4 containing n trapezoidal fuzzy numbers characterized by their four values inf0,inf1,sup1,sup0. The function implicitly checks if the matrix is in the correct form (tested by checkingTra).

Details

See examples

Value

The function returns the Aumann-type mean, given as a matrix of dimension 1 x 4.

Note

In case you find (almost surely existing) bugs or have recommendations for improving the functions comments are welcome to the above mentioned mail addresses.

Author(s)

Asun Lubiano <[email protected]>, Sara de la Rosa de Saa <[email protected]>

References

[1] Sinova, B.; De la Rosa de Saa, S.; Lubiano, M.A.; Gil, M.A.: An overview on the statistical central tendency for fuzzy datasets, International Journal of Uncertainty, Fuzziness and Knowledge-Based Systems 23 (Suppl. 1), pp. 105-132 (2015)

See Also

checkingTra

Examples

# Example 1:
F=SimulCASE1(100)
Mean(F)

# Example 2:
F=matrix(c(1,0,2,3),nrow=1)
Mean(F)

# Example 3:
F=matrix(c(1,0,2,3),nrow=2)
Mean(F)

1-norm median of a trapezoidal fuzzy sample

Description

Given a sample of trapezoidal fuzzy numbers contained in a matrix F, the function calculates the 1-norm median of these numbers, characterized by means of nl equidistant α\alpha-levels (by default nl=101), including always the 0 and 1 levels, with their infimum and supremum values. The function first checks if the input matrix F is given in the correct form (tested by checkingTra).

Usage

Median1norm(F, nl = 101)

Arguments

F

matrix of dimension n x 4 containing n trapezoidal fuzzy numbers characterized by their four values inf0,inf1,sup1,sup0. The function implicitly checks if the matrix is in the correct form (tested by checkingTra).

nl

positive integer, by default nl=101. It indicates the number of desired α\alpha-levels for characterizing the 1-norm median.

Details

See examples

Value

The function returns the 1-norm median, given by an array of dimension nl x 3 x 1 where nl is the number of considered α\alpha-levels and 3 the number of columns of the array: the first column will be the α\alpha-levels, the second one their infimum values and the third one their supremum values.

Note

In case you find (almost surely existing) bugs or have recommendations for improving the functions comments are welcome to the above mentioned mail addresses.

Author(s)

Asun Lubiano <[email protected]>, Sara de la Rosa de Saa <[email protected]>

References

[1] Sinova, B.; Gil, M.A.; Colubi, A.; Van Aelst, S.: The median of a random fuzzy number. The 1-norm distance approach, Fuzzy Sets Syst. 200, pp. 99-115 (2012)

See Also

checkingTra, TransfTra, Medianwabl

Examples

# Example 1:
F=SimulCASE1(10)
Median1norm(F,200)

# Example 2:
F=matrix(c(1,0,2,3),nrow=1)
Median1norm(F)

φ\varphi-wabl/ldev/rdev median of a trapezoidal fuzzy sample

Description

Given a sample of trapezoidal fuzzy numbers contained in a matrix F, the function calculates the φ\varphi-wabl/ldev/rdev median of these numbers, characterized by means of nl equidistant α\alpha-levels (by default nl=101), including always the 0 and 1 levels, with their infimum and supremum values. The function first checks if the input matrix F is given in the correct form (tested by checkingTra).

Usage

Medianwabl(F, nl = 101, a = 1, b = 1)

Arguments

F

matrix of dimension n x 4 containing n trapezoidal fuzzy numbers characterized by their four values inf0,inf1,sup1,sup0. The function implicitly checks if the matrix is in the correct form (tested by checkingTra).

nl

positive integer, by default nl=101. It indicates the number of desired α\alpha-levels for characterizing theφ\varphi-wabl/ldev/rdev median.

a

number >0, by default a=1. It is the first parameter of a beta distribution which corresponds to a weighting measure on [0,1].

b

number >0, by default b=1. It is the second parameter of a beta distribution which corresponds to a weighting measure on [0,1].

Details

See examples

Value

The function returns the φ\varphi-wabl/ldev/rdev median, given by an array of dimension nl x 3 x 1 where nl is the number of considered α\alpha-levels and 3 the number of columns of the array: the first column will be the α\alpha-levels, the second one their infimum values and the third one their supremum values.

Note

In case you find (almost surely existing) bugs or have recommendations for improving the functions comments are welcome to the above mentioned mail addresses.

Author(s)

Asun Lubiano <[email protected]>, Sara de la Rosa de Saa <[email protected]>

References

[1] Sinova, B.; de la Rosa de Saa, S.; Gil, M.A.: A generalized L1-type metric between fuzzy numbers for an approach to central tendency of fuzzy data, Information Sciences 242, pp. 22-34 (2013)

[2] Sinova, B.; Gil, M.A.; Van Aelst, S.: M-estimates of location for the robust central tendency of fuzzy data, IEEE Transactions on Fuzzy Systems 24(4), pp. 945-956 (2016)

See Also

checkingTra, DwablphiTra, Dwablphi, Wablphi, Median1norm

Examples

# Example 1:
F=SimulCASE1(10)
Medianwabl(F,3)

# Example 2:
F=matrix(c(1,0,2,3),nrow=1)
Medianwabl(F)

Qn scale measure of a trapezoidal fuzzy sample

Description

This function calculates the scale measure Qn for a matrix of trapezoidal fuzzy numbers F. The employed metric in the calculation can be the 1-norm distance, the mid/spr distance or the (φ,θ)(\varphi,\theta)-wabl/ldev/rdev distance. The function first checks if the input matrix F is given in the correct form (tested by checkingTra).

Usage

Qn(F, type, a = 1, b = 1, theta = 1/3)

Arguments

F

matrix of dimension n x 4 containing n trapezoidal fuzzy numbers characterized by their four values inf0,inf1,sup1,sup0. The function implicitly checks if the matrix is in the correct form (tested by checkingTra).

type

number 1, 2 or 3: if type==1, the 1-norm distance will be considered in the calculation of the measure ADD. If type==2, the mid/spr distance will be considered. By contrast, if type==3, the (φ,θ)(\varphi,\theta)-wabl/ldev/rdev distance will be used.

a

number >0, by default a=1. It is the first parameter of a beta distribution which corresponds to a weighting measure on [0,1] in the mid/spr distance or in the (φ,θ)(\varphi,\theta)-wabl/ldev/rdev distance.

b

number >0, by default b=1. It is the second parameter of a beta distribution which corresponds to a weighting measure on [0,1] in the mid/spr distance or in the (φ,θ)(\varphi,\theta)-wabl/ldev/rdev distance.

theta

number >0, by default theta=1/3. It is the weight of the spread in the mid/spr distance and the weight of the ldev and rdev in the (φ,θ)(\varphi,\theta)-wabl/ldev/rdev distance.

Details

See examples

Value

The function returns the scale measure Qn, which is a real number.

Note

In case you find (almost surely existing) bugs or have recommendations for improving the functions comments are welcome to the above mentioned mail addresses.

Author(s)

Asun Lubiano <[email protected]>, Sara de la Rosa de Saa <[email protected]>

See Also

checkingTra, Rho1Tra, DthetaphiTra, DwablphiTra

Examples

# Example 1:
F=SimulCASE1(10)
Qn(F,3,1,1,1)

# Example 2:
F=matrix(c(1,3,2,2),nrow=1)
Qn(F,2,5,1,1)

1-norm distance between fuzzy numbers

Description

This function calculates the 1-norm distance between the fuzzy numbers contained in two arrays, which should be given in the desired format. For this, the function first checks if the input arrays R and S are in the correct form (tested by checking) and if the α\alpha-levels of all fuzzy numbers coincide.

Usage

Rho1(R, S)

Arguments

R

array of dimension nl x 3 x r containing r fuzzy numbers characterized by means of nl α\alpha-levels each. The function first calls checking to check if the array R has the correct format. Moreover, the α\alpha-levels of the array R should coincide with the ones of the array S (the function checks this condition).

S

array of dimension nl x 3 x s containing s fuzzy numbers characterized by means of nl α\alpha-levels each. The function first calls checking to check if the array S has the correct format. Moreover, the α\alpha-levels of the array S should coincide with the ones of the array R (the function checks this condition).

Details

See examples

Value

The function returns a matrix of dimension r x s containing the 1-norm distances between the fuzzy numbers of the array R and the fuzzy numbers of the array S .

Note

In case you find (almost surely existing) bugs or have recommendations for improving the functions comments are welcome to the above mentioned mail addresses.

Author(s)

Asun Lubiano <[email protected]>, Sara de la Rosa de Saa <[email protected]>

References

[1] Diamond, P.; Kloeden, P.: Metric spaces of fuzzy sets, Fuzzy Sets Syst. 35, pp. 241-249 (1990)

See Also

checking, Rho1Tra

Examples

# Example 1:
F=SimulCASE1(4)
S=SimulCASE1(5)
F=TransfTra(F)
S=TransfTra(S)
Rho1(F,S)

# Example 2:
F=SimulCASE1(4)
S=SimulCASE1(5)
S=TransfTra(S)
Rho1(F,S)

# Example 3:
F=SimulCASE1(4)
S=SimulCASE1(5)
F=TransfTra(F)
S=TransfTra(S,10)
Rho1(F,S)

1-norm distance between trapezoidal fuzzy numbers

Description

This function calculates the 1-norm distance between the trapezoidal fuzzy numbers contained in two matrixes, which should be given in the desired format. For this, the function first checks if the input matrixes R and S are in the correct form (tested by checkingTra).

Usage

Rho1Tra(R, S)

Arguments

R

matrix of dimension r x 4 containing r trapezoidal fuzzy numbers characterized by their four values inf0,inf1,sup1,sup0. The function first calls checkingTra to check if the matrix R has the correct format.

S

matrix of dimension s x 4 containing s trapezoidal fuzzy numbers characterized by their four values inf0,inf1,sup1,sup0. The function first calls checkingTra to check if the matrix S has the correct format.

Details

See examples

Value

The function returns a matrix of dimension r x s containing the 1-norm distances between the trapezoidal fuzzy numbers of the matrix R and the trapezoidal fuzzy numbers of the matrix S.

Note

In case you find (almost surely existing) bugs or have recommendations for improving the functions comments are welcome to the above mentioned mail addresses.

Author(s)

Asun Lubiano <[email protected]>, Sara de la Rosa de Saa <[email protected]>

See Also

checkingTra, Rho1

Examples

# Example 1:
F=SimulCASE2(4)
S=SimulCASE3(5)
Rho1Tra(F,S)

# Example 2:
F=matrix(c(1,1,0,2,3,4,5,6),nrow=2)
S=SimulCASE3(5)
Rho1Tra(F,S)

S1 dataset

Description

S1 is a matrix of dimension 69 x 4 containing 69 trapezoidal fuzzy rating responses, each of which is characterized by its four values inf0,inf1,sup1,sup0. The data correspond to the well-known questionnaire TIMSS-PIRLS2011. This questionnaire was adapted to allow a double-type response, namely, the original Likert and a fuzzy rating scale-based (to simplify, trapezoidal). The questionnaire was conducted on 69 fourth grade students from Colegio San Ignacio (Oviedo-Asturias, Spain). Trapezoidal fuzzy rating responses to the Question S1 "My teacher taught me to discover science in daily life" are collected in this dataset.

Usage

data("S1")

Format

A matrix of dimension 69 x 4 containing 69 trapezoidal fuzzy rating responses, each of which is characterized by its four values inf0,inf1,sup1,sup0.

Details

See examples

Source

The complete dataset can be found in http://bellman.ciencias.uniovi.es/SMIRE/FuzzyRatingScaleQuestionnaire-SanIgnacio.html

References

[1] Gil, M.A.; Lubiano, M.A.; De la Rosa de Saa, S.; Sinova, B.: Analyzing data from a fuzzy rating scale-based questionnaire. A case study, Psicothema 27(2), pp. 182-191 (2015)

[2] Lubiano, M.A.; De la Rosa de Saa, S.; Montenegro, M.; Sinova, B.; Gil, M.A.: Descriptive analysis of responses to items in questionnaires. Why not a fuzzy rating scale?, Information Sciences 360, pp. 131-148 (2016)

[3] Lubiano, M.A.; Montenegro, M.; Sinova, B.; De la Rosa de Saa, S.; Gil, M.A.: Hypothesis testing for means in connection with fuzzy rating scale-based data: algorithms and applications, European Journal of Operational Research 251, pp. 918-929 (2016)

Examples

data(S1)
filterNA(S1)
F=filterNA(S1)[[1]]
Var(F)

Simulation of trapezoidal fuzzy numbers CASE 1

Description

This function generates n trapezoidal fuzzy numbers from a symmetric distribution and with independent components (for a detailed explanation of the simulation see the paper [1] below, namely, the Case 1 for noncontaminated samples).

Usage

SimulCASE1(n)

Arguments

n

positive integer. It is the number of trapezoidal fuzzy numbers to be generated.

Details

See examples

Value

This function returns n trapezoidal fuzzy numbers contained in a matrix of dimension n x 4. Each trapezoidal fuzzy number is characterized by its four values inf0,inf1,sup1,sup0.

Note

In case you find (almost surely existing) bugs or have recommendations for improving the functions comments are welcome to the above mentioned mail addresses.

Author(s)

Asun Lubiano <[email protected]>, Sara de la Rosa de Saa <[email protected]>

References

[1] Sinova, B.; Gil, M.A.; Colubi, A.; Van Aelst, S.: The median of a random fuzzy number. The 1-norm distance approach, Fuzzy Sets Syst. 200, pp. 99-115 (2012)

See Also

SimulCASE2, SimulCASE3, SimulCASE4, SimulFRSTra

Examples

# Example 1:
SimulCASE1(10)

Simulation of trapezoidal fuzzy numbers CASE 2

Description

This function generates n trapezoidal fuzzy numbers from a symmetric distribution and with dependent components (for a detailed explanation of the simulation see the paper [1] below, namely, the Case 2 for noncontaminated samples).

Usage

SimulCASE2(n)

Arguments

n

positive integer. It is the number of trapezoidal fuzzy numbers to be generated.

Details

See examples

Value

This function returns n trapezoidal fuzzy numbers contained in a matrix of dimension n x 4. Each trapezoidal fuzzy number is characterized by its four values inf0,inf1,sup1,sup0.

Note

In case you find (almost surely existing) bugs or have recommendations for improving the functions comments are welcome to the above mentioned mail addresses.

Author(s)

Asun Lubiano <[email protected]>, Sara de la Rosa de Saa <[email protected]>

References

[1] Sinova, B.; Gil, M.A.; Colubi, A.; Van Aelst, S.: The median of a random fuzzy number. The 1-norm distance approach, Fuzzy Sets Syst. 200, pp. 99-115 (2012)

See Also

SimulCASE1, SimulCASE3, SimulCASE4, SimulFRSTra

Examples

# Example 1:
SimulCASE2(10)

Simulation of trapezoidal fuzzy numbers CASE 3

Description

This function generates n trapezoidal fuzzy numbers from an asymmetric distribution and with independent components (for a detailed explanation of the simulation see the paper [1] below, namely, the Case 3 for noncontaminated samples).

Usage

SimulCASE3(n)

Arguments

n

positive integer. It is the number of trapezoidal fuzzy numbers to be generated.

Details

See examples

Value

This function returns n trapezoidal fuzzy numbers contained in a matrix of dimension n x 4. Each trapezoidal fuzzy number is characterized by its four values inf0,inf1,sup1,sup0.

Note

In case you find (almost surely existing) bugs or have recommendations for improving the functions comments are welcome to the above mentioned mail addresses.

Author(s)

Asun Lubiano <[email protected]>, Sara de la Rosa de Saa <[email protected]>

References

[1] Sinova, B.; Gil, M.A.; Van Aelst, S.: M-estimates of location for the robust central tendency of fuzzy data, IEEE Transactions on Fuzzy Systems 24(4), pp. 945-956 (2016)

See Also

SimulCASE1, SimulCASE2, SimulCASE4, SimulFRSTra

Examples

# Example 1:
SimulCASE3(10)

Simulation of trapezoidal fuzzy numbers CASE 4

Description

This function generates n trapezoidal fuzzy numbers from an asymmetric distribution and with dependent components (for a detailed explanation of the simulation see the paper [1] below, namely, the Case 4 for noncontaminated samples).

Usage

SimulCASE4(n)

Arguments

n

positive integer. It is the number of trapezoidal fuzzy numbers to be generated.

Details

See examples

Value

This function returns n trapezoidal fuzzy numbers contained in a matrix of dimension n x 4. Each trapezoidal fuzzy number is characterized by its four values inf0,inf1,sup1,sup0.

Note

In case you find (almost surely existing) bugs or have recommendations for improving the functions comments are welcome to the above mentioned mail addresses.

Author(s)

Asun Lubiano <[email protected]>, Sara de la Rosa de Saa <[email protected]>

References

[1] Sinova, B.; Gil, M.A.; Van Aelst, S.: M-estimates of location for the robust central tendency of fuzzy data, IEEE Transactions on Fuzzy Systems 24(4), pp. 945-956 (2016)

See Also

SimulCASE1, SimulCASE2, SimulCASE3, SimulFRSTra

Examples

# Example 1:
SimulCASE4(10)

Simulation of trapezoidal fuzzy rating responses to a questionnaire

Description

This function generates n trapezoidal responses based on the fuzzy rating scale. They are simulated mimicking the human behavior, considering for it a finite mixture of three different procedures (for a detailed explanation of the simulation see the paper [1] below), and generated in the interval [1,k], being k the number of Likert responses of the supposed questionnaire.

Usage

SimulFRSTra(n, k, w1, w2, w3, p, q)

Arguments

n

positive integer. It is the number of trapezoidal fuzzy numbers to be generated.

k

positive integer and >1. It's the number of Likert responses of the supposed questionnaire. The trapezoidal fuzzy responses will be generated in the interval [1,k].

w1

number in [0,1]. It should be fulfilled that w1+w2+w3=1.

w2

number in [0,1]. It should be fulfilled that w1+w2+w3=1.

w3

number in [0,1]. It should be fulfilled that w1+w2+w3=1.

p

number >0. It is the first parameter of the beta distribution.

q

number >0. It is the second parameter of the beta distribution.

Details

See examples

Value

This function returns n trapezoidal fuzzy rating responses contained in a matrix of dimension n x 4, with values in the interval [1,k]. Each trapezoidal fuzzy rating response is characterized by its four values inf0,inf1,sup1,sup0.

Note

In case you find (almost surely existing) bugs or have recommendations for improving the functions comments are welcome to the above mentioned mail addresses.

Author(s)

Asun Lubiano <[email protected]>, Sara de la Rosa de Saa <[email protected]>

References

[1] De la Rosa de Saa, S.; Gil, M.A.; Gonzalez-Rodriguez, G.; Lopez, M.T.; Lubiano M.A.: Fuzzy rating scale-based questionnaires and their statistical analysis, IEEE Trans. Fuzzy Syst. 23(1), pp. 111-126 (2015)

See Also

SimulCASE1, SimulCASE2, SimulCASE3, SimulCASE4

Examples

# Example 1:
SimulFRSTra(100,6,0.05,0.35,0.6,2,1)

Sn scale measure of a trapezoidal fuzzy sample

Description

This function calculates the scale measure Sn for a matrix of trapezoidal fuzzy numbers F. The employed metric in the calculation can be the 1-norm distance, the mid/spr distance or the (φ,θ)(\varphi,\theta)-wabl/ldev/rdev distance. The function first checks if the input matrix F is given in the correct form (tested by checkingTra).

Usage

Sn(F, type, a = 1, b = 1, theta = 1/3)

Arguments

F

matrix of dimension n x 4 containing n trapezoidal fuzzy numbers characterized by their four values inf0,inf1,sup1,sup0. The function implicitly checks if the matrix is in the correct form (tested by checkingTra).

type

number 1, 2 or 3: if type==1, the 1-norm distance will be considered in the calculation of the measure ADD. If type==2, the mid/spr distance will be considered. By contrast, if type==3, the (φ,θ)(\varphi,\theta)-wabl/ldev/rdev distance will be used.

a

number >0, by default a=1. It is the first parameter of a beta distribution which corresponds to a weighting measure on [0,1] in the mid/spr distance or in the (φ,θ)(\varphi,\theta)-wabl/ldev/rdev distance.

b

number >0, by default b=1. It is the second parameter of a beta distribution which corresponds to a weighting measure on [0,1] in the mid/spr distance or in the (φ,θ)(\varphi,\theta)-wabl/ldev/rdev distance.

theta

number >0, by default theta=1/3. It is the weight of the spread in the mid/spr distance and the weight of the ldev and rdev in the (φ,θ)(\varphi,\theta)-wabl/ldev/rdev distance.

Details

See examples

Value

The function returns the scale measure Sn, which is a real number.

Note

In case you find (almost surely existing) bugs or have recommendations for improving the functions comments are welcome to the above mentioned mail addresses.

Author(s)

Asun Lubiano <[email protected]>, Sara de la Rosa de Saa <[email protected]>

See Also

checkingTra, Rho1Tra, DthetaphiTra, DwablphiTra

Examples

# Example 1:
F=SimulCASE1(10)
Sn(F,2,5,1,0.5)

# Example 2:
F=matrix(c(1,3,2,2),nrow=1)
Sn(F,1)

Tn scale measure of a trapezoidal fuzzy sample

Description

This function calculates the scale measure Tn for a matrix of trapezoidal fuzzy numbers F. The employed metric in the calculation can be the 1-norm distance, the mid/spr distance or the (φ,θ)(\varphi,\theta)-wabl/ldev/rdev distance. The function first checks if the input matrix F is given in the correct form (tested by checkingTra).

Usage

Tn(F, type, a = 1, b = 1, theta = 1/3)

Arguments

F

matrix of dimension n x 4 containing n trapezoidal fuzzy numbers characterized by their four values inf0,inf1,sup1,sup0. The function implicitly checks if the matrix is in the correct form (tested by checkingTra).

type

number 1, 2 or 3: if type==1, the 1-norm distance will be considered in the calculation of the measure ADD. If type==2, the mid/spr distance will be considered. By contrast, if type==3, the (φ,θ)(\varphi,\theta)-wabl/ldev/rdev distance will be used.

a

number >0, by default a=1. It is the first parameter of a beta distribution which corresponds to a weighting measure on [0,1] in the mid/spr distance or in the (φ,θ)(\varphi,\theta)-wabl/ldev/rdev distance.

b

number >0, by default b=1. It is the second parameter of a beta distribution which corresponds to a weighting measure on [0,1] in the mid/spr distance or in the (φ,θ)(\varphi,\theta)-wabl/ldev/rdev distance.

theta

number >0, by default theta=1/3. It is the weight of the spread in the mid/spr distance and the weight of the ldev and rdev in the (φ,θ)(\varphi,\theta)-wabl/ldev/rdev distance.

Details

See examples

Value

The function returns the scale measure Tn, which is a real number.

Note

In case you find (almost surely existing) bugs or have recommendations for improving the functions comments are welcome to the above mentioned mail addresses.

Author(s)

Asun Lubiano <[email protected]>, Sara de la Rosa de Saa <[email protected]>

See Also

checkingTra, Rho1Tra, DthetaphiTra, DwablphiTra

Examples

# Example 1:
F=SimulCASE1(10)
Tn(F,1)

# Example 2:
F=matrix(c(1,2,3,4),nrow=2)
Tn(F,2,5,1,0.5)

Transformation of a matrix of trapezoidal fuzzy numbers into an array

Description

This function transforms a matrix of dimension n x 4 containing n trapezoidal fuzzy numbers characterized by their four values inf0,inf1,sup1,sup0 into an array of dimension nl x 3 x n containing these n fuzzy numbers characterized by means of nl equidistant α\alpha-levels each (by default nl=101). The function first checks if the input matrix F is given in the correct form (tested by checkingTra). In case yes, the function returns an array given in the format explained in the function checking.

Usage

TransfTra(F, nl = 101)

Arguments

F

matrix of dimension n x 4 containing n trapezoidal fuzzy numbers characterized by their four values inf0,inf1,sup1,sup0. The function implicitly checks if the matrix is in the correct form (tested by checkingTra).

nl

positive integer, by default nl=101. It indicates the number of desired α\alpha-levels for characterizing the trapezoidal fuzzy numbers.

Details

See examples

Value

The function returns an array of dimension nl x 3 x n containing the n trapezoidal fuzzy numbers characterized by means of nl α\alpha-levels. The first column of the array are the α\alpha-levels, the second one their infimum values and the third one their supremum values. The correct format of the array is explained in the function checking.

Note

In case you find (almost surely existing) bugs or have recommendations for improving the functions comments are welcome to the above mentioned mail addresses.

Author(s)

Asun Lubiano <[email protected]>, Sara de la Rosa de Saa <[email protected]>

See Also

checkingTra, checking

Examples

# Example 1:
F=SimulCASE3(10)
TransfTra(F,200)

# Example 2:
F=matrix(c(1,1,0,2,3,4,5,6),nrow=2)
TransfTra(F)

Variance of a trapezoidal fuzzy sample

Description

Given a sample of trapezoidal fuzzy numbers contained in a matrix F, the function calculates the variance of these numbers with respect to the mid/spr distance. The function first checks if the input matrix F is given in the correct form (tested by checkingTra).

Usage

Var(F, a = 1, b = 1, theta = 1/3)

Arguments

F

matrix of dimension n x 4 containing n trapezoidal fuzzy numbers characterized by their four values inf0,inf1,sup1,sup0. The function implicitly checks if the matrix is in the correct form (tested by checkingTra).

a

number >0, by default a=1. It is the first parameter of a beta distribution which corresponds to a weighting measure on [0,1].

b

number >0, by default b=1. It is the second parameter of a beta distribution which corresponds to a weighting measure on [0,1].

theta

number >0, by default theta=1/3. It is the weight of the spread in the mid/spr distance.

Details

See examples

Value

The function returns the variance of the sample with respect to the mid/spr distance, which is a real number.

Note

In case you find (almost surely existing) bugs or have recommendations for improving the functions comments are welcome to the above mentioned mail addresses.

Author(s)

Asun Lubiano <[email protected]>, Sara de la Rosa de Saa <[email protected]>

References

[1] De la Rosa de Saa, S.; Lubiano M.A.; Sinova, B.; Filzmoser, P.: Robust scale estimators for fuzzy data, Advances in Data Analysis and Classification, pp. 1-28 (2015)

See Also

checkingTra, Mean, DthetaphiTra

Examples

# Example 1:
F=SimulCASE1(10)
Var(F,1,1,1)

# Example 2:
F=matrix(c(1,0,2,3),nrow=1)
Var(F)

φ\varphi-wabl values of a trapezoidal fuzzy sample

Description

Given a sample of trapezoidal fuzzy numbers contained in a matrix F, the function calculates the φ\varphi-wabl value for each of these numbers. The function first checks if the input matrix F is given in the correct form (tested by checkingTra).

Usage

Wablphi(F, a = 1, b = 1)

Arguments

F

matrix of dimension n x 4 containing n trapezoidal fuzzy numbers characterized by their four values inf0,inf1,sup1,sup0. The function implicitly checks if the matrix is in the correct form (tested by checkingTra).

a

number >0, by default a=1. It is the first parameter of a beta distribution which corresponds to a weighting measure on [0,1].

b

number >0, by default b=1. It is the second parameter of a beta distribution which corresponds to a weighting measure on [0,1].

Details

See examples

Value

The function returns a vector giving the φ\varphi-wabl values of each trapezoidal fuzzy number.

Note

In case you find (almost surely existing) bugs or have recommendations for improving the functions comments are welcome to the above mentioned mail addresses.

Author(s)

Asun Lubiano <[email protected]>, Sara de la Rosa de Saa <[email protected]>

References

[1] Sinova, B.; Gil, M.A.; Lopez, M.T.; Van Aelst, S.: A parameterized L2 metric between fuzzy numbers and its parameter interpretation, Fuzzy Sets and Systems 245, pp. 101-115 (2014)

See Also

checkingTra, DwablphiTra, Dwablphi, Medianwabl

Examples

# Example 1:
F=SimulCASE4(60)
Wablphi(F,2,1)

# Example 2:
F=matrix(c(1,0,2,3),nrow=1)
Wablphi(F)