Skip to content

Commit 045a7cf

Browse files
amkrajewskiamr8004
authored andcommitted
- added an example of 2D graph plotting using Wolfram Cloud
1 parent f3220a7 commit 045a7cf

File tree

1 file changed

+45
-11
lines changed

1 file changed

+45
-11
lines changed

SStoTi64.ipynb

+45-11
Original file line numberDiff line numberDiff line change
@@ -19285,18 +19285,18 @@
1928519285
},
1928619286
{
1928719287
"cell_type": "code",
19288-
"execution_count": 193,
19288+
"execution_count": 217,
1928919289
"metadata": {},
1929019290
"outputs": [],
1929119291
"source": [
1929219292
"key = SecuredAuthenticationKey(\n",
19293-
"'clientKey,\n",
19293+
"'clientKey',\n",
1929419294
"'privateKey')"
1929519295
]
1929619296
},
1929719297
{
1929819298
"cell_type": "code",
19299-
"execution_count": 194,
19299+
"execution_count": 218,
1930019300
"metadata": {},
1930119301
"outputs": [],
1930219302
"source": [
@@ -19305,7 +19305,7 @@
1930519305
},
1930619306
{
1930719307
"cell_type": "code",
19308-
"execution_count": 195,
19308+
"execution_count": 219,
1930919309
"metadata": {},
1931019310
"outputs": [
1931119311
{
@@ -19314,7 +19314,7 @@
1931419314
"(-3, 9)"
1931519315
]
1931619316
},
19317-
"execution_count": 195,
19317+
"execution_count": 219,
1931819318
"metadata": {},
1931919319
"output_type": "execute_result"
1932019320
}
@@ -19325,7 +19325,7 @@
1932519325
},
1932619326
{
1932719327
"cell_type": "code",
19328-
"execution_count": 196,
19328+
"execution_count": 220,
1932919329
"metadata": {},
1933019330
"outputs": [
1933119331
{
@@ -19342,7 +19342,7 @@
1934219342
},
1934319343
{
1934419344
"cell_type": "code",
19345-
"execution_count": 197,
19345+
"execution_count": 223,
1934619346
"metadata": {},
1934719347
"outputs": [],
1934819348
"source": [
@@ -19359,23 +19359,24 @@
1935919359
},
1936019360
{
1936119361
"cell_type": "code",
19362-
"execution_count": 198,
19362+
"execution_count": 205,
1936319363
"metadata": {},
1936419364
"outputs": [
1936519365
{
1936619366
"data": {
1936719367
"text/plain": [
19368-
"CloudObject['https://www.wolframcloud.com/obj/4e69ab39-5022-4848-be5b-899135b93cea']"
19368+
"CloudObject['https://www.wolframcloud.com/obj/7eb44350-505b-48df-80dc-2b6f982c107d']"
1936919369
]
1937019370
},
19371-
"execution_count": 198,
19371+
"execution_count": 205,
1937219372
"metadata": {},
1937319373
"output_type": "execute_result"
1937419374
}
1937519375
],
1937619376
"source": [
19377+
"# 3D\n",
1937719378
"session.evaluate(\n",
19378-
" wl.CloudPublish(\n",
19379+
" wl.CloudDeploy(\n",
1937919380
" wl.Show(\n",
1938019381
" wl.GraphPlot3D(\n",
1938119382
" wl.Map(wlEdges, trueEdges), \n",
@@ -19388,6 +19389,39 @@
1938819389
"))))"
1938919390
]
1939019391
},
19392+
{
19393+
"cell_type": "code",
19394+
"execution_count": 224,
19395+
"metadata": {},
19396+
"outputs": [
19397+
{
19398+
"data": {
19399+
"text/plain": [
19400+
"CloudObject['https://www.wolframcloud.com/obj/74e5afa4-4279-4d4e-a542-d3ba5837b232']"
19401+
]
19402+
},
19403+
"execution_count": 224,
19404+
"metadata": {},
19405+
"output_type": "execute_result"
19406+
}
19407+
],
19408+
"source": [
19409+
"# 2D\n",
19410+
"session.evaluate(\n",
19411+
" wl.CloudDeploy(\n",
19412+
" wl.Show(\n",
19413+
" wl.GraphPlot(\n",
19414+
" wl.Map(wlEdges, trueEdges), \n",
19415+
" wlexpr('VertexLabelStyle -> Directive[Green, Bold, 12]'),\n",
19416+
" wlexpr('DirectedEdges -> True'),\n",
19417+
" wlexpr('GraphLayout -> {\"SpringEmbedding\", \"InferentialDistance\" -> 3, \"MaxIteration\" -> 1000}'),\n",
19418+
" wlexpr('ViewProjection -> \"Orthographic\"'),\n",
19419+
" wlexpr('PerformanceGoal -> \"Quality\"'),\n",
19420+
" pureComponentLabels,\n",
19421+
" GraphHighlight=shortestPath\n",
19422+
"))))"
19423+
]
19424+
},
1939119425
{
1939219426
"cell_type": "code",
1939319427
"execution_count": 109,

0 commit comments

Comments
 (0)