-
Notifications
You must be signed in to change notification settings - Fork 19
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
Ideas for the far future #23
Comments
I've just come across this package whilst coding up some changepoint models directly. The specific application I've been working in is word/letter frequencies for stylometry. I'm interested to know if categorical/multinomial models could fit into this framework? (This package looks amazing, by the way!) |
@josswright Yes, mathematically and in JAGS it's straightforward to extend mcp to include multinomial models, as long as there is a continuous predictor. Just need mcp to count the number of categories in the dependent variable (N), to set up a logistic model for each of them ( I hope to get time to do this after adding survival analysis, but any pull requests are welcome :-) |
@lindeloev Fantastic! I'm more familiar with Stan than JAGS, but if I find the time then I'll definitely take a look! |
I'm working on abrupt time series forecasting problem and interested in change point/anomaly detection integrated with forecasting algorithms. This package is very promising. Just curious, are there particular reasons to choose JAGS over Stan as the underlying Bayesian software? IMO, stan gains more popularity and extensibility in the community, like "prophet", "tidybayes" and "shinystan". I'm wondering whether it would be considered to include an option to choose "stan" as a backend so we can get a stan model output to integrate with other "stan" based packages. |
@jpzhangvincent I chose JAGS because:
If I'd be happy to hear your thoughts here! |
Thanks for your response! I'd like to deep dive into the codebase and see anything I can contribute to. Can you give me some pointers where I can better understand how the model is specified in JAGS? |
@jpzhangvincent Yes, definitely!
This code is mostly generated in Adding support for |
Here are some ideas which could use some discussion and careful consideration. It extends the current model specification: https://lindeloev.github.io/mcp/articles/formulas.html
In the order from "soonish" (top) to "in your dreams":
Survival models
Survival models are relatively simple and we should support them, including censoring too. The API for the model itself would be something like
brms
:It should support both exponential decay and Cox proportional hazards. This would probably be specified via the
mcp(..., family = )
argument, but I'm unsure what would be the best.Slope on change points
If there are multiple (piecewise) lines over a single change point, and each line is associated with a different parameter
x
, we can use that to predict the change point. For example, we could assess subitizing in participants of varying age, and it would be reasonable to expect the subitizing range (location of first change point) to increase with age in childhood and decrease with age in adulthood.How to implement this in a formula, I'm unsure. Maybe it has to be in the random effect:
(1 + x | age)
since that specifies the grouping of multiple lines. This would also ensure that the parameter names stay intact.cp_i
,cp_i_age
, and then probablycp_i_x
.Multivariate regression
Multiple response variables predicted from single change points. Something like
This could be merged with "Variance change (Specify y)" to specify a change in one response but not the other:
ARIMA
mcp
currently supports AR(N) models. It should go more general. Take a look at:The text was updated successfully, but these errors were encountered: