j1-template 2022.2.3 → 2022.3.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (115) hide show
  1. checksums.yaml +4 -4
  2. data/assets/themes/j1/adapter/js/analytics.js +13 -13
  3. data/assets/themes/j1/adapter/js/nbinteract.js +192 -39
  4. data/assets/themes/j1/core/css/themes/unodark/bootstrap.css +30 -40
  5. data/assets/themes/j1/core/css/themes/unodark/bootstrap.min.css +1 -1
  6. data/assets/themes/j1/core/css/themes/unolight/bootstrap.css +23 -12
  7. data/assets/themes/j1/core/css/themes/unolight/bootstrap.min.css +1 -1
  8. data/assets/themes/j1/core/js/template.js +1 -1
  9. data/assets/themes/j1/core/js/template.min.js +1 -1
  10. data/assets/themes/j1/core/js/template.min.js.map +1 -1
  11. data/assets/themes/j1/modules/carousel/css/theme/uno.css +5 -0
  12. data/assets/themes/j1/modules/carousel/css/theme/uno.min.css +1 -1
  13. data/assets/themes/j1/modules/justifiedGallery/css/justifiedGallery.css +6 -0
  14. data/assets/themes/j1/modules/justifiedGallery/css/justifiedGallery.min.css +1 -1
  15. data/assets/themes/j1/modules/mmenuLight/css/mmenu-light.css +2 -2
  16. data/assets/themes/j1/modules/mmenuLight/css/mmenu-light.min.css +1 -2
  17. data/assets/themes/j1/modules/nbInteract/css/theme/uno/nbinteract-core.css +33 -33
  18. data/assets/themes/j1/modules/nbInteract/css/theme/uno/nbinteract-core.min.css +1 -1
  19. data/assets/themes/j1/modules/nbInteract/js/requireJS/require.js +2068 -0
  20. data/assets/themes/j1/modules/nbInteract/js/requireJS/require.min.js +36 -0
  21. data/assets/themes/j1/modules/plotly/LICENSE +21 -0
  22. data/assets/themes/j1/modules/plotly/README.md +32 -0
  23. data/assets/themes/j1/modules/plotly/js/plotly.js +265345 -0
  24. data/assets/themes/j1/modules/plotly/js/plotly.min.js +65 -0
  25. data/assets/themes/j1/modules/requirejs/LICENSE +45 -0
  26. data/assets/themes/j1/modules/requirejs/README.md +79 -0
  27. data/assets/themes/j1/modules/requirejs/js/require.js +2068 -0
  28. data/assets/themes/j1/modules/requirejs/js/require.min.js +36 -0
  29. data/lib/j1/version.rb +1 -1
  30. data/lib/starter_web/Gemfile +1 -1
  31. data/lib/starter_web/_config.yml +1 -1
  32. data/lib/starter_web/_data/modules/analytics.yml +8 -23
  33. data/lib/starter_web/_data/modules/defaults/analytics.yml +1 -1
  34. data/lib/starter_web/_data/modules/justifiedGallery.yml +14 -8
  35. data/lib/starter_web/_data/modules/navigator_menu.yml +6 -3
  36. data/lib/starter_web/_data/modules/nbinteract.yml +12 -48
  37. data/lib/starter_web/_data/resources.yml +56 -0
  38. data/lib/starter_web/_includes/attributes.asciidoc +11 -0
  39. data/lib/starter_web/_plugins/lunr_index.rb +1 -1
  40. data/lib/starter_web/assets/images/pages/nbinteract/mandelbrot-menge-1920x1200.jpg +0 -0
  41. data/lib/starter_web/assets/images/pages/nbinteract/mandelbrot-menge.png +0 -0
  42. data/lib/starter_web/assets/images/pages/nbinteract/manual/nbi_bar.jpg +0 -0
  43. data/lib/starter_web/assets/images/pages/nbinteract/manual/nbi_hist.jpg +0 -0
  44. data/lib/starter_web/assets/images/pages/nbinteract/manual/nbi_line.jpg +0 -0
  45. data/lib/starter_web/assets/images/pages/nbinteract/manual/nbi_multiple_choice.jpg +0 -0
  46. data/lib/starter_web/assets/images/pages/nbinteract/manual/nbi_scatter.jpg +0 -0
  47. data/lib/starter_web/assets/images/pages/nbinteract/manual/nbi_scatter_drag.jpg +0 -0
  48. data/lib/starter_web/assets/images/pages/nbinteract/manual/nbi_short_answer.jpg +0 -0
  49. data/lib/starter_web/assets/videos/gallery/kick-it-old-school-poster.jpg +0 -0
  50. data/lib/starter_web/assets/videos/gallery/nye-party-shop-poster.jpg +0 -0
  51. data/lib/starter_web/assets/videos/gallery/stay-colorful-poster.jpg +0 -0
  52. data/lib/starter_web/collections/posts/public/series/_posts/2020-01-01-post-wiki-series.adoc +1 -0
  53. data/lib/starter_web/collections/posts/public/series/_posts/2020-01-02-post-wiki-series.adoc +1 -0
  54. data/lib/starter_web/collections/posts/public/series/_posts/2020-01-03-post-wiki-series.adoc +1 -0
  55. data/lib/starter_web/package.json +1 -2
  56. data/lib/starter_web/pages/public/jupyter/docs/j1-nbinteract-doc.adoc +16 -16
  57. data/lib/starter_web/pages/public/jupyter/docs/nbi-widget-manual.adoc +149 -2
  58. data/lib/starter_web/pages/public/jupyter/docs/nbinteract-doc.adoc +1 -1
  59. data/lib/starter_web/pages/public/jupyter/examples/j1-circular-times-table.adoc +137 -0
  60. data/lib/starter_web/pages/public/jupyter/examples/j1-interactive-widgets.adoc +2 -2
  61. data/lib/starter_web/pages/public/jupyter/examples/j1-odes-in-python.adoc +11 -6
  62. data/lib/starter_web/pages/public/jupyter/examples/j1-testing-plotly.adoc +86 -0
  63. data/lib/starter_web/pages/public/jupyter/examples/j1_climate-change-forecast.adoc +2 -2
  64. data/lib/starter_web/pages/public/jupyter/notebooks/j1/.ipynb_checkpoints/j1_climate_change_forecast-checkpoint.ipynb +1058 -0
  65. data/lib/starter_web/pages/public/jupyter/notebooks/j1/{j1_ode_selected.ipynb → .ipynb_checkpoints/j1_docs_example_dynamic-checkpoint.ipynb} +1 -1
  66. data/lib/starter_web/pages/public/jupyter/notebooks/j1/.ipynb_checkpoints/j1_interactive_widgets-checkpoint.ipynb +20 -20
  67. data/lib/starter_web/pages/public/jupyter/notebooks/j1/.ipynb_checkpoints/{j1_altair_interactive_test-checkpoint.ipynb → j1_ode_selected-checkpoint.ipynb} +99 -318
  68. data/lib/starter_web/pages/public/jupyter/notebooks/j1/.ipynb_checkpoints/j1_odes_in_python-checkpoint.ipynb +15227 -0
  69. data/lib/starter_web/pages/public/jupyter/notebooks/j1/j1_circular_times_table.ipynb +12390 -0
  70. data/lib/starter_web/pages/public/jupyter/notebooks/j1/j1_climate_change_forecast.ipynb +2 -2
  71. data/lib/starter_web/pages/public/jupyter/notebooks/j1/j1_docs_example_dynamic.ipynb +1 -1
  72. data/lib/starter_web/pages/public/jupyter/notebooks/j1/j1_interactive_widgets.ipynb +20 -20
  73. data/lib/starter_web/pages/public/jupyter/notebooks/j1/j1_odes_in_python.ipynb +15227 -0
  74. data/lib/starter_web/pages/public/jupyter/notebooks/nbi-docs/.ipynb_checkpoints/nbi_docs_examples_variability_of_the_sample_mean-checkpoint.ipynb +323 -0
  75. data/lib/starter_web/pages/public/jupyter/notebooks/nbi-docs/.ipynb_checkpoints/nbi_docs_recipes_graphing-checkpoint.ipynb +387 -0
  76. data/lib/starter_web/pages/public/jupyter/notebooks/nbi-docs/.ipynb_checkpoints/nbi_docs_recipes_layout-checkpoint.ipynb +384 -0
  77. data/lib/starter_web/pages/public/jupyter/notebooks/nbi-docs/.ipynb_checkpoints/nbi_docs_tutorial_interact-checkpoint.ipynb +254 -0
  78. data/lib/starter_web/pages/public/jupyter/notebooks/nbi-docs/.ipynb_checkpoints/nbi_docs_tutorial_monty_hall-checkpoint.ipynb +732 -0
  79. data/lib/starter_web/pages/public/jupyter/notebooks/nbi-docs/nbi_docs_tutorial_monty_hall.ipynb +25 -26
  80. data/lib/starter_web/pages/public/jupyter/notebooks/textbooks/j1_circular_times_table.html +749 -0
  81. data/lib/starter_web/pages/public/jupyter/notebooks/textbooks/j1_climate_change_forecast.html +2 -2
  82. data/lib/starter_web/pages/public/jupyter/notebooks/textbooks/j1_docs_example_dynamic.html +186 -186
  83. data/lib/starter_web/pages/public/jupyter/notebooks/textbooks/j1_interactive_widgets.html +919 -919
  84. data/lib/starter_web/pages/public/jupyter/notebooks/textbooks/j1_odes_in_python.html +955 -0
  85. data/lib/starter_web/pages/public/jupyter/notebooks/textbooks/nbi_docs_recipes_interactive_questions.html +242 -242
  86. data/lib/starter_web/pages/public/jupyter/services/binderhub.adoc +3 -3
  87. data/lib/starter_web/pages/public/learn/roundtrip/100_present_images.adoc +1 -1
  88. data/lib/starter_web/pages/public/learn/roundtrip/100_present_videos.adoc +9 -15
  89. data/lib/starter_web/pages/public/learn/roundtrip/200_typography.adoc +1 -1
  90. data/lib/starter_web/pages/public/learn/roundtrip/300_icon_fonts.adoc +1 -1
  91. data/lib/starter_web/pages/public/learn/roundtrip/400_asciidoc_extensions.adoc +1 -1
  92. data/lib/starter_web/pages/public/learn/roundtrip/410_bs_modals_extentions.adoc +1 -1
  93. data/lib/starter_web/pages/public/learn/roundtrip/420_responsive_tables_extensions.adoc +1 -1
  94. data/lib/starter_web/pages/public/legal/en/300_privacy.adoc +117 -12
  95. data/lib/starter_web/utilsrv/_defaults/package.json +1 -1
  96. data/lib/starter_web/utilsrv/package.json +1 -1
  97. metadata +38 -22
  98. data/lib/starter_web/assets/videos/gallery/adriana-lima-poster.jpg +0 -0
  99. data/lib/starter_web/pages/public/jupyter/notebooks/binder/binder-launches.ipynb +0 -385
  100. data/lib/starter_web/pages/public/jupyter/notebooks/j1/.ipynb_checkpoints/Untitled-checkpoint.ipynb +0 -6
  101. data/lib/starter_web/pages/public/jupyter/notebooks/j1/.ipynb_checkpoints/binder-launches-checkpoint.ipynb +0 -385
  102. data/lib/starter_web/pages/public/jupyter/notebooks/j1/.ipynb_checkpoints/google_altair-checkpoint.ipynb +0 -33
  103. data/lib/starter_web/pages/public/jupyter/notebooks/j1/binder-launches.ipynb +0 -411
  104. data/lib/starter_web/pages/public/jupyter/notebooks/textbooks/binder-launches.html +0 -670
  105. data/lib/starter_web/pages/public/jupyter/notebooks/textbooks/j1_ode_selected.html +0 -186
  106. data/lib/starter_web/pages/public/jupyter/notebooks/themes/altair/excel.py +0 -55
  107. data/lib/starter_web/pages/public/jupyter/notebooks/themes/altair/ggplot.py +0 -108
  108. data/lib/starter_web/pages/public/jupyter/notebooks/themes/altair/ggplot2.py +0 -108
  109. data/lib/starter_web/pages/public/jupyter/notebooks/themes/altair/husky.py +0 -121
  110. data/lib/starter_web/pages/public/jupyter/notebooks/themes/altair/latimes.py +0 -149
  111. data/lib/starter_web/pages/public/jupyter/notebooks/themes/altair/pcolor.py +0 -6
  112. data/lib/starter_web/pages/public/jupyter/notebooks/themes/altair/quartz.py +0 -55
  113. data/lib/starter_web/pages/public/jupyter/notebooks/themes/altair/spacy_base.py +0 -94
  114. data/lib/starter_web/pages/public/jupyter/notebooks/themes/altair/spacy_mono.py +0 -158
  115. data/lib/starter_web/pages/public/jupyter/notebooks/themes/altair/sunsentinel.py +0 -125
