sign1 | R Documentation |
differ from sign as it return 0 when x is NA
sign1(x)
x |
any number |
1 if x > 0 -1 if x < 0 0 if x = 0 or x = NA
used by rkt
Aldo Marchetto
Hirsch R.M. & Slack J.R. 1984. A nonparametric test for seasonal data with serial dependance. Water Resources Research, 20: 727-732
rkt
a<-1
sign1(a)
a<-NA
sign1(a)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.