Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updating Probability figures in Dan's chapter #29

Merged
merged 3 commits into from
Nov 9, 2022
Merged

Updating Probability figures in Dan's chapter #29

merged 3 commits into from
Nov 9, 2022

Conversation

amandakube
Copy link
Collaborator

No description provided.

@review-notebook-app
Copy link

Check out this pull request on  ReviewNB

See visual diffs & provide feedback on Jupyter Notebooks.


Powered by ReviewNB

@jesteria jesteria added the content textbook content label Nov 7, 2022
Copy link
Member

@jesteria jesteria left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cool. Question about the use of the <img> tag (below).

@@ -18,7 +18,7 @@
"\n",
"**Complement of an event**: The complement of an event $A$ is the event that $A$ does not occur, denoted by $A^C$. For the event $A$ defined above, $A^C$ is the event that more than half of the babies are boys, or the set of integers from 50 to 100.\n",
"\n",
"![](./img/venn_comp.png)\n",
"<img src=\"./img/complement.png\" width=\"400\"/> \n",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Any reason to use <img> and to set a width?

  • As far as I can tell, one of the advantages to using the Markdown-native syntax is that the textbook builder detects what you're doing and ensures the image is included. With this version, none of the images are included and these tags are broken. For that reason, I think we don't really want to use <img> tags at all.
  • The width is probably fine, but generally it's nice to allow the browser to figure out the best sizing, based on the image and layout. (And if we do need to control the sizing, there might be a more dynamic way.)

I would just tweak these to work with the textbook – the Markdown syntax is both textbook-compatible and less verbose – but, let me know if there's a reason behind the particular form you used.

image

@amandakube
Copy link
Collaborator Author

amandakube commented Nov 7, 2022 via email

@jesteria
Copy link
Member

jesteria commented Nov 9, 2022

OK cool. For reference, the textbook-standard syntax for setting such extended attributes is using either the image or the figure directive [ref].

(HTML is otherwise not parsed by the textbook builder, rather passed directly through as text. This is mainly an issue for images, which require extra processing.)

That said, there's an extension to catch <img> tags and convert them … so why not? I enabled the extension.

As for the static width, sure, 400px seems perfectly reasonable for this layout. (The layout appears to correctly handle the images regardless of the size of the window/viewport.)

If you think it helpful, I'll just see to it that the images are horizontally centered.

amandakube and others added 3 commits November 9, 2022 12:54
* adding simulations to causality section

* causality edits

* changing to python notebooks

* adding sampling simulations

* working on sampling simulations

* peer edits

* constructing sampling simulations

* finishing sampling simulations

* working on chapter 12

* added bias variance tradeoff

* bias variance tradeoff figure

* separate files

* remove full file

* fixing plot output

* editing histograms

* fixing figure not plotting

* changing names and headings

* made edits to ch11

* ch11edits

* ch12edits

* fix issue with tense

* Adding updated images

* Changing image references

* Removing old files

* Removing old union image

* Removing old complement image

* Removing old intersection image

* changing image size

* Changing image size

* Update Rules_Definitions.ipynb

* Update Rules_Definitions.ipynb

* Update Rules_Definitions.ipynb

* Update Rules_Definitions.ipynb

* changed image sizes

* removing incorrect merge
@jesteria jesteria merged commit d3d0f5f into uchicago-dsi:master Nov 9, 2022
SusannaLange pushed a commit to SusannaLange/textbook-datascience-1 that referenced this pull request Aug 16, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
content textbook content
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants