=============================
Using Anaconda Cloud projects
=============================

Anaconda's cloud storage solution provides you with greater access to your files across your workspace. By securely uploading your CSVs, notebook files, code snippets, and more to projects in Anaconda Cloud, you can access your files from any machine with Excel and internet access.

**What are projects?**

You can think of projects as folders for storing your data files, which allow you to:

* Access your stored ``.csv`` files or code snippets from either Anaconda Notebooks or :doc:`Excel </excel/index>`
* Keep related ``.csv`` and ``.ipynb`` files organized 
* Execute bulk actions, such as uploading, downloading, and deleting files
* Set default environment kernels

For example, you can create a ``.csv`` file in Excel, :doc:`upload it to Anaconda Cloud </excel/toolbox/data>`, then pull that ``.csv`` data directly into a notebook in Anaconda Notebooks!

Creating a project
==================

Create a project using the following steps: 

#. Open Anaconda Toolbox.
#. Under **Anaconda Cloud**, click **Create a New Project**.
#. Enter a unique title for your project.
#. Select an environment for your project from the **Environment Location** dropdown.
#. Upload files to your project, or transfer files already saved in Anaconda Cloud. 

    .. note::

        You can upload any file type to your project, but the best options are ``.csv`` and ``.ipynb`` files under 100MB.

#. Click **Create Project**. Your project appears under **My Projects**.

.. tip::

    Save your new project and files by :ref:`pushing your project <sync-project>` to Anaconda Cloud.

Uploading files to a project
============================

Add files to a project using the following steps: 

#. Open Anaconda Toolbox.
#. Under **Anaconda Cloud**, click **My Projects**.
#. Click |action| actions beside the project, then click **Upload**.
#. Upload files to your project, or transfer files already saved in Anaconda Cloud. 
#. Click **Upload to Project**.

The file(s) appear in the project.

.. _share-project:

Sharing a project
=================

You can share projects you own with other users in your organizations using the following steps:

#. Under **Anaconda Cloud**, click **My Projects**.
#. Click |action| actions beside the project you want to share, then click |share-nodes| *Manage Permissions*.

    .. thumbnail:: ../../img/notebook_project_sharing.png
        :align: center

#. In the Manage Permissions dialog, select your organization from the dropdown under **Your Organizations**.

    .. note::
        
        Sharing projects with other users is only possible through a shared organization. To share with someone who is not a member of your organization, create a new organization for that user to join by clicking **Create new organization** beneath the organizations dropdown.

#. Under **Organization Users**, enter the email of the user(s) you want to share the project with, then click **Invite**.
#. Choose each user's :ref:`permission level <project-permission>`.
#. Click **Update Permissions**.

The user(s) then receive an email notifying them of the update to their permission level on your project and a link to Anaconda Notebooks.

.. _project-permission:

Permissions
-----------

Access to projects and the actions you can perform in them are determined by your permission level for the project. By default, you as the owner of your project have admin permissions; for projects owned by an organization, the admins of that organization have admin permissions for that project.

.. csv-table::
    :file: /csv/data-connections-permissions.csv
    :header-rows: 1


Creating a new notebook
=======================

Begin creating a new notebook from either the home page or directly in a project from **My Projects**:

.. tab-set::

    .. tab-item:: Home Page

        #. Click **Create a New Notebook**.
        #. Enter a unique name for your notebook.
        #. Select a project to store your notebook in.

    .. tab-item:: My Projects

        #. Click **My Projects**.
        #. Click |action| actions beside a project, then click **New Notebook**.
        #. Enter a unique name for your notebook.

4. Click **Create Notebook**. Your new notebook opens.
#. Select the kernel for your notebook in the **Assign a Kernel** dialog, then click **Assign**.

    .. tip::

        To always use the same kernel and prevent the dialog from appearing when creating a notebook, select the checkbox beside "Always start the preferred kernel". 
        
        To remove a project's preferred kernel, open an associated notebook, click the kernel in the top-right corner, and uncheck "Always start the preferred kernel". Alternatively, go to **Settings**, select *Settings Editor*, select *Notebook* from the left sidebar, and clear "Automatically Start Preferred Kernel".

You can now begin working in your new notebook.

.. _sync-project:

Syncing projects to Anaconda Cloud
==================================