@@ -58,7 +58,7 @@ resource_options:
58
58
  :binder-badge-enabled: false
59
59
  :binder--home: https://mybinder.org/
60
60
  :binder--docs: https://mybinder.readthedocs.io/en/latest/
61
- :binder-app-launch--tree: https://mybinder.org/v2/gh/jekyll-one/nbinteract-notebooks/main?urlpath=/tree
61
+ :binder-app-launch--tree: https://mybinder.org/v2/gh/jekyll-one/j1-binder-repo/main?urlpath=/tree
62
62
 
63
63
  // Load Liquid procedures
64
64
  // -----------------------------------------------------------------------------
@@ -103,6 +103,25 @@ hist_function (Array | (*args -> Array int | Array float)):
103
103
  histogram.
104
104
  ----
105
105
 
106
+ .Example
107
+ [source, python, role="noclip"]
108
+ ----
109
+ import nbinteract as nbi
110
+ import numpy as np
111
+
112
+ def hist_response_function(mean, sd, size=1000):
113
+ '''
114
+ Returns 1000 values picked at random from the normal
115
+ distribution with the mean and SD given.
116
+ '''
117
+ return np.random.normal(loc=mean, scale=sd, size=1000)
118
+
119
+ nbi.hist(hist_response_function, mean=(0, 10), sd=(0, 2.0, 0.2))
120
+ ----
121
+
122
+ .Rendered Histogram
123
+ lightbox::nbi-widget--hist[800, {data-nbi-widget--hist}, role="mt-3 mb-4"]
124
+
106
125
  === Options
