verify/dataseries
verify a relation between two DataSeries objects
Calling Sequence
Parameters
Description
Examples
verify(expr1, expr2, dataseries)
verify(expr1, expr2, dataseries(ver, opt)
expr1, expr2
-
anything
ver
(optional) verification to use for the entries of the DataSeries objects
opt
(optional) equation of the form labelverification = lver, where lver is the verification to use for the labels of the DataSeries objects
The verify(expr1, expr2, dataseries) command returns true if expr1 and expr2 are both DataSeries objects, and their labels and entries are the same and occur in the same order.
The verify(expr1, expr2, dataseries(ver)) command returns true if expr1 and expr2 are both DataSeries objects, and their labels are the same and occur in the same order, and each entry of expr1 is in the relation specified by ver with the corresponding entry of expr2.
The verify(expr1, expr2, dataseries(labelverification=lver)) command returns true if expr1 and expr2 are both DataSeries objects, and their entries are the same and occur in the same order, and each label of expr1 is in the relation specified by lver with the corresponding label of expr2.
The verify(expr1, expr2, dataseries(ver, labelverification=lver)) command returns true if expr1 and expr2 are both DataSeries objects, and each label of expr1 is in the relation specified by lver with the corresponding label of expr2, and each entry of expr1 is in the relation specified by ver with the corresponding entry of expr2.
The relation specified as dataseries(ver, labelverification=lver) is symmetric if ver and lver are symmetric. The default relation used for verification if ver and/or lver is omitted, is symmetric (it is equality).
ds1≔DataSeries⁡1.,2.,3.,labels=a,b,c
ds1≔a1.b2.c3.
ds2≔DataSeries⁡1.01,1.99,2.99,labels=a,b,c
ds2≔a1.01b1.99c2.99
ds3≔DataSeries⁡1.,3.,2.,labels=a,c,b
ds3≔a1.c3.b2.
ds4≔DataSeries⁡1.,2.,3.,labels=d,e,f
ds4≔d1.e2.f3.
ds1 and ds1 have the same entries and labels.
verify⁡ds1,ds1,dataseries
true
ds1 and ds2 have different entries.
verify⁡ds1,ds2,dataseries
false
However, they are pairwise in the relation float(2, digits=3) (see verify/float).
verify⁡ds1,ds2,dataseries⁡float⁡2,digits=3
While ds1 and ds3 map the same labels to the same values, they are ordered differently. The verify/dataseries command has no facility to recognize this.
verify⁡ds1,ds3,dataseries
ds1 and ds4 have the same entries, but different labels. We specify labelverification = true (see verify/true) so that the labels compare pairwise successfully.
verify⁡ds1,ds4,dataseries⁡labelverification=true
See Also
DataFrame
DataSeries
verify
verify/dataframe
Download Help Document