{"id":2216,"date":"2022-01-24T15:36:55","date_gmt":"2022-01-24T15:36:55","guid":{"rendered":"http:\/\/optimumsportsperformance.com\/blog\/?p=2216"},"modified":"2022-01-24T15:36:55","modified_gmt":"2022-01-24T15:36:55","slug":"tidyx-91-rmarkdown-code-chunks-figure-options","status":"publish","type":"post","link":"https:\/\/optimumsportsperformance.com\/blog\/tidyx-91-rmarkdown-code-chunks-figure-options\/","title":{"rendered":"TidyX 91: RMarkdown &#8211; Code Chunks &#038; Figure Options"},"content":{"rendered":"<p>Picking up where we left off <strong><span style=\"color: #0000ff;\"><a style=\"color: #0000ff;\" href=\"https:\/\/optimumsportsperformance.com\/blog\/tidyx-90-rmarkdown-guide-formatting\/\">last week<\/a><\/span><\/strong>, <span style=\"color: #0000ff;\"><strong><a style=\"color: #0000ff;\" href=\"https:\/\/twitter.com\/ellis_hughes\">Ellis Hughes<\/a><\/strong><\/span> and I dive into controlling code chunks and figure options within your RMarkdown reports.<\/p>\n<p>We cover:<\/p>\n<p>1) How to show or hide your code in the report<br \/>\n2) How to show or hide the output of your code in a report<br \/>\n3) How to show code without having R run it in the report<br \/>\n4) Setting figure height, width, and alignment<br \/>\n5) Setting a figure caption<\/p>\n<p>The first RMarkdown file covers the basics &lt;<strong><span style=\"color: #0000ff;\"><a style=\"color: #0000ff;\" href=\"https:\/\/github.com\/thebioengineer\/TidyX\/blob\/master\/TidyTuesday_Explained\/091-Rmarkdown_Guide_Image_Outputs\/TidyX%20-%20Rmarkdown%20Chunk%20Options%20-%20Figures.Rmd\">CLICK HERE<\/a><\/span><\/strong>&gt;<\/p>\n<p>The second RMarkdown walks through a more nuanced example, where we scrape data from <strong><span style=\"color: #0000ff;\"><a style=\"color: #0000ff;\" href=\"https:\/\/www.basketball-reference.com\/\">basketball-reference.com<\/a><\/span><\/strong> and create a {<strong><span style=\"color: #000000;\">ggplot2<\/span><\/strong>} plot of Team Offensive and Defensive Rebounds &lt;<strong><span style=\"color: #0000ff;\"><a style=\"color: #0000ff;\" href=\"https:\/\/github.com\/thebioengineer\/TidyX\/blob\/master\/TidyTuesday_Explained\/091-Rmarkdown_Guide_Image_Outputs\/NBA%20-%20Example.Rmd\">CLICK HERE<\/a><\/span><\/strong>&gt;<\/p>\n<p>To watch the screen cast, <strong><span style=\"color: #0000ff;\"><a style=\"color: #0000ff;\" href=\"https:\/\/www.youtube.com\/watch?v=qH0YrXM07uU\">CLICK HERE<\/a><\/span><\/strong>.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Picking up where we left off last week, Ellis Hughes and I dive into controlling code chunks and figure options within your RMarkdown reports. We cover: 1) How to show or hide your code in the report 2) How to show or hide the output of your code in a report 3) How to show [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[44],"tags":[],"class_list":["post-2216","post","type-post","status-publish","format-standard","hentry","category-tidyx-screen-cast"],"_links":{"self":[{"href":"https:\/\/optimumsportsperformance.com\/blog\/wp-json\/wp\/v2\/posts\/2216","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/optimumsportsperformance.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/optimumsportsperformance.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/optimumsportsperformance.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/optimumsportsperformance.com\/blog\/wp-json\/wp\/v2\/comments?post=2216"}],"version-history":[{"count":1,"href":"https:\/\/optimumsportsperformance.com\/blog\/wp-json\/wp\/v2\/posts\/2216\/revisions"}],"predecessor-version":[{"id":2217,"href":"https:\/\/optimumsportsperformance.com\/blog\/wp-json\/wp\/v2\/posts\/2216\/revisions\/2217"}],"wp:attachment":[{"href":"https:\/\/optimumsportsperformance.com\/blog\/wp-json\/wp\/v2\/media?parent=2216"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/optimumsportsperformance.com\/blog\/wp-json\/wp\/v2\/categories?post=2216"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/optimumsportsperformance.com\/blog\/wp-json\/wp\/v2\/tags?post=2216"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}