Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow .~ infix operator #30341

Closed
cscherrer opened this issue Dec 10, 2018 · 0 comments

Comments

2 participants
@cscherrer
Copy link

commented Dec 10, 2018

~ is standard notation for statistical distributions, for example x ~ Normal(0,1). Because of this, it's a natural choice for probabilistic programming DSLs like Soss.jl and Turing.jl.

It would be convenient to allow this notation to be broadcast in the usual way, for example allowing x .~ Normal(0,1). But this currently seems to be disallowed:

julia> :(x .~ Normal(0,1))
ERROR: syntax: missing comma or ) in argument list

@StefanKarpinski suggested I open an issue to request this be changed:
cscherrer/Soss.jl#14 (comment)

Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.