stan-dev/stan

deprecate int_step

Aberta

#2.433 aberto em 9 de nov. de 2017

 (5 comentários) (0 reação) (0 responsável)C++ (387 forks)batch import
bugdocumentationgood first issue

Métricas do repositório

Stars
 (2.761 estrelas)
Métricas de merge de PR
 (Nenhuma PRs mesclada em 30d)

Description

Summary:

int_step(x) and step(x) return different values for 0.

The version of step(x) matches the BUGS definition and the standard definition of the Heaviside step function. Therefore, it should not be changed.

Changing int_step()'s behavior would be confusing, so instead it should be deprecated and replaced with a suggestion to replace existing uses of int_step(n) with the boolean expression (n >= 0), which evaluates to 1 if n >= 0 and 0 otherwise.

Current Version:

v2.17.0

Guia do colaborador