# (-) minus operator

## (- number) ðŸ¡’ number

Example:

x = 3
show scalar "" with -x


## (- date) ðŸ¡’ number

Converts the date to a number and then invert its sign.

Example:

x = date(2020, 10, 1)
show scalar "" with -x


This operator is primarily intended for specifying the increasing or decreasing order when sorting against date value.

## (number - number) ðŸ¡’ number

The regular substraction of two numbers.

Example:

x = 3
y = 2
show scalar "" with x - y


## (date - date) ðŸ¡’ number

The substraction of two dates returns the number of days of difference.

Example:

x = date(2020, 11, 25)
y = date(2019,  8, 24)
show scalar "days" with x - y


There is no + counterpart for a pair of date values.

## (date - number) ðŸ¡’ date

Substracts an integral number of days to a date.

Example:

x = date(2020,8,25) + 12
show scalar "" with x


## (number - date) ðŸ¡’ number

Substract to a number a date intepreted as an number of days since Jan 1st, 2001.

Example:

x = 7000 - date(2020,8,25)
show scalar "" with x


## (ranvar - ranvar) ðŸ¡’ ranvar

The substraction of two random independent variables over $\mathbb{Z}$.

Example:

x1 = poisson(5)
x2 = poisson(3)
show scalar "" a1b2 with x1 - x2


## (zedfunc - zedfunc) ðŸ¡’ zedfunc

The substraction of two zedfuncs, real functions over $\mathbb{Z}$..

Example:

f = linear(3)
g = linear(2)
show scalar "" a1b2 with f - g