<p><div><div><div><div data-width="100" data-show-faces="false" data-send="true" data-layout="button_count" data-height="21" data-href="https://www.r-bloggers.com/one-year-of-r-notes/"></div></div><div><a data-url="https://www.r-bloggers.com/one-year-of-r-notes/" data-counturl="https://www.r-bloggers.com/one-year-of-r-notes/" data-count="horizontal" data-text="One year of R / Notes" class="twitter-share-button" data-via="rbloggers" href="https://twitter.com/share"></a></div><div></div></div><div></div></div>
<div>
(This article was first published on <strong><a href="http://f.briatte.org/r/one-year-of-r-notes"> R / Notes</a></strong>, and kindly contributed to <a rel="nofollow" href="https://www.r-bloggers.com/">R-bloggers)</a> </div>
<p>My <a target="_blank" href="http://f.briatte.org/r">collection of R notes</a> is now slightly over one year old. This note reflects on how useful the exercise of blogging about R has been so far, and answers some of the questions that I have received about it.</p>
<h2>Blogging about R</h2>
<p>I created my collection of R notes with the intention to keep track of technical notes that I often need to refer to when I work with other people.</p>
<p>My notes are usually very simple, at least at the mathematical level: my math skills are “read-only” skills, and I have nothing of interest to “showcase” in that area. Still, most of my R notes are more technical in nature than the kind of blog posts that I write for <a target="_blank" href="https://politbistro.hypotheses.org/">my academic blog</a>, which I write in French for an audience of social scientists.</p>
<p>Writing up “R / Notes” has forced me to simplify the code that I use. My impression is that, when I write code for others to read through, I like to streamline the code as much as possible, using <a target="_blank" href="https://cran.r-project.org/web/packages/magrittr/index.html">pipes</a> and as few R packages and lines of code as possible.</p>
<p>I also have the habit to use single-letter names for objects and to create as few of these objects as possible, but that is probably as much of a bad habit as a good one. I can trace that habit to many years ago, when I used to write <a target="_blank" href="https://en.wikipedia.org/wiki/TI-BASIC">TI-BASIC</a> code in high school…</p>
<h2>R-Bloggers syndication</h2>
<p>As the header of <a target="_blank" href="http://f.briatte.org/r">this collection</a> suggests, my R notes are syndicated on the <a target="_blank" href="https://www.r-bloggers.com/">R-Bloggers</a> aggregator, where most other existing R blogs are also syndicated.</p>
<p>Thanks to <a target="_blank" href="https://www.talgalili.com/">Tal Galili</a> for maintaining R-Bloggers, and for his help with syndicating this blog despite the fact that it is built on a customized version of the (discontinued?) <a target="_blank" href="https://github.com/Circa75/dropplets">Dropplets</a> static blog engine that produces slightly weird <a target="_blank" href="http://f.briatte.org/r/atom">Atom</a> and <a target="_blank" href="http://f.briatte.org/r/rss">RSS</a> feeds.</p>
<h2>Code embeds</h2>
<p>One question that has come up more than once about this collection of notes is: How do I embed the R code that shows up in the notes?</p>
<p>The answer is that I use <a target="_blank" href="https://gist.github.com/">Gist</a>, with a short bit of custom CSS to hide everything produced by its <a target="_blank" href="https://github.com/blog/122-embedded-gists">embed</a> method, except for the code and its line numbers:</p>
<p></p>
<p>The little bit of CSS code above corresponds to <a target="_blank" href="https://gist.github.com/briatte/cccefd51b08e77319a0c8f36b733f92a">this (secret) Gist</a>. The code to embed the Gist, which requires JavaScript, is shown at the top of the Gist.</p>
<h2>Math embeds</h2>
<p>Another question that has come up about this collection of notes is: How do I embed the math code that (occasionally) shows up in the notes?</p>
<p>In order to be able to use mathematical notation in some of my notes, I have turned, like many others, to the fantastic <a target="_blank" href="https://www.mathjax.org/">MathJax</a> library, which brings the power of <a target="_blank" href="https://en.wikipedia.org/wiki/LaTeX">LaTeX</a> typesetting to the Web.</p>
<p><div><div><div><div data-width="55" data-show-faces="false" data-send="true" data-layout="box_count" data-height="62" data-href="https://www.r-bloggers.com/one-year-of-r-notes/"></div></div><div><a data-url="https://www.r-bloggers.com/one-year-of-r-notes/" data-counturl="https://www.r-bloggers.com/one-year-of-r-notes/" data-count="vertical" data-text="One year of R / Notes" class="twitter-share-button" data-via="rbloggers" href="https://twitter.com/share"></a></div><div></div></div><div></div></div>
<div>
<div>To <strong>leave a comment</strong> for the author, please follow the link and comment on their blog: <strong><a href="http://f.briatte.org/r/one-year-of-r-notes"> R / Notes</a></strong>.</div>
<hr>
<a rel="nofollow" href="https://www.r-bloggers.com/">R-bloggers.com</a> offers <strong><a rel="nofollow" href="https://feedburner.google.com/fb/a/mailverify?uri=RBloggers">daily e-mail updates</a></strong> about <a title="The R Project for Statistical Computing" rel="nofollow" href="https://www.r-project.org/">R</a> news and <a title="R tutorials" rel="nofollow" href="https://www.r-bloggers.com/?s=tutorial">tutorials</a> on topics such as: <a title="Data science" rel="nofollow" href="https://www.r-bloggers.com/?s=data%20science">Data science</a>, <a title="Big Data" rel="nofollow" href="https://www.r-bloggers.com/?s=Big%20Data">Big Data, <a title="R jobs" rel="nofollow" href="https://www.r-users.com/">R jobs</a>, visualization (<a title="ggplot and ggplot2 tutorials" rel="nofollow" href="https://www.r-bloggers.com/?s=ggplot2">ggplot2</a>, <a title="Boxplots using lattice and ggplot2 tutorials" rel="nofollow" href="https://www.r-bloggers.com/?s=boxplot">Boxplots</a>, <a title="Maps and gis" rel="nofollow" href="https://www.r-bloggers.com/?s=map">maps</a>, <a title="Animation in R" rel="nofollow" href="https://www.r-bloggers.com/?s=animation">animation</a>), programming (<a title="RStudio IDE for R" rel="nofollow" href="https://www.r-bloggers.com/?s=RStudio">RStudio</a>, <a title="Sweave and literate programming" rel="nofollow" href="https://www.r-bloggers.com/?s=sweave">Sweave</a>, <a title="LaTeX in R" rel="nofollow" href="https://www.r-bloggers.com/?s=LaTeX">LaTeX</a>, <a title="SQL and databases" rel="nofollow" href="https://www.r-bloggers.com/?s=SQL">SQL</a>, <a title="Eclipse IDE for R" rel="nofollow" href="https://www.r-bloggers.com/?s=eclipse">Eclipse</a>, <a title="git and github, Version Control System" rel="nofollow" href="https://www.r-bloggers.com/?s=git">git</a>, <a title="Large data in R using Hadoop" rel="nofollow" href="https://www.r-bloggers.com/?s=hadoop">hadoop</a>, <a title="Web Scraping of google, facebook, yahoo, twitter and more using R" rel="nofollow" href="https://www.r-bloggers.com/?s=Web+Scraping">Web Scraping</a>) statistics (<a title="Regressions and ANOVA analysis tutorials" rel="nofollow" href="https://www.r-bloggers.com/?s=regression">regression</a>, <a title="principal component analysis tutorial" rel="nofollow" href="https://www.r-bloggers.com/?s=PCA">PCA</a>, <a title="Time series" rel="nofollow" href="https://www.r-bloggers.com/?s=time+series">time series</a>, <a title="finance trading" rel="nofollow" href="https://www.r-bloggers.com/?s=trading">trading</a>) and more...
<img height="1" alt="" width="1" src="http://feeds.feedburner.com/~r/RBloggers/~4/nkVmmEl6E4Q"></a></div>