is.registeredMH | R Documentation |
Checks if a MatH
contains histograms described by the same number of
bins and the same cdf.
is.registeredMH(object)
## S4 method for signature 'MatH'
is.registeredMH(object)
object |
A |
a logical
value TRUE
if the distributions share the
same cdf, FALSE
otherwise.
Antonio Irpino
Irpino, A., Lechevallier, Y. and Verde, R. (2006): Dynamic
clustering of histograms using Wasserstein metric In: Rizzi, A., Vichi, M.
(eds.) COMPSTAT 2006. Physica-Verlag, Berlin, 869-876.
Irpino, A.,Verde,
R. (2006): A new Wasserstein based distance for the hierarchical
clustering of histogram symbolic data In: Batanjeli, V., Bock, H.H.,
Ferligoj, A., Ziberna, A. (eds.) Data Science and Classification, IFCS 2006.
Springer, Berlin, 185-192.
## ---- initialize three distributionH objects mydist1 and mydist2
mydist1 <- new("distributionH", c(1, 2, 3), c(0, 0.4, 1))
mydist2 <- new("distributionH", c(7, 8, 10, 15), c(0, 0.2, 0.7, 1))
mydist3 <- new("distributionH", c(9, 11, 20), c(0, 0.8, 1))
## create a MatH object
MyMAT <- new("MatH", nrows = 1, ncols = 3, ListOfDist = c(mydist1, mydist2, mydist3), 1, 3)
is.registeredMH(MyMAT)
## [1] FALSE #the distributions do not share the same cdf
## Hint: check with str(MyMAT)
## register the two distributions
MATregistered <- registerMH(MyMAT)
is.registeredMH(MATregistered)
## TRUE #the distributions share the same cdf
## Hint: check with str(MATregistered)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.