Resizing plots in R Markdown

I made a lot of progress on one of my datasets today. It’s a 2 x 2 x 2 study, so it requires a fair amount of thinking in what the best way is to plot the data.

Lately I have been writing up my code in an R script, then when I’m happy with it, I plug it into R Markdown so I can see all the graphs at once.

When I plotted my 3-way interaction graphs, the group labels on the x-axis squished together because the default plot size was too small. So I looked up how to change the plot size in R Markdown and found this useful stackflow response.

Plot size in R Markdown

Plot size in R Markdown

So I tried it and voila! My plots look beautiful in R Markdown.

Plots in R Markdown

Plots in R Markdown


3 thoughts on “Resizing plots in R Markdown

  1. Milly

    Oj… Herlege bileter bÃ¥de frÃ¥ februar og april altsÃ¥, men trur eg heldt ein knapp pÃ¥ dei nystea;) Fin 1. mai til deg og! Likte bloggen din:)


  2. van insurence

    As I keep telling you, Theresa, great minds think alike ; ) I think we were separated at birth because we have such similar tastes and the books and movies you like I swear I like every one of them! I haven’t seen the video of “Take Peace”! Is that about Tasha? Oh, I’ll have to check it out!



Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s