While it's best practice to save your work as you go, an extra step is required to ensure your project files are securely uploaded to the cloud for easy retrieval and use on other machines and software.

Save a project to Anaconda Cloud by clicking |save| **Save project to the cloud** beside the project title.

.. thumbnail:: ../../img/notebook_toolbox_push.png
   :align: center

Sync your local projects with those stored on Anaconda Cloud by clicking |refresh| **Refresh Project** beside the project title.

.. warning::

    Refreshing your project(s) will synchronize your local files with those stored on Anaconda Cloud, *overwriting your local project files*. Make sure to save your projects to the cloud before refreshing to avoid losing any progress.

.. thumbnail:: ../../img/notebook_toolbox_pull.png
   :align: center

.. tip::

    Refresh all projects at once by clicking |refresh| **Refresh all projects** at the top of **My Projects**.

.. |action| raw:: html

        <svg width="1em" height="1em" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
    <path d="M7.5 4C8.325 4 9 3.325 9 2.5C9 1.675 8.325 1 7.5 1C6.675 1 6 1.675 6 2.5C6 3.325 6.675 4 7.5 4Z"/>
    <path d="M7.5 6C6.675 6 6 6.675 6 7.5C6 8.325 6.675 9 7.5 9C8.325 9 9 8.325 9 7.5C9 6.675 8.325 6 7.5 6Z"/>
    <path d="M7.5 11C6.675 11 6 11.675 6 12.5C6 13.325 6.675 14 7.5 14C8.325 14 9 13.325 9 12.5C9 11.675 8.325 11 7.5 11Z"/>
    </svg>

.. |save| raw:: html

    <svg width="1em" height="1em" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 448 512"><path d="M48 480H0V432 80 32H48 336L448 144V432v48H400 48zm352-48V163.9l-80-80V184v24H296 104 80V184 80H48V432H400zM128 80v80H272V80H128zm32 240a64 64 0 1 1 128 0 64 64 0 1 1 -128 0z"/></svg>

.. |refresh| raw:: html

    <svg width="1em" height="1em" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512"><path d="M496 200c0 13.3-10.7 24-24 24h0H360 328c-13.3 0-24-10.7-24-24s10.7-24 24-24h32 54.1l-52.1-52.1C333.8 95.8 295.7 80 256 80c-72.7 0-135.2 44.1-162 107.1c-5.2 12.2-19.3 17.9-31.5 12.7s-17.9-19.3-12.7-31.5C83.9 88.2 163.4 32 256 32c52.5 0 102.8 20.8 139.9 57.9L448 142.1V88l0-.4V56c0-13.3 10.7-24 24-24s24 10.7 24 24V200zM40 288H152c13.3 0 24 10.7 24 24s-10.7 24-24 24H97.9l52.1 52.1C178.2 416.2 216.3 432 256 432c72.6 0 135-43.9 161.9-106.8c5.2-12.2 19.3-17.8 31.5-12.6s17.8 19.3 12.6 31.5C427.8 424 348.5 480 256 480c-52.5 0-102.8-20.8-139.9-57.9L64 369.9V424c0 13.3-10.7 24-24 24s-24-10.7-24-24V312c0-13.3 10.7-24 24-24z"/></svg>

.. |share-nodes| raw:: html

   <svg class="inline" height="1em" width="1em" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 448 512"><path d="M448 112c0 44.2-35.8 80-80 80c-22.9 0-43.6-9.6-58.1-25l-151 75.5c.8 4.4 1.1 8.9 1.1 13.5s-.4 9.1-1.1 13.5l151 75.5c14.6-15.4 35.2-25 58.1-25c44.2 0 80 35.8 80 80s-35.8 80-80 80s-80-35.8-80-80c0-9.7 1.7-19 4.9-27.7L147.2 299.5c-14.3 22-39 36.5-67.2 36.5c-44.2 0-80-35.8-80-80s35.8-80 80-80c28.2 0 52.9 14.5 67.2 36.5l145.7-72.9c-3.2-8.6-4.9-17.9-4.9-27.7c0-44.2 35.8-80 80-80s80 35.8 80 80zM80 304a48 48 0 1 0 0-96 48 48 0 1 0 0 96zM416 112a48 48 0 1 0 -96 0 48 48 0 1 0 96 0zM368 448a48 48 0 1 0 0-96 48 48 0 1 0 0 96z"/></svg>

