Example of auto completion with IPython¶

Links: notebook, html, PDF, python, slides, slides(2), GitHub

Dirty trick to extend the automated completion in a notebook.

from pyquickhelper.ipythonhelper import AutoCompletionFile
from jyquickhelper.helper_in_notebook import set_notebook_name_theNotebook
set_notebook_name_theNotebook()
<IPython.core.display.Javascript object>
theNotebook
'example_completion.ipynb'
import os
path = os.path.join(os.path.abspath(os.path.dirname(theNotebook)), "..")
d = AutoCompletionFile(path)
d._members
['notebooks', 'sphinxdoc']
d.sphinxdoc.source.index_rst._ [25:]
'GitHub\pyquickhelper\_doc\sphinxdoc\source\index.rst'
import os
os.listdir(d.sphinxdoc.source._)
['all_coverage.rst',
 'all_example.rst',
 'all_example_otherpageofexamples.rst',
 'all_example_pagewithanaccentinthetitle.rst',
 'all_example_pagewithanaccentointhetitle.rst',
 'all_FAQ.rst',
 'all_indexes.rst',
 'all_notebooks.rst',
 'all_report.rst',
 'blog',
 'completion.png',
 'conf.py',
 'doctestunit.rst',
 'documentation_example.rst',
 'filechanges.rst',
 'form.png',
 'generatedoc.rst',
 'generatesetup.rst',
 'glossary.rst',
 'images',
 'index.rst',
 'indexmenu.rst',
 'index_class.rst',
 'index_ext-doc.rst',
 'index_function.rst',
 'index_method.rst',
 'index_module.rst',
 'index_property.rst',
 'index_staticmethod.rst',
 'installation.rst',
 'license.rst',
 'LICENSE.txt',
 'notebooks',
 'open_function.png',
 'open_functionl.png',
 'open_params.png',
 'phdoc_static',
 'phdoc_templates',
 'pyquickhelper',
 'README.rst',
 '_images',
 '__pycache__']