107
126
 
108
127
  [source, python, role="noclip"]
@@ -147,6 +166,28 @@ y_fn (Array | (Array, *args -> Array int | Array float)):
147
166
  y-axis.
148
167
  ----
149
168
 
169
+ .Example
170
+ [source, python, role="noclip"]
171
+ ----
172
+ import nbinteract as nbi
173
+ import numpy as np
174
+
175
+ def categories(n):
176
+ return np.arange(n)
177
+
178
+ def heights(xs, offset):
179
+ return xs + offset
180
+
181
+ opts = {
182
+ 'ylim': (0, 20),
183
+ }
184
+
185
+ nbi.bar(categories, heights, n=(0, 10), offset=(1, 10), options=opts)
186
+ ----
187
+
188
+ .Rendered Barchart
189
+ lightbox::nbi-widget--bar[800, {data-nbi-widget--bar}, role="mt-3 mb-4"]
190
+
150
191
  === Options
151
192
 
152
193
  [source, python, role="noclip"]
@@ -168,7 +209,7 @@ interact_params (dict): Keyword arguments in the same format as
168
209
  ----
169
210
 
170
211
 
171
- == Scatter plot
212
+ == Interactive Scatter plot
172
213
 
173
214
  The widget `nbinteract.scatter_drag` generates an interactive scatter plot
