(-) minus operator

(- date) 🡒 number, const

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

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, const autodiff

The sign inversion of a number.

x = 3
show scalar "" with -x

(- ranvar) 🡒 ranvar

The reflected random random variable, i.e. $P[x = -X]$.

x = poisson(3)
show scalar "" with -x

(- zedfunc) 🡒 zedfunc

The inverted function, i.e. $f(-x)$.

x = linear(3)
show scalar "" with -x

(number - number) 🡒 number, const autodiff

The regular substraction of two numbers.

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

(date - date) 🡒 number, const

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

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, const

Substracts an integral number of days to a date.

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

(number - date) 🡒 number, const

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

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

(ranvar - ranvar) 🡒 ranvar

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

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}$..

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