-
Notifications
You must be signed in to change notification settings - Fork 6
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
Consider adding an argument to fix parameter values in models #84
Comments
Hi Darren, can you provide a reproducible example of doing this in drc? |
Hi Becky, Sure thing, here's an example using the earthworms dataset from drc package:
These data are from an avoidance bioassay - two containers are set next to each other, one containing contaminated soil and the other uncontaminated soil. If the earthworms don't like the contaminated soil they will move to the uncontaminated soil. We can fit a a 3-parameter log-logistic model:
The upper limit/asymptote is a parameter estimated by the model, but we know a priori that at dose 0 the number/total should be 0.5. So we can use the 'fixed' argument of drm to set that model parameter to 0.5:
|
Thanks Darren |
Hi Darren, apologies Diego and I have been too busy to implement this as yet. However, I have worked out some code to show you how to use bayesnec to fit the desired model, pull the brms formula and priors, and then refit using brms, using the constant. You can do this with:
inspect priors and use as a guide to build custom priors with constant 0.5 for top
get the brmsfit
update with custom priors
note top is now fixed at 0.5
|
Many concentration-response curves I generate use data normalised to a control response. This gives response values in percent with controls defined as being 100%. As such it would be useful to fix a model's upper asymptote to 100% (or 1). This would be equivalent to the 'fixed' argument in the drc package.
Thanks!
The text was updated successfully, but these errors were encountered: