-
-
Notifications
You must be signed in to change notification settings - Fork 10
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
Using Preferences #358
Comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This is a meta-issue for all Julia component packages. Python ArviZ uses a matplotlib-like rcParams object to manage global configurable options. For projects with many analyses, this allows the user to set a preference once (e.g. default CI type or probability) and use it everywhere without needing to always include it in the keywords.
I think the right way to do this in Julia would be to use Preferences.jl and define a
LocalPreferences.toml
giving the preferences. unlike Python ArviZ, I think the user would need to set any changed preferences in their ownLocalPreferences.toml
before launching Julia. The question then is whether we should define an ArviZPreferences.jl package that only exists to set preferences for all of our packages (and would need to be a dependency for all our packages( or whether we should have each package define its ownLocalPreferences.toml
.The advantage of the first option is a single place where all preferences are set, and we can easily print out the file in the docs. The disadvantage is that if we want to add a new preferences option for a given package, we need to first modify this dependency.
The advantage of the second option is that the preferences are defined where they are needed. The disadvantage is that the preferences are clustered by package name. Since ArviZ is a meta-package, this requires users to know in which package which parameter is defined. Not really a problem if we have a way to print out in the docs the preferences for all component packages.
The text was updated successfully, but these errors were encountered: