Import a module or library
4.6 •• • •
How to add a module
To add a module or library, select Add Module (Control+l) or Add Library from the File menu. The main difference is that Add module starts the file browser by default in the folder you opened the model (or last added module) from, where Add Library starts from the standard libraries folder installed when you installed Analytica. Either way, you must be in Edit mode or those options will be grayed out in the File menu.
The standard Open Model dialog appears. Select the desired module in that dialog. The following dialog then appears.
An added module or library can be either embedded or linked. You can optionally overwrite any nodes with the same identifiers.
Embed a copy
Embeds a copy of the selected module or library in the active model, making it a part of, and saving it with, the model. Any changes to the copy do not affect the original filed module or library.
Link to original
Creates a link to the selected module or library, which can be separately opened and saved. If you make changes to a filed module or library from one model, the changes are saved in the original’s file and any other models linked to the original are affected by the changes. A filed module or filed library has a bold arrow pointing into it on the diagram.
Merge contents (overwrite)
Select this checkbox to overwrite existing objects in the active model with objects with the same identifiers from the added module or library. This is useful if the file being added contains updates from a previous version.
If you do not select this checkbox, and an object in the file being added has the same identifier as one in the active model, Analytica points that out and asks if you want to rename the variable. If you click Yes, it renames the variable in the existing model, and updates all definitions in the existing model to use the changed identifier. It leaves unchanged the identifier of the variable in the module it is adding (which might contain definitions referencing that identifier that it has yet to read.) Hence, all the definitions in the existing model and added module continue to reference the correct (original) variables.
- Tutorial: Opening modules
- Using Add Module... to import a Model file
- Modules and Libraries
- Obfuscated and Browse-Only Models
- Filed modules and libraries
- Working with Models, Modules, and Files in ADE
- Combining models into an integrated model
- Example Models and Libraries
- Analytica Libraries and Templates