Skip to content

Commit

Permalink
Updated notebooks (#295)
Browse files Browse the repository at this point in the history
* updated example_restriction (#285)

Co-authored-by: Pei-Lun Xie <peilunx.jeff@gmail.com>

* small fixes (#294)

* allow run all on notebooks that have pip install for google colab

---------

Co-authored-by: Pei-Lun Xie <peilunx.jeff@gmail.com>
  • Loading branch information
manulera and JeffXiePL authored Oct 7, 2024
1 parent b26f931 commit 8543b7b
Show file tree
Hide file tree
Showing 10 changed files with 194 additions and 209 deletions.
12 changes: 8 additions & 4 deletions docs/notebooks/CRISPR.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,14 @@
"metadata": {},
"outputs": [],
"source": [
"# Install pydna \n",
"%%capture\n",
"!pip install pydna"
"# Install pydna (only when running on Colab)\n",
"import sys\n",
"if 'google.colab' in sys.modules:\n",
" %%capture\n",
" # Install the current development version of pydna (comment to install pip version)\n",
" !pip install git+https://github.com/BjornFJohansson/pydna@dev_bjorn\n",
" # Install pip version instead (uncomment to install)\n",
" # !pip install pydna\n"
]
},
{
Expand All @@ -54,7 +59,6 @@
"cell_type": "code",
"execution_count": null,
"metadata": {},

"outputs": [
{
"name": "stdout",
Expand Down
11 changes: 8 additions & 3 deletions docs/notebooks/Dseq.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,14 @@
"metadata": {},
"outputs": [],
"source": [
"# Install pydna \n",
"%%capture\n",
"!pip install pydna"
"# Install pydna (only when running on Colab)\n",
"import sys\n",
"if 'google.colab' in sys.modules:\n",
" %%capture\n",
" # Install the current development version of pydna (comment to install pip version)\n",
" !pip install git+https://github.com/BjornFJohansson/pydna@dev_bjorn\n",
" # Install pip version instead (uncomment to install)\n",
" # !pip install pydna\n"
]
},
{
Expand Down
11 changes: 8 additions & 3 deletions docs/notebooks/Dseq_Features.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,14 @@
"metadata": {},
"outputs": [],
"source": [
"# Install pydna \n",
"%%capture\n",
"!pip install pydna"
"# Install pydna (only when running on Colab)\n",
"import sys\n",
"if 'google.colab' in sys.modules:\n",
" %%capture\n",
" # Install the current development version of pydna (comment to install pip version)\n",
" !pip install git+https://github.com/BjornFJohansson/pydna@dev_bjorn\n",
" # Install pip version instead (uncomment to install)\n",
" # !pip install pydna\n"
]
},
{
Expand Down
11 changes: 8 additions & 3 deletions docs/notebooks/Example_CRISPR.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -75,9 +75,14 @@
"metadata": {},
"outputs": [],
"source": [
"#Install pydna for colab.\n",
"%%capture\n",
"!pip install git+https://github.com/BjornFJohansson/pydna.git@dev_bjorn"
"# Install pydna (only when running on Colab)\n",
"import sys\n",
"if 'google.colab' in sys.modules:\n",
" %%capture\n",
" # Install the current development version of pydna (comment to install pip version)\n",
" !pip install git+https://github.com/BjornFJohansson/pydna@dev_bjorn\n",
" # Install pip version instead (uncomment to install)\n",
" # !pip install pydna\n"
]
},
{
Expand Down
11 changes: 8 additions & 3 deletions docs/notebooks/Example_Gibson.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,14 @@
"metadata": {},
"outputs": [],
"source": [
"# Install pydna \n",
"%%capture\n",
"!pip install pydna"
"# Install pydna (only when running on Colab)\n",
"import sys\n",
"if 'google.colab' in sys.modules:\n",
" %%capture\n",
" # Install the current development version of pydna (comment to install pip version)\n",
" !pip install git+https://github.com/BjornFJohansson/pydna@dev_bjorn\n",
" # Install pip version instead (uncomment to install)\n",
" # !pip install pydna\n"
]
},
{
Expand Down
303 changes: 122 additions & 181 deletions docs/notebooks/Example_Restriction.ipynb

Large diffs are not rendered by default.

11 changes: 8 additions & 3 deletions docs/notebooks/Gibson.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,14 @@
"metadata": {},
"outputs": [],
"source": [
"# Install pydna \n",
"%%capture\n",
"!pip install pydna"
"# Install pydna (only when running on Colab)\n",
"import sys\n",
"if 'google.colab' in sys.modules:\n",
" %%capture\n",
" # Install the current development version of pydna (comment to install pip version)\n",
" !pip install git+https://github.com/BjornFJohansson/pydna@dev_bjorn\n",
" # Install pip version instead (uncomment to install)\n",
" # !pip install pydna\n"
]
},
{
Expand Down
11 changes: 8 additions & 3 deletions docs/notebooks/Importing_Seqs.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,14 @@
"metadata": {},
"outputs": [],
"source": [
"# Install pydna \n",
"%%capture\n",
"!pip install pydna"
"# Install pydna (only when running on Colab)\n",
"import sys\n",
"if 'google.colab' in sys.modules:\n",
" %%capture\n",
" # Install the current development version of pydna (comment to install pip version)\n",
" !pip install git+https://github.com/BjornFJohansson/pydna@dev_bjorn\n",
" # Install pip version instead (uncomment to install)\n",
" # !pip install pydna\n"
]
},
{
Expand Down
11 changes: 8 additions & 3 deletions docs/notebooks/PCR.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,14 @@
"metadata": {},
"outputs": [],
"source": [
"# Install pydna \n",
"%%capture\n",
"!pip install pydna"
"# Install pydna (only when running on Colab)\n",
"import sys\n",
"if 'google.colab' in sys.modules:\n",
" %%capture\n",
" # Install the current development version of pydna (comment to install pip version)\n",
" !pip install git+https://github.com/BjornFJohansson/pydna@dev_bjorn\n",
" # Install pip version instead (uncomment to install)\n",
" # !pip install pydna\n"
]
},
{
Expand Down
11 changes: 8 additions & 3 deletions docs/notebooks/Restrict_Ligate_Cloning.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,14 @@
"metadata": {},
"outputs": [],
"source": [
"# Install pydna \n",
"%%capture\n",
"!pip install pydna"
"# Install pydna (only when running on Colab)\n",
"import sys\n",
"if 'google.colab' in sys.modules:\n",
" %%capture\n",
" # Install the current development version of pydna (comment to install pip version)\n",
" !pip install git+https://github.com/BjornFJohansson/pydna@dev_bjorn\n",
" # Install pip version instead (uncomment to install)\n",
" # !pip install pydna\n"
]
},
{
Expand Down

0 comments on commit 8543b7b

Please # to comment.