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

Add quick_launch function for easier scripting and interactive sessions #191

Merged
merged 2 commits into from
Feb 9, 2020

Conversation

jpgill86
Copy link
Owner

@jpgill86 jpgill86 commented Feb 9, 2020

Load data, configure the GUI, and launch the app with one convenient function.

quick_launch allows neurotic to be used easily in interactive sessions and scripts. For example:

>>> import neurotic
>>> metadata = {'data_file': 'data.axgx'}
>>> neurotic.quick_launch(metadata)

See documentation: https://neurotic.readthedocs.io/en/latest/api/scripts.html#neurotic.scripts.quick_launch

Although reading metadata from files using ``_load_metadata`` sets defaults, defaults were not set for metadata derived from other sources, e.g., a simple dictionary constructed in a script or interactive session. This made manually constructing a metadata dictionary unnecessarily tedious, since defaults had to be filled in by hand for many unused features.

This change allows default values to be filled in on the fly, which should allow incomplete metadata dictionaries, such as those built manually in interactive sessions or scripts, to work with less effort.
@jpgill86 jpgill86 added the enhancement New feature or request label Feb 9, 2020
@jpgill86 jpgill86 added this to the 1.4.0 milestone Feb 9, 2020
@coveralls
Copy link

coveralls commented Feb 9, 2020

Coverage Status

Coverage increased (+0.02%) to 51.974% when pulling eab062e on quick-launch into a1c2d62 on master.

@coveralls
Copy link

Coverage Status

Coverage increased (+0.01%) to 51.972% when pulling eab062e on quick-launch into a1c2d62 on master.

@jpgill86 jpgill86 merged commit c6c5064 into master Feb 9, 2020
@jpgill86 jpgill86 deleted the quick-launch branch February 9, 2020 20:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants