22 nov. 2017

Jupyter

1 Jupyter

1.0.1 Début avec emacs

Donc d'installation:

https://github.com/millejoh/emacs-ipython-notebook/issues/176

Ajouter les variables pour que celà fonctionne:

https://github.com/millejoh/emacs-ipython-notebook/issues/217

Solution pour configurer emacs avec EIN

For "Server Command" you want to enter the path to the jupyter executable. At the shell you can try executing which jupyter and it will report the path.

For "Notebook Directory" you want to enter the path to where you keep all your notebooks. What is the path when you start jupyter in the terminal?

Once you know the path to the jupyter executable, I would do the following.

    M-x customize-variable RET ein:jupyter-default-server-command and set the value to the path you determined above.
    M-x customize-variable RET ein:jupyter-default-notebook-directory and set it to the path where you are keeping your jupyter notebooks.

Et démarrer le serveur: M-x ein:jupyter-server-start

  1. Avec pandas et les json Transformer un json en dataframe
    import json
    import pandas as pd
    
    with open("maj.json") as datafile:
        data = json.load(datafile)
    dataframe = pd.DataFrame(data)
    
    dataframe
    

    Et un exemple de manipulation

    https://eric.univ-lyon2.fr/~ricco/tanagra/fichiers/fr%5C_Tanagra%5C_Data%5C_Manipulation%5C_Pandas.pdf

Other posts