Skip to content

Commit

Permalink
add_representation
Browse files Browse the repository at this point in the history
  • Loading branch information
hainm committed Dec 4, 2024
1 parent ffb158a commit d657fa6
Showing 1 changed file with 29 additions and 7 deletions.
36 changes: 29 additions & 7 deletions notebooks/molstarview.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
{
"data": {
"application/vnd.jupyter.widget-view+json": {
"model_id": "9b5586a7f3c243ceb16e803e97db27e5",
"model_id": "91ffff2fd7c543cda5b6c60af5e68769",
"version_major": 2,
"version_minor": 0
},
Expand All @@ -21,17 +21,16 @@
{
"data": {
"application/vnd.jupyter.widget-view+json": {
"model_id": "b71b8c0bdd014221b67768790f63fdb1",
"model_id": "7236255e5c194422b24c453987083e61",
"version_major": 2,
"version_minor": 0
},
"text/plain": [
"MolstarView()"
]
},
"execution_count": 1,
"metadata": {},
"output_type": "execute_result"
"output_type": "display_data"
}
],
"source": [
Expand Down Expand Up @@ -91,23 +90,46 @@
{
"data": {
"application/vnd.jupyter.widget-view+json": {
"model_id": "b71b8c0bdd014221b67768790f63fdb1",
"model_id": "7236255e5c194422b24c453987083e61",
"version_major": 2,
"version_minor": 0
},
"text/plain": [
"MolstarView()"
]
},
"execution_count": 4,
"metadata": {},
"output_type": "execute_result"
"output_type": "display_data"
}
],
"source": [
"view"
]
},
{
"cell_type": "markdown",
"id": "41b835c5-3a2a-4b34-b862-0c6eb4f6700e",
"metadata": {},
"source": [
"# Add representation"
]
},
{
"cell_type": "code",
"execution_count": 6,
"id": "5c15c428-8b99-42b0-887f-d767b08e7fd6",
"metadata": {},
"outputs": [],
"source": [
"params = {\n",
" \"type\": \"spacefill\",\n",
" \"typeParams\": { \"sizeFactor\": 0.5 },\n",
" \"color\": \"hydrophobicity\",\n",
" \"colorParams\": { \"scale\": \"DGwoct\" },\n",
"}\n",
"view.add_representation(**params)"
]
},
{
"cell_type": "markdown",
"id": "7afb6cdc-5bcf-4abf-9db3-cf204d624c67",
Expand Down

0 comments on commit d657fa6

Please sign in to comment.