174
215
  with the best fit line plotted over the points. The points can be dragged by
@@ -180,6 +221,23 @@ x_points (Array Number): x-values of points to plot
180
221
  y_points (Array Number): y-values of points to plot
181
222
  ----
182
223
 
224
+ .Example
225
+ [source, python, role="noclip"]
226
+ ----
227
+ import nbinteract as nbi
228
+ import numpy as np
229
+
230
+ x_coords = np.arange(10)
231
+ y_coords = np.arange(10) + np.random.rand(10)
232
+
233
+ opts = {'xlim': (0, 9), 'ylim': (0, 11), 'animation_duration': 250}
234
+
235
+ nbi.scatter_drag(x_coords, y_coords, options=opts)
236
+ ----
237
+
238
+ .Rendered interactive Scatter Plot
239
+ lightbox::nbi-widget--scatter-drag[800, {data-nbi-widget--scatter-drag}, role="mt-3 mb-4"]
240
+
183
241
  === Options
184
242
 
185
243
  [source, python, role="noclip"]
@@ -221,6 +279,21 @@ y_fn (Array | (Array, *args -> Array int | Array float)):
221
279
  scatter plot.
222
280
  ----
223
281
 
282
+ .Example
283
+ [source, python, role="noclip"]
284
+ ----
285
+ import nbinteract as nbi
286
+ import numpy as np
287
+
288
+ def x_values(n): return np.random.choice(100, n)
289
+ def y_values(xs): return np.random.choice(100, len(xs))
290
+
291
+ nbi.scatter(x_values, y_values, n=(0,200))
292
+ ----
293
+
294
+ .Rendered Scatter Plot
295
+ lightbox::nbi-widget--scatter[800, {data-nbi-widget--scatter}, role="mt-3 mb-4"]
296
+
224
297
  === Options
225
298
 
226
299
  [source, python, role="noclip"]
