Skip to content

How to run rxinfer on infinite stream iteratively? #133

Answered by bvdmitri
schlichtanders asked this question in Q&A
Discussion options

You must be logged in to vote

@schlichtanders Perhaps, for your use case you can just use the inference function then? Your logic will be looking like

# cell 1:
update = Dates.now()

# cell 2:
# I assume in your model specification you have a `datavar` named `y`
posterior = inference(model = my_model(prior), data = (y = update, )) 

# cell 3:
plot(posterior)

or something similar.

We use this kind of pattern in almost all of our examples in the documentation, and it works perfectly inside Pluto because Pluto itself handles all reactivity. The interface to the inference function is almost identical to rxinference, with the exception that it encapsulates all the reactivity magic inside, and simply returns the result, al…

Replies: 3 comments 12 replies

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
12 replies
@schlichtanders
Comment options

@bvdmitri
Comment options

@schlichtanders
Comment options

@schlichtanders
Comment options

@bvdmitri
Comment options

Answer selected by schlichtanders
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants
Converted from issue

This discussion was converted from issue #129 on June 20, 2023 14:33.