Fmedian {SAFD} | R Documentation |
Median of a fuzzy sample
Description
Given a list XX
of polygonal fuzzy numbers the functions first checks (1) if each element of the lists is in the correct form (tested by checking
) and (2) if the alpha-levels of all elements coincide. If all conditions are fulfilled the function calculates the (levelwise) median (which, by definition, is a fuzzy number too) using a large number of levels, by default nl
=101.
Usage
Fmedian(XX, nl = 101, pic = 1)
Arguments
XX |
...list of polygonal fuzzy numbers with the same alpha levels (the functions implicitly checks the conditions) |
nl |
...number of equidistant alpha-level, by default |
pic |
...numeric, if |
Details
See examples.
Value
Given correct input XX
the function returns the median of the sample.
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)
Wolfgang Trutschnig <wolfgang@trutschnig.net>, Asun Lubiano <lubiano@uniovi.es>
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 and Systems, 200, pp. 99-115 (2012)
See Also
See Also as Mmean
Examples
#Example 1:
data(XX)
V<-translator(XX[[3]],100)
YY<-vector("list",length=50)
for(i in 1:50){
YY[[i]]<-generator(V,,,)
}
Me<-Fmedian(YY)
#Example 2:
data(Trees)
Species1_Median<-Fmedian(Trees[[1]],nl=11)
Species1_Median
Species2_Median<-Fmedian(Trees[[2]])
Species3_Median<-Fmedian(Trees[[3]])