Import a module, and issue a nice message to stderr if the module isn’t installed.
Currently, this function will print nice error messages for networkx, tables, netCDF4, and simtk.unit, which are optional MDTraj dependencies.
| Parameters: | module : str 
 | 
|---|---|
| Returns: | module : {module, object} 
 | 
Examples
>>> # the following two lines are equivalent. the difference is that the
>>> # second will check for an ImportError and print you a very nice
>>> # user-facing message about what's wrong (where you can install the
>>> # module from, etc) if the import fails
>>> import tables
>>> tables = import_('tables')