@@ -275,6 +348,8 @@ opts = {
275
348
  nbi.line(x_values, y_values, max=(10, 50), sd=(1, 10), options=opts)
276
349
  ----
277
350
 
351
+ .Rendered Line Plot
352
+ lightbox::nbi-widget--line[800, {data-nbi-widget--line}, role="mt-3 mb-4"]
278
353
 
279
354
  [source, python, role="noclip"]
280
355
  ----
@@ -316,3 +391,75 @@ interact_params (dict): Keyword arguments in the same format as
316
391
  parameter names, prefix the corresponding kwargs with `x__` and
317
392
  `y__`.
318
393
  ----
394
+
395
+ == Multiple Choice
396
+
397
+ Generates a multiple choice question that allows the user to select an
398
+ answer choice and shows whether choice was correct.
399
+
400
+ [source, python, role="noclip"]
401
+ ----
402
+ nbinteract.multiple_choice(question, choices, answers)
403
+ ----
404
+
405
+ .Example
406
+ [source, python, role="noclip"]
407
+ ----
408
+ import nbinteract as nbi
409
+
410
+ nbi.multiple_choice(question="Select all prime numbers.",
411
+ choices=['12', '3', '31'],
412
+ answers=[1, 2])
413
+ ----
414
+
415
+ .Rendered Multiple Choice
416
+ lightbox::nbi-widget--multiple-choice[800, {data-nbi-widget--multiple-choice}, role="mt-3 mb-4"]
417
+
418
+ === Options
419
+
420
+ [source, python, role="noclip"]
421
+ ----
422
+ question (str): Question text displayed above choices.
423
+
424
+ choices (list str): Answer choices that user can select.
425
+
426
+ answers (int | iterable int): Either an integer or iterable of
427
+ integers. Each integer in answers corresponds to the index of the
428
+ correct choice in `choices`.
429
+ ----
430
+
431
+ == Short Answer
432
+
433
+ Generates a short answer question that allows user to input an answer in
434
+ a textbox and a submit button to check the answer.
435
+
436
+ [source, python, role="noclip"]
437
+ ----
438
+ nbinteract.short_answer(question, answers, explanation=None)
439
+ ----
440
+
441
+ .Example
442
+ [source, python, role="noclip"]
443
+ ----
444
+ import nbinteract as nbi
445
+
446
+ nbi.short_answer('What is 1+1?', answers='2', explanation='1+1 is 2')
447
+ ----
448
+
449
+ .Rendered Short Answer
450
+ lightbox::nbi-widget--short-answer[800, {data-nbi-widget--short-answer}, role="mt-3 mb-4"]
451
+
452
+ === Options
453
+
454
+ [source, python, role="noclip"]
455
+ ----
456
+ question (str): The question being asked.
457
+
458
+ answers (str | list str | func): If a string, only that string will be
459
+ marked correct. If a list of string, any string in the list will be
460
+ marked correct. If a function, any input that causes the function
461
+ to return True will be marked correct.
462
+
463
+ explanation (str): The explanation to the question is displayed when
464
+ the user inputs the correct answer.
465
+ ----
@@ -65,7 +65,7 @@ resource_options:
65
65
  :binder-badge-enabled: false
66
66
  :binder--home: https://mybinder.org/
67
67
  :binder--docs: https://mybinder.readthedocs.io/en/latest/
68
- :binder-app-launch--tree: https://mybinder.org/v2/gh/jekyll-one/nbinteract-notebooks/main?urlpath=/tree
68
+ :binder-app-launch--tree: https://mybinder.org/v2/gh/jekyll-one/j1-binder-repo/main?urlpath=/tree
69
69
 
70
70
  // Load Liquid procedures
71
71
  // -----------------------------------------------------------------------------
@@ -0,0 +1,137 @@
1
+ ---
2
+ title: Time Tables
3
+ tagline: visualize patterns
4
+ date: 2022-03-28 00:00:00
5
+ description: >
6
+ The package nbinteract aims to enable authors and educators to create and
7
+ share interactive web pages easily. Interactive explanations of concepts are
8
+ useful for communicating and explaining tricky concepts.
9
+ keywords: >
10
+ opensource, free, load, download, start, starter, example,
11
+ high, easy, use, secure, encrypt, standard, popular,
12
+ generate, create, learn, distribute, publish, deploy,
13
+ beginner, advanced, expert, student, learner, writer, reader, visitor
14
+ framework, toolkit, integration, extension, module, api,
15
+ dynamic, static, generator, client, server, internet, local, localhost
16
+ page, web, website, webdesign, material, design, responsive,
17
+ javascript, nodejs, ruby, windows, linux, osx, mac, os,
18
+ http, https, html, html5, css, scss, style,
19
+ browser, firefox, chrome, edge, opera, safari,
20
+ configuration, generator, navigation, menu, dropdown, fab, action, button
21
+ application, interface, provider, api, repository,
22
+ cookie, language, translation, gdpr, dsgvo, privacy,
23
+ asciidoc, aciidoctor, bootstrap, jekyll, liquid,
24
+ hyvor, disqus, git, github, netlify, heroku, apple, microsoft,
25
+ provider, service, internet, support,
26
+ google, analytics, advertising, search, console, silverlight, score,
27
+ j1, template, jekyllone, comment,
28
+ python, jupyter, notebook, textbook, api, app, nbinteract,
29
+ nbi, integration, binder, binderhub, jupyterhub
30
+
31
+ categories: [ Software, Python ]
32
+ tags: [ Binder, Jupyter, Notebooks ]
33
+
34
+ scrollbar: false
35
+ fab_menu_id: open_toc_reload
36
+ personalization: true
37
+
38
+ permalink: /pages/public/jupyter/textbooks/j1-circular-times-table/
39
+ regenerate: false
40
+
41
+ resources: [ nbinteract, rouge ]
42
+ resource_options:
43
+ - attic:
44
+ padding_top: 400
45
+ padding_bottom: 50
46
+ opacity: 0.5
47
+ slides:
48
+ - url: /assets/images/pages/nbinteract/mandelbrot-menge-1920x1200.jpg
49
+ ---
50
+
51
+ // Page Initializer
52
+ // =============================================================================
53
+ // Enable the Liquid Preprocessor
54
+ :page-liquid:
55
+
56
+ // Set (local) page attributes here
57
+ // -----------------------------------------------------------------------------
58
+ // :page--attr: <attr-value>
59
+ :binder-badges-enabled: true
60
+ :binder-app-launch--tree: https://mybinder.org/v2/gh/jekyll-one/j1-binder-repo/main?urlpath=/tree
61
+ :binder-app-launch--notebook: https://mybinder.org/v2/gh/jekyll-one/j1-binder-repo/main?filepath=notebooks/j1/j1_circular_times_table.ipynb
62
+
63
+ :time-tables-visualization: https://elc.github.io/posts/times-tables/
64
+
65
+ // Load Liquid procedures
66
+ // -----------------------------------------------------------------------------
67
+ {% capture load_attributes %}themes/{{site.template.name}}/procedures/global/attributes_loader.proc{%endcapture%}
68
+
69
+ // Load page attributes
70
+ // -----------------------------------------------------------------------------
71
+ {% include {{load_attributes}} scope="global" %}
72
+
73
+
74
+ // Page content
75
+ // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
76
+ // image:/assets/images/badges/myBinder.png[Binder, link="https://mybinder.org/", {browser-window--new}]
77
+ // image:/assets/images/badges/docsBinder.png[Binder, link="https://mybinder.readthedocs.io/en/latest/", {browser-window--new}]
78
+ // See: https://towardsdatascience.com/ordinal-differential-equation-ode-in-python-8dc1de21323b
79
+
80
+ ifeval::[{binder-badges-enabled} == true]
81
+ image:/assets/images/badges/notebookBinder.png[Binder, link="{binder-app-launch--notebook}", {browser-window--new}]
82
+ image:https://mybinder.org/badge_logo.svg[Binder, link="{binder-app-launch--tree}", {browser-window--new}]
83
+ endif::[]
84
+
85
+ NOTE: All examples are taken from
86
+ link:{time-tables-visualization}[Time Tables Visualization - Finding Patterns, {browser-window--new}],
87
+ and re-written for the use of module J1 NBI. Some text is used from the
88
+ original post but re-written for clarity and simplicity.
89
+
90
+ First, let's introduce the video from _Mathologer_. This video creates very
91
+ nice patterns from _Times Tables_. Everybody knows them from primary school.
92
+ It's something like this:
93
+
94
+ .Table of *Two* (excerpt)
95
+ [cols="6a,6a", options="header", width="100%", role="rtable mt-3"]
96
+ |===
97
+ |Factor |Value
98
+
99
+ |`1 x 2`
100
+ |2
101
+
102
+ |`2 x 2`
103
+ |4
104
+
105
+ |`3 x 2`
106
+ |6
107
+
108
+ |`4 x 2`
109
+ |8
110
+
111
+ |===
112
+
113
+ The idea, in general, is surprisingly simple, but the results are surprising.
114
+ Please go for the video from _Mathologer_ first to catch the idea behind it.
115
+
116
+ In this document, several scenarios using _Times Tables_ as a base to
117
+ calculate plotted images are presented similar to the approach of
118
+ what _Mathologer_ is doing:
119
+
120
+ * a static but parametric version: you can change with sliders the values
121
+ and experiment by yourself.
122
+ * an animated version to construct the image Line by Line: the factor
123
+ and the number of points is fixed, but each line is plotted per iteration
124
+ * an animated version to construct the image Point by Point: the factor
125
+ and the lines are fixed, but each iteration increases the number of points
126
+ * an animated version to construct the image Factor by Factor: the lines
127
+ and the number of points is fixed, but the factor increases per iteration.
128
+
129
+ WARNING: Each scenario presented on this page uses *time-consuming*
130
+ operations that take a while to finish. The images and the interactive
131
+ elements are built through a backend in the cloud. Please be patient
132
+ to see the results.
133
+
134
+ Start your journey on the power of Mathematics!
135
+
136
+ // textbook::circular_times_table[]
137
+ textbook::j1_circular_times_table[]
@@ -62,8 +62,8 @@ resource_options:
62
62
  // -----------------------------------------------------------------------------
63
63
  // :page--attr: <attr-value>
64
64
  :binder-badges-enabled: true
65
- :binder-app-launch--tree: https://mybinder.org/v2/gh/jekyll-one/nbinteract-notebooks/main?urlpath=/tree
66
- :binder-app-launch--notebook: https://mybinder.org/v2/gh/jekyll-one/nbinteract-notebooks/main?filepath=notebooks/j1/j1_interactive.ipynb
65
+ :binder-app-launch--tree: https://mybinder.org/v2/gh/jekyll-one/j1-binder-repo/main?urlpath=/tree
66
+ :binder-app-launch--notebook: https://mybinder.org/v2/gh/jekyll-one/j1-binder-repo/main?filepath=notebooks/j1/j1_interactive_widgets.ipynb
67
67
 
68
68
 
69
69
  // Load Liquid procedures
@@ -1,5 +1,5 @@
1
1
  ---
2
- title: ODEs in Python
2
+ title: ODEs with Python
3
3
  tagline: interactive evaluation
4
4
  date: 2022-03-28 00:00:00
5
5
  description: >
@@ -57,9 +57,9 @@ resource_options:
57
57
  // -----------------------------------------------------------------------------
58
58
  // :page--attr: <attr-value>
59
59
  :binder-badges-enabled: true
60
- :binder-app-launch--tree: https://mybinder.org/v2/gh/jekyll-one/nbinteract-notebooks/main?urlpath=/tree
61
- :binder-app-launch--notebook: https://mybinder.org/v2/gh/jekyll-one/nbinteract-notebooks/main?filepath=notebooks/j1/j1_odes_in_python.ipynb
62
-
60
+ :binder-app-launch--tree: https://mybinder.org/v2/gh/jekyll-one/j1-binder-repo/main?urlpath=/tree
61
+ :binder-app-launch--notebook: https://mybinder.org/v2/gh/jekyll-one/j1-binder-repo/main?filepath=notebooks/j1/j1_odes_in_python.ipynb
62
+ :odes-in-python: https://elc.github.io/posts/ordinary-differential-equations-with-python/
63
63
  // Load Liquid procedures
64
64
  // -----------------------------------------------------------------------------
65
65
  {% capture load_attributes %}themes/{{site.template.name}}/procedures/global/attributes_loader.proc{%endcapture%}
@@ -81,7 +81,10 @@ image:https://mybinder.org/badge_logo.svg[Binder, link="{binder-app-launch--tree
81
81
  endif::[]
82
82
 
83
83
 
84
- == ODEs in Python
84
+ // See: https://elc.github.io/posts/ordinary-differential-equations-with-python/
85
+
86
+ NOTE: All examples are taken from
87
+ link:{odes-in-python}[Ordinary Differential Equations (ODE) with Python, {browser-window--new}]
85
88
 
86
89
  An ordinary differential equation (often abbreviated to ODE) is one
87
90
  Differential equation where only derivatives of the desired function
@@ -96,4 +99,6 @@ describing the dynamics of the population of rabbits and foxes. Check how
96
99
  the animals depend on each other. Manipulate some parameters to see the
97
100
  influences on the rabbits and foxes population.
98
101
 
99
- textbook::j1_ode_selected[]
102
+ // textbook::j1_ode_selected[]
103
+
104
+ textbook::j1_odes_in_python[]
@@ -0,0 +1,86 @@
1
+ ---
2
+ title: Testing Plotly
3
+ tagline: interactive evaluation
4
+ date: 2022-03-28 00:00:00
5
+ description: >
6
+ The package nbinteract aims to enable authors and educators to create and
7
+ share interactive web pages easily. Interactive explanations of concepts are
8
+ useful for communicating and explaining tricky concepts.
9
+ keywords: >
10
+ opensource, free, load, download, start, starter, example,
11
+ high, easy, use, secure, encrypt, standard, popular,
12
+ generate, create, learn, distribute, publish, deploy,
13
+ beginner, advanced, expert, student, learner, writer, reader, visitor
14
+ framework, toolkit, integration, extension, module, api,
15
+ dynamic, static, generator, client, server, internet, local, localhost
16
+ page, web, website, webdesign, material, design, responsive,
17
+ javascript, nodejs, ruby, windows, linux, osx, mac, os,
18
+ http, https, html, html5, css, scss, style,
19
+ browser, firefox, chrome, edge, opera, safari,
20
+ configuration, generator, navigation, menu, dropdown, fab, action, button
21
+ application, interface, provider, api, repository,
22
+ cookie, language, translation, gdpr, dsgvo, privacy,
23
+ asciidoc, aciidoctor, bootstrap, jekyll, liquid,
24
+ hyvor, disqus, git, github, netlify, heroku, apple, microsoft,
25
+ provider, service, internet, support,
26
+ google, analytics, advertising, search, console, silverlight, score,
27
+ j1, template, jekyllone, comment,
28
+ python, jupyter, notebook, textbook, api, app, nbinteract,
29
+ nbi, integration, binder, binderhub, jupyterhub
30
+
31
+ categories: [ Software, Python ]
32
+ tags: [ Binder, Jupyter, Notebooks ]
33
+
34
+ scrollbar: false
35
+ fab_menu_id: open_toc_reload
36
+ personalization: true
37
+
38
+ permalink: /pages/public/jupyter/textbooks/j1-testing-plotly/
39
+ regenerate: true
40
+
41
+ resources: [ nbinteract, require, rouge ]
42
+ resource_options:
43
+ - attic:
44
+ padding_top: 400
45
+ padding_bottom: 50
46
+ opacity: 0.5
47
+ slides:
48
+ - url: /assets/images/modules/attics/runner-1920x1200.jpg
49
+ ---
50
+
51
+ // Page Initializer
52
+ // =============================================================================
53
+ // Enable the Liquid Preprocessor
54
+ :page-liquid:
55
+
56
+ // Set (local) page attributes here
57
+ // -----------------------------------------------------------------------------
58
+ // :page--attr: <attr-value>
59
+ :binder-badges-enabled: true
60
+ :binder-app-launch--tree: https://mybinder.org/v2/gh/jekyll-one/j1-binder-repo/main?urlpath=/tree
61
+ :binder-app-launch--notebook: https://mybinder.org/v2/gh/jekyll-one/j1-binder-repo/main?filepath=notebooks/j1/j1_odes_in_python.ipynb
62
+
63
+ // Load Liquid procedures
64
+ // -----------------------------------------------------------------------------
65
+ {% capture load_attributes %}themes/{{site.template.name}}/procedures/global/attributes_loader.proc{%endcapture%}
66
+
67
+ // Load page attributes
68
+ // -----------------------------------------------------------------------------
69
+ {% include {{load_attributes}} scope="global" %}
70
+
71
+
72
+ // Page content
73
+ // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
74
+ // image:/assets/images/badges/myBinder.png[Binder, link="https://mybinder.org/", {browser-window--new}]
75
+ // image:/assets/images/badges/docsBinder.png[Binder, link="https://mybinder.readthedocs.io/en/latest/", {browser-window--new}]
76
+ // See: https://towardsdatascience.com/ordinal-differential-equation-ode-in-python-8dc1de21323b
77
+
78
+ ifeval::[{binder-badges-enabled} == true]
79
+ image:/assets/images/badges/notebookBinder.png[Binder, link="{binder-app-launch--notebook}", {browser-window--new}]
80
+ image:https://mybinder.org/badge_logo.svg[Binder, link="{binder-app-launch--tree}", {browser-window--new}]
81
+ endif::[]
82
+
83
+
84
+ == Plotly
85
+
86
+ textbook::j1_testing_plotly[]
@@ -58,8 +58,8 @@ resource_options:
58
58
  // -----------------------------------------------------------------------------
59
59
  // :page--attr: <attr-value>
60
60
  :binder-badges-enabled: true
61
- :binder-app-launch--tree: https://mybinder.org/v2/gh/jekyll-one/nbinteract-notebooks/main?urlpath=/tree
62
- :binder-app-launch--notebook: https://mybinder.org/v2/gh/jekyll-one/nbinteract-notebooks/main?filepath=notebooks/j1/j1_climate_change_forecast.ipynb
61
+ :binder-app-launch--tree: https://mybinder.org/v2/gh/jekyll-one/j1-binder-repo/main?urlpath=/tree
62
+ :binder-app-launch--notebook: https://mybinder.org/v2/gh/jekyll-one/j1-binder-repo/main?filepath=notebooks/j1/j1_climate_change_forecast.ipynb
63
63
 
64
64
  // Load Liquid procedures
65
65
  // -----------------------------------------------------------------------------