<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Jacqueline Nolis on Medium]]></title>
        <description><![CDATA[Stories by Jacqueline Nolis on Medium]]></description>
        <link>https://medium.com/@jnolis?source=rss-1adb4927e341------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*uwHt3jdBwCmUlT5tHDrHuQ@2x.jpeg</url>
            <title>Stories by Jacqueline Nolis on Medium</title>
            <link>https://medium.com/@jnolis?source=rss-1adb4927e341------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Tue, 17 Nov 2026 01:52:28 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@jnolis/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com" rel="hub"/>
        <item>
            <title><![CDATA[TK is based on a flawed premise]]></title>
            <link>https://medium.com/@jnolis/tk-is-based-on-a-flawed-premise-17933cb8b77b?source=rss-1adb4927e341------2</link>
            <guid isPermaLink="false">https://medium.com/p/17933cb8b77b</guid>
            <category><![CDATA[medium]]></category>
            <category><![CDATA[tk]]></category>
            <category><![CDATA[writing]]></category>
            <dc:creator><![CDATA[Jacqueline Nolis]]></dc:creator>
            <pubDate>Thu, 12 Nov 2026 18:02:49 GMT</pubDate>
            <atom:updated>2026-11-12T18:02:49.120Z</atom:updated>
            <content:encoded><![CDATA[<p><em>You can’t make a tool to help writers if you don’t understand why people write.</em></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/930/1*Dcrs8wIsStqiBiIXqnkNdg.png" /><figcaption>This is bad, actually.</figcaption></figure><p>This week Medium launched it’s newest product, TK, with the phrase “<a href="https://medium.com/blog/tk-a-new-private-notebook-app-from-medium-13d3d6efdce1">we are betting on human intelligence.</a>” Tony continues with a very long, perhaps even meandering, post discussing how he believes the future of human writing is based on using artificial intelligence. The comments on the post, along with articles promoting the release, are filled with people upset about adding AI to writing.</p><p>There is an obvious reason why <em>readers</em> don’t want artificial intelligence in writing — AI makes it harder to tell if you’re reading valuable knowledge from an expert or AI slop generated with a few clicks. Some evidence is that Medium traffic is <a href="https://www.linkedin.com/feed/update/urn:li:activity:7524139740447584256/">down 35% this year</a>. What’s bad for readers is bad for writers — if other writing is AI slop why would people trust <em>your</em> writing? But there is a bigger issue for writers around the question: “why do we write in the first place?”</p><p>Part of the value of writing, as directly mentioned by the leadership at Medium, is that the activity itself helps you as a person. Writing helps you think through ideas by forcing you to write them down. The act of having to structure and order concepts means you can’t just understand them at a surface level, you have to explore them more deeply. Further, if you plan on sharing your writing with other people then you must structure the ideas in a way that the audience will understand. You need to think through your ideas through the lens of the audience. Taking ideas in your head and making them stronger is almost certainly a Good Thing. People smarter than me have been saying this for a long time (<a href="https://www.theatlantic.com/magazine/archive/1893/05/the-english-question/634214/">here is an essay about it from 1893!</a>).</p><p>TK, however, is designed to not have you stop writing when you get stuck. The moment you aren’t sure how to structure an argument or make a plot twist, it will give you a suggestion. Don’t know what the murderer should say when he grabs the gun? The agent will tell you. Need some reasons why you should get more exercise? The agent will tell you. It will give you answers any time you get to a struggling point.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*hn8gVNvEPCyFrt2SgeW6aQ.png" /><figcaption>Sorry not sorry.</figcaption></figure><p>If you believe that the value of writing is to help you think through your ideas, this is terrible. The act of getting stuck and figuring out what to is the very thing that helps you better understand your idea. Imagine a company announcing: “We think going to the gym is important, so we made a robot that lifts weights for you!” Certainly it does make going to the gym easier, but in doing so it loses the purpose of it.</p><p>Writing isn’t the only field having to reckon with AI changing the purpose of it — right now the domain of theoretical mathematics is trying to <a href="https://www.theverge.com/ai-artificial-intelligence/1004933/ai-math-openai-breakthrough-solution">figure out what it means</a> for humans to prove things if AI can do it dramatically faster with little prompting. But at least there you argue the benefit of using AI for proving math is the world then knows more things about mathematics. If the point of writing is to help yourself improve then there is no gain to this.</p><p>Unless the point of writing is not to help the writer to improve but instead to help convey ideas from writers to readers. In that case AI is definitely bad because (again) it is making it impossible to promote good writing when every good piece of writing is surrounded with AI slop.</p><p>So whatever your reason is for writing, TK probably isn’t the tool for it. TK shows a lack of understanding for users, and people are so upset over it they are <a href="https://jacquelinedooley.substack.com/p/an-unsolicited-opinion-of-mediums">leaving the Medium platform entirely</a>.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=17933cb8b77b" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Pretending to have a SQL database with RStudio]]></title>
            <link>https://medium.com/@jnolis/pretending-to-have-a-sql-database-with-rstudio-e80d9a1338b1?source=rss-1adb4927e341------2</link>
            <guid isPermaLink="false">https://medium.com/p/e80d9a1338b1</guid>
            <category><![CDATA[sql]]></category>
            <category><![CDATA[r]]></category>
            <category><![CDATA[rstudio]]></category>
            <category><![CDATA[data-science]]></category>
            <dc:creator><![CDATA[Jacqueline Nolis]]></dc:creator>
            <pubDate>Wed, 29 Jul 2020 17:37:31 GMT</pubDate>
            <atom:updated>2020-07-29T20:14:18.714Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*seEDNk14Yenmm96wPaElNw.png" /></figure><p>Here is a data team riddle for you. Suppose you had an analyst on your team who loves working with SQL. Unfortunately, none of your data is in a SQL database, instead it is scattered across csv files, in AWS S3 buckets, whatever. The data isn’t particularly large, but the fact that it’s scattered and not in a SQL database is making it a real hassle for the analyst to do their job. And because of IT requirements, you can’t just go make a SQL database to put it all in. How can you, intrepid data team member, create a way for this analyst to easily write SQL queries on the data in a nice maintainable GUI without you having to set up and run a complex SQL database yourself? And without the analyst having to learn another programming language besides SQL?</p><p>One answer it turns out, is with RStudio.</p><p>While RStudio Desktop and RStudio Server are integrated development environments that were originally made to handle R, they can now interoperate with other languages surprisingly well, including Python and SQL. In this riddle of a situation where an analyst wants SQL, we could write a small R script that loads the data from whatever format it’s originally stored in and into an in-memory SQLite database using R. Then, once we have in-memory SQLite tables of data, the analyst can query the code using SQL commands to their delight. By wrapping it all in an RMarkdown file all of the commands can be run and the analysis output can be recorded and saved in an easy way.</p><p>First, it’s only a little bit of R code to create a SQL database in-memory in R, then load tables into it. All you need to do is use the DBI and RSQLite packages. The R code below does two things. First, it creates a connection con to a new SQLite in-memory database with DBI and RSQLite. Second, it loads some tables from csv files into that database. Each read.csv command reads a table from a csv file, then the dbWriteTable command wrapped around places the table into the database. Below is an example R script that sets this up.</p><pre>library(DBI)</pre><pre>con &lt;- dbConnect(RSQLite::SQLite(), dbname = &quot;:memory:&quot;)</pre><pre>dbWriteTable(con, &quot;customers&quot;, read.csv(&quot;customer_data.csv&quot;))<br>dbWriteTable(con, &quot;orders&quot;, read.csv(&quot;orders.csv&quot;))</pre><p>R is really flexible and can load data from tons of places! So if instead of a csv file you had an Excel file you could use readxl::readxlsx or you could pull data from the cloud or do a million other things to get data into the table. The analyst could learn a few commands to load data without really having to learn R in full and instead mostly staying in the SQL world.</p><p>Now from the same R script, you can use SQL queries on those tables with the dbGetQuery command:</p><pre>dbGetQuery(&quot;SELECT * FROM customers LIMIT 10&quot;)</pre><p>While it has that slightly pesky dbGetQuery() wrapper, this is otherwise just a standard SQL query that the analyst should feel comfortable writing. So for each SQL query the analyst wants to write, they can use a dbGetQuery() command.</p><p><em>But wait, it gets way better with RMarkdown!</em></p><p>So that’s pretty decent, but it becomes amazing when you put it in an RMarkdown file. An RMarkdown file lets you split your code into chunks and include formatted text between the code. The code chunks don’t have to be just R, they can also be SQL. Which means you can write an RMarkdown file like this:</p><pre>## Here is the setup code!</pre><pre>```{r setup}<br>library(DBI)</pre><pre>con &lt;- dbConnect(RSQLite::SQLite(), dbname = &quot;:memory:&quot;)</pre><pre>dbWriteTable(con, &quot;customers&quot;, read.csv(&quot;customer_data.csv&quot;))<br>dbWriteTable(con, &quot;orders&quot;, read.csv(&quot;orders.csv&quot;))<br>```</pre><pre>## Here is the sql code!</pre><pre>```{sql, connection=con}<br>SELECT * FROM customers LIMIT 10<br>```</pre><pre>## And here is different sql code!</pre><pre>```{sql, connection=con}<br>SELECT * FROM orders LIMIT 10<br>```</pre><p>So now each of the analysts queries can be a nice SQL chunk in the RMarkdown file with descriptive text before and after. And the Rmarkdown file can be knitted into a nice HTML output that includes all the queries, the text, and the outputs:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*pORtAot75kyxFx4c06GPhA.png" /></figure><p>This Rmd file and the corresponding HTML output is a great way for an analyst to do SQL work and save it (in the Rmd file) as well as save a record of what the actual output was (in the HTML file). It really beats the more traditional method of “save each output as a separate csv” or the tragic “copy and paste the results from SQL Server Management Studio into Excel” that are often used by analysts with SQL</p><p>The somewhat unusual case of a SQL using analyst who doesn’t have a SQL database is rare, but the case of “a person doesn’t quite have the data in a way they want it” is common. This example goes to show that R and RStudio are extremely good tools for bridging that gap between desires and reality with a toolset that data experts have built up to be incredibly flexible and customizable.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=e80d9a1338b1" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[R Docker faster]]></title>
            <link>https://medium.com/@jnolis/r-docker-faster-28e13a6d241d?source=rss-1adb4927e341------2</link>
            <guid isPermaLink="false">https://medium.com/p/28e13a6d241d</guid>
            <category><![CDATA[r]]></category>
            <category><![CDATA[docker]]></category>
            <category><![CDATA[data-science]]></category>
            <category><![CDATA[rstudio]]></category>
            <dc:creator><![CDATA[Jacqueline Nolis]]></dc:creator>
            <pubDate>Tue, 07 Jul 2020 04:50:51 GMT</pubDate>
            <atom:updated>2020-07-07T14:40:28.078Z</atom:updated>
            <content:encoded><![CDATA[<h4>My experiment shows R Docker images will build much faster thanks to the new package manager from RStudio</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*0rGjEuOE46LUpfbFVPLRyA.jpeg" /></figure><p>If you’ve ever tried using R in a Docker container (and you <a href="https://medium.com/tmobile-tech/using-docker-to-deploy-an-r-plumber-api-863ccf91516d">really</a> <a href="https://opensource.t-mobile.com/blog/posts/r-tensorflow-api/">should</a>!), you may have discovered how wonderful of a tool it is for <a href="http://putrinprod.com">putting R into production</a>. With Docker, you can use a Dockerfile to specify how an image of a computer is built, and then you can easily run those images as containers in a repeatable fashion. Unfortunately, the process of building an image for using R can be really slow — sometimes taking up to half an hour! The process has been slow because building an image requires the installation each R package required. The process of compiling R packages in linux can be really slow as it requires lots of compiling C++ on the backend. And you may have to rerun all of these package installation steps every time you make changes to what’s in the image. Over the course of developing a piece of production R code you may have had to build the image 50 times. So because of that having long build times can really be a drain.</p><h3></h3><p></p><p>Thankfully, that changed this week as RStudio announced a<a href="https://blog.rstudio.com/2020/07/01/announcing-public-package-manager/"> new public package manager</a>. Their package manager does several things that are very helpful for putting R in production:</p><ul><li>RStudio takes snapshots of all R packages on CRAN several times a week. This means that their packages will always be the same for a given snapshot, and you can trust that your Docker images will be deterministic. So you don’t have to worry that rebuilding a Docker image months in the future will have packages with different code in them. Previously this functionality was available from MRAN (Microsoft’s daily snapshots of CRAN), so now we have <em>two</em> companies taking snapshots of CRAN continuously. Nice.</li><li>Their package manager includes Linux binaries. This means that Docker containers that pull packages from RStudio’s package manager won’t have to do the laborious task of recompling all of the package code each time the image is rebuilt. This should absolutely solve the problem of Docker builds taking forever. Since compiling the binaries was the slow part.</li></ul><p>And the good news is that if you’re using <a href="https://hub.docker.com/u/rocker">Rocker images for R in Docker</a> (which if you followed me and Heather’s blog posts from earlier, or <a href="https://github.com/nolis-llc/pet-names">our Keras pet names generator repo</a>, or <a href="https://github.com/tmobile/r-tensorflow-api">T-Mobile’s R TensorFlow API repo</a>, you already are), then getting the cool new RStudio package manager is a breeze! By updating your Rocker base image to R version 4.0.0 or above you’ll be using RStudio’s package manager.</p><p>But does RStudio’s package manager truly make a difference in run time? I decided to find out. I ran a test where I made a docker image that only installed a single R package: dplyr. The package dplyr always takes foreeeeever to build. It both has a lot of R dependencies, and also has a lot of C++ to compile. This almost always is the longest package to install for any R Docker image I’ve personally worked with.</p><p>For the experiment I built two different Docker images, one without RStudio’s package manager and one with it, and time just the step of installing dplyr:</p><pre># Uses MRAN for packages (should be slow)<br>FROM rocker/r-ver:3.6.3<br>RUN install2.r --error dplyr</pre><p>vs</p><pre># Uses RStudio for packages (should be faster)<br>FROM rocker/r-ver:4.0.0<br>RUN install2.r --error dplyr</pre><p>The results? The MRAN installation took 4 minutes and 33 seconds, while the RStudio package manager one took 1 minute and 29 seconds. <strong>That’s less than 1/3rd the time to build</strong>, and the only work required was to change 3 characters in the Dockerfile.</p><p>So hopefully with this new system in the world 30 minute R Docker builds will be a thing of my past, and something that will be passed down in data science lore as “the dark times.”</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=28e13a6d241d" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Using data science to analyze my data science book]]></title>
            <link>https://medium.com/@jnolis/using-data-science-to-analyze-my-data-science-book-830aacca3c7e?source=rss-1adb4927e341------2</link>
            <guid isPermaLink="false">https://medium.com/p/830aacca3c7e</guid>
            <category><![CDATA[r]]></category>
            <category><![CDATA[analysis]]></category>
            <category><![CDATA[data-science]]></category>
            <category><![CDATA[careers]]></category>
            <dc:creator><![CDATA[Jacqueline Nolis]]></dc:creator>
            <pubDate>Tue, 24 Mar 2020 15:43:08 GMT</pubDate>
            <atom:updated>2020-08-16T04:36:51.808Z</atom:updated>
            <content:encoded><![CDATA[<h4>An extremely meta analysis of the book <a href="http://bestbook.cool"><em>Build a Career in Data Science</em></a></h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*hXdMz906Odut9kjXy-ZkuA.png" /></figure><p>With the publication of the book <a href="http://bestbook.cool"><em>Build a Career in Data Science</em></a> by me and <a href="https://twitter.com/robinson_es">Emily Robinson</a>, I couldn’t wait to use some of the techniques from the book on the book itself. Build a Career in Data Science covers all the non-technical skills you need to know to become a data scientist — from making a great resume to managing stakeholders. There is a great method covered in an entire chapter of the book (chapter 4) to help you get into data science, keep your skills, strong, and make you more marketable for future jobs: <em>building a portfolio of data science projects</em>. So in a true ouroboros of a blog post, I will do a side project where the dataset I’m analyzing is each change to the book itself as we’ve written it.</p><p>So let’s get cracking on the project! Thankfully, chapter 10 of the book is all about how to make an analysis. I used a technique from that chapter and created an <em>analysis plan</em> before I started doing any data science. When working on data science projects it’s very easy to lose focus on what your goal is and pursue whatever part of the data is most interesting to you in the moment. Having a plan makes you less likely to waste time on approaches that don’t pan out. Here is the analysis plan from when I started the project:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*XL9RKlqi0pkOz4VU7PPlYg.png" /><figcaption>My analysis plan at the start of analyzing the data. Spoiler alert: the first half took way longer than expected so I didn’t do the second part.</figcaption></figure><h3>Gathering the data</h3><p>The documents containing the manuscript itself were in our GitHub repository, and they included one document per chapter plus a bunch of documents for things like the acknowledgments and appendix full of interview questions. For the analysis I chose to use the programming language R, because I love R. That being said the material in the book itself is language agnostic. I needed to write code that would turn the repository into an R data frame that contains the text at each commit at the time of writing it:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*duD-Tc9tDU52zny_u532Ig.png" /><figcaption>Steps for creating and cleaning the dataset.</figcaption></figure><p>While I ultimately was able to collect all the data, it took my <em>waaaay</em> longer than I expected it to. Some of the many problems I had to deal with were:</p><ul><li><strong>The way we stored the manuscript changed over time.</strong> In the beginning we would name chapters things like ch07_the_interview.md with an abbreviation of the chapter name in the file. That later switched to ch07_build_career.docx . Not only did the file names change to “build_career” to fit the publisher’s specifications, but we had to switch from markdown documents to word documents because apparently when you’re writing a book the “publisher” cares about “format and styling” so we needed to use their template.</li><li><strong>We broke our own standards all the time.</strong> If a document should have been named ch07_build_career.docx, we as fallible humans would occasionally do things like ch07-build-career.docx and catching all the mistakes when reading the data in was hard.</li><li><strong>We stored files with our manuscript that made our data weird.</strong> In the book we talk about <em>weird </em>data as data that was totally implausible that indicated something was wrong, such as data showing an airplane landed before it took off. When collecting this book data I would occasionally see implausible values, and it would turn out to be things like accidentally including an entire 1 hour transcript of an interview we did into the text. This took work to clean up.</li></ul><p>This problem of having the data collection take longer than you expect is something we cover in the book too. It’s totally natural and normal for data to be messy since it’s usually created in messy ways. As a data scientist, it’s your job to accept what you’ve been given and do the best with it. If you can find ways to improve the data collection process and make the data come cleaner that’s great, but don’t avoid doing work just because you have to spend more time on the setup than you’d like.</p><h3>The findings</h3><p>Here are three findings from the analysis that I thought were worth sharing. They were all made using only R and a few packages such as tidyverse and lubridate.</p><h4>Book length over time</h4><p>Here is a plot showing how the word count grew over time, colored by which author made that commit:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*LdlJlrtipfvPAmeLrLaX9A.png" /><figcaption>The word count of our book over the 19 months it took to write it.</figcaption></figure><p>When you look at the word count a couple things pop out right away. Overall, it seems like the writing went at a fairly consistent rate. It looks like we wrote somewhere around 50k words every three months. Both Emily and I wrote fairly consistently throughout the process with a couple of times where only one of us wrote. There are a few gaps in the writing, such as November 2018 or May 2019, and those were usually us waiting for feedback from the publisher before continuing. There was a strange jump in words December 2019 — that was us adding the end matter to the book (with interview questions and suggested resources) from its previously draft state. We didn’t just 15k words in one day.</p><p>Looking at this graph I think we can learn two things about the writing process. First, it really works by you chipping away at it over time. Having a few all nighters isn’t a great way to write a 350 page book. Second, having some points in the writing where things go slower isn’t a death sentence. If you need to wait two weeks for the publisher to get back to you or take a two week vacation your book can probably survive it.</p><h4>Chapter growth</h4><p>Here is that same data from before, but now the chapters are split to individual charts.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*qHoghouUMwVA2tMaxqEXkQ.png" /><figcaption>Progression of the chapter writing</figcaption></figure><p>Most of the chapters, such as chapters 6–14, have one or two core weeks where they are mostly written and then edits are made until the book is published. A few chapters, like chapters 2 and 3, have a more gradual build up as they get added to over time. These chapters took a couple of takes to get right during the writing process. Almost all of the chapters have a single commit that adds a lot of words near the end: that’s from us adding an interview with an interesting data scientist to the end of each chapter. Chapters 15 and 16 are also peculiar; I started writing chapter 15 when I first began work on the book, then didn’t touch it for months, and then renumbered it as chapter 16 before actually finishing it.</p><p>This data is indicative of Emily’s and my writing style — we would each pick a chapter and work on them simultaneously until they were done, then edit the other person’s work, add the interview, then call the chapter basically done and move on. In theory you could have a single author write multiple chapters and bounce between them as they feel like it, but to me that seems really hard to do. By quickly powering through a chapter you have the highest chance of it having a consistent, interesting narrative.</p><h4>When the writing was done</h4><p>For fun, I was interested in comparing when I would do my writing to when Emily would. While Emily made overall more commits than me since she would make smaller amounts of changes for each commit, that shouldn’t affect any patterns of when they were done. Here is a box plot showing when we made our commits, adjusted for the fact that we worked in different time zones and split by weekday and weekend:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Gy5qUIMH_Odi8nGOdAwh9g.png" /><figcaption>Me and Emily’s commits to our repository by time</figcaption></figure><p>There are a few interesting things here. First, for both me and Emily on weekdays half of our writing was done after 8pm and less than 25% was done before 2pm. It makes sense that we don’t do very much work before 2pm, because we both had day jobs besides “spend a year writing a book.” Emily is a little bit more of a night owl then me, since she committed after 10pm almost 50% more than me. On weekends Emily tends to work in the morning and afternoon whereas I work in the evening.</p><p>Within this data are two differences between us that happen to be connected. First, I tend to write more in the very early morning then Emily — she has a single commit before 8am whereas I have plenty between 6 and 8am. I also have a huge gap in my commits between 4 and 7pm and Emily doesn’t. Both of these are because my family, unlike hers, includes a toddler. Raising a human child places a burden on me and my wife — some of the only times I got that were distraction free were before 7am. Between 4 and 7pm my wife Heather and I were both back from work making dinner and spending time with our child. Our child’s bedtime is, not coincidentally, 7pm. Because I have a loving and supportive wife who could stay at home after our baby was asleep I was able to go out to coffee shops after dinner a couples times of week to work on the book, and hence why I have so many commits then on both weekdays and weekends.</p><h4>Wrapping it up</h4><p>I wanted to do more of an analysis on the book, but this part took so much time I didn’t have the time to do so. As discussed in the book it’s better to share what you have then spend too long iterating and never finishing. There are still a lot more ways for me to look at the data on the book — in addition to the git commits I could analyze the actual text, or I could even look at my coffee shop transactions to see how much I’ve indirectly spent on writing the book (it’s a lot). Maybe if I’m lucky my coauthor will take on some of this…</p><p>Normally, at the end of a blog post about a data project like this our book recommends linking to the code on GitHub and the data to try it out yourself. Unfortunately this data isn’t publicly available so this code wouldn’t be meaningful. That said, you could try doing a similar analysis on any git repository changing over time!</p><p>Hopefully this inspired you to think about what data projects of your own you have in your life to help grow your career, or at least has inspired you to go to <a href="http://bestbook.cool">bestbook.cool</a> and grab a copy of the book!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=830aacca3c7e" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[How to make rtweet R  Shiny apps with user credentials]]></title>
            <link>https://medium.com/@jnolis/how-to-make-rtweet-r-shiny-apps-with-user-credentials-48acca246b58?source=rss-1adb4927e341------2</link>
            <guid isPermaLink="false">https://medium.com/p/48acca246b58</guid>
            <category><![CDATA[twitter]]></category>
            <category><![CDATA[3-legged-oauth]]></category>
            <category><![CDATA[shiny]]></category>
            <category><![CDATA[r]]></category>
            <dc:creator><![CDATA[Jacqueline Nolis]]></dc:creator>
            <pubDate>Thu, 23 Jan 2020 17:53:20 GMT</pubDate>
            <atom:updated>2020-01-23T17:53:20.474Z</atom:updated>
            <content:encoded><![CDATA[<h3>How to make rtweet R Shiny apps with user credentials</h3><h4>using 3-legged authentication so that you don’t worry about twitter rate limits</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/901/1*9EhjPLLfcX5oL6Ev735PpA.png" /></figure><p><a href="https://gist.github.com/jnolis/49d328f58e6bb0074442d032f4e79c7f"><em>[If you just want to see some code that makes it work, click this!]</em></a></p><p><em>rtweet</em> is a fantastic R package from Michael Kearney that lets you get Twitter data using the Twitter API. <em>Shiny</em> is a R package from RStudio that lets you create interactive websites from R. With these two packages you can create all sorts of fun tools in R, like <a href="https://gadenbuie.shinyapps.io/tweets-of-2019/">this website</a> by Garrick Aden-Buie that gives you a Twitter year in review. Unfortunately, Twitter puts constraints on the amount you can use their API, referred to as <em>rate-limiting</em>, and if your site gets too popular it’ll suddenly stop working. There is a way you can avoid this, and that’s to have your users authenticate on Twitter while using your site. If Twitter knows which user is hitting their API, then twitter won’t count those hits directly against your site’s rate-limit. It’ll instead count those hits against the users own rate-limit. So by making users authenticate, avoiding the rate-limit will no longer be a concern for your site.</p><p>The process of asking users to first log into Twitter before using your site is called <em>3-legged authentication</em>. If you have a twitter account you’ve probably been asked to authenticate before and you may have not even noticed. It takes some work to set up for a shiny application, but its really worth it!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*4pLs7P6X7iIxsg_HOMJTkA.png" /><figcaption>This interface is Twitter asking you to authenticate yourself for the app — you probably have seen this before and didn’t know it</figcaption></figure><p>This blog post is a walk-through of setting up 3-legged Twitter authentication in an R Shiny application that uses rtweet. In a follow up blog post I’ll add the additional step of using cookies to allow the users to stay authenticated even after closing the browser.</p><h3>How 3-legged authentication works</h3><p>To make any request from the Twitter API you need four strings that together make a set of Twitter credentials: a consumer key, a consumer secret, an authentication token, and an authentication token secret. When you register a Twitter app, Twitter provides you those four items. However, when you use the app credentials they count against your app’s rate limits. The process of 3-legged authentication gets you, for each user who authenticates, an alternate authentication token and authentication token secret to use. When you use those two strings plus the original consumer key and consumer secret, Twitter knows to use the user’s rate limits instead of the applications. Twitter uses a method of 3-legged authentication that follows the oauth standard, which is nice because that means that the lessons learned here could be applied to other websites beyond just Twitter.</p><p>The actual process is as follows. Suppose we have a Shiny app and we wanted to authenticate:</p><p><em>The R application will ask Twitter to generate a “request_token” via an API request. This token will be put into a special URL that when a user clicks will send them to the twitter authentication page. The URL will look something like:</em></p><pre><a href="https://api.twitter.com/oauth/authorize?oauth_token=TX7OoQAAAAAA_XMwAAABb7IAFBg">https://api.twitter.com/oauth/authorize?oauth_token=TX7OoQAAAAAA_XMwAAABb7IAFBg</a></pre><p><em>The user will click that URL and go to the authentication page. If the user clicks the “Authorize app” button, they’ll be redirected back to the shiny app, but with the useful information of an “oauth_token” and an “oauth_verifier” in the response URL. The URL that the user gets returned to would look something like this:</em></p><pre>http://127.0.0.1/?oauth_token=zxpV2gAAAAAA_XMwAAABb7Iglq0&amp;oauth_verifier=8JjwceyQAcfcAcJLyklHFlNVkKGaKrc8</pre><p><em>Finally, the R shiny app will ask Twitter to convert that oauth_token and oauth_verifier into the actual access token and access token secrets that are needed via one last API request. At that point the Shiny application will have the credentials needed to have requests go against the user rate limit instead.</em></p><p>In picture form, the process looks like this</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*TWHLgZr6XzyriVYGX6__qA.png" /><figcaption>The sequence diagram for the actions that the user, Shiny app, and Twitter take. Software engineering architects just looooove sequence diagrams.</figcaption></figure><h3>How to do it in Shiny</h3><p>First, go to <a href="https://developer.twitter.com/apps">https://developer.twitter.com/apps</a> and register a new app. This may take some time before Twitter approves it. Once you have approval, go to the keys page and save the four keys (consumer key, consumer secret, access token, and access token secret). Also on the app page edit the callback urls to include “http://127.0.0.1”.<strong> If you do not do this step your app won’t work</strong>. You also will want to add any other urls that you might have your shiny application use, such as if you host it on shinyapps.io.</p><p>Here is the R code for the steps in this process. Before we start let’s load up the R packages we need:</p><pre>library(shiny)<br>library(httr)<br>library(rtweet)</pre><p>Let’s also load up the credentials from the Twitter app we made earlier. Replace what’s in the brackets with your own keys.</p><pre>app &lt;- <br>  oauth_app(<br>    app = &quot;&quot;,<br>    key = [CONSUMER KEY],<br>    secret = [CONSUMER SECRET]<br>  )</pre><p>You don’t need the access token or access token secret. You can also store them in a json file and load them with the R package jsonlite (which is what I do in the demo at the end).</p><h4>Steps 1, 2, and 3: creating the authorization URL</h4><p>To request the URL that the user will click to authorize the Shiny app with Twitter, we need to call the Twitter API and ask for some tokens. Most of the time you don’t need to call the Twitter API directly (that’s what the rtweet package is for). However, the 3-legged authentication requests aren’t built into rtweet, so we have to write these requests ourselves.</p><p>We need a function that creates the signature so that the Twitter API accepts our request. I pulled this function from rtweet and slightly modified it — it uses the oauth code from the httr package:</p><pre>oauth_sig &lt;- function(url, method, token = NULL, token_secret = NULL, private_key = NULL, ...){<br>  httr::oauth_header(<br>    httr::oauth_signature(url, <br>                          method,<br>                          app,<br>                          token,<br>                          token_secret, <br>                          private_key,<br>                          other_params = list(...)))<br>}</pre><p>And then here is the function to create the URL for the user to click. It does a HTTP request to Twitter to get a request token. It then processes the response of the request to turn it into the URL. The method for how it does this processing (taking the response and turning into part of the URL query) is straight from the Twitter API documentation.</p><pre>get_authorization_url &lt;- <br>  function(app, callback_url, permission=NULL){<br>    private_key &lt;- NULL<br>    response &lt;- <br>      httr::POST(<br>        &quot;<a href="https://api.twitter.com/oauth/request_token">https://api.twitter.com/oauth/request_token</a>&quot;,<br>        oauth_sig(<br>          &quot;<a href="https://api.twitter.com/oauth/request_token">https://api.twitter.com/oauth/request_token</a>&quot;,<br>          &quot;POST&quot;, <br>          private_key = NULL,<br>          oauth_callback = callback_url)<br>      )<br>      httr::stop_for_status(response)<br>      params &lt;- <br>        httr::content(<br>          response, <br>          type = &quot;application/x-www-form-urlencoded&quot;)<br>      authorize_url &lt;- <br>        httr::modify_url(<br>          &quot;<a href="https://api.twitter.com/oauth/authenticate">https://api.twitter.com/oauth/authenticate</a>&quot;,<br>          query = list(oauth_token = params$oauth_token, <br>                       permission = permission))<br>      authorize_url <br>}</pre><p>Then, if you run:</p><pre>url &lt;- get_authorization_url(app, &quot;http://127.0.0.1&quot;)</pre><p>You would generate a URL that you could click on and it would take you to the Twitter authentication page. When you authorized the app, it would return you to “http://127.0.0.1/?[the credentials the app needs]”. If you failed to set “http://127.0.0.1” as a callback url on the Twitter developer app website then this step will fail.</p><h4>Step 4: user clicks the authorization URL</h4><p>To serve that authorization url in Shiny app you can just use a HTML link</p><pre>a(href = url, &quot;Authorize this app&quot;)</pre><p>After the user clicks the link and authorizes the app, we can finish it.</p><h4>Steps 5, 6, and 7: retrieving the user tokens</h4><p>As stated before, when the user authorizes the app they’ll be sent back to your shiny app with the information you need in the url:</p><pre>http://127.0.0.1/?oauth_token=zxpV2gAAAAAA_XMwAAABb7Iglq0&amp;oauth_verifier=8JjwceyQAcfcAcJLyklHFlNVkKGaKrc8</pre><p>There are two components here, an oauth_token and an oauth_verifier. You can retrieve them within your shiny app by using the session component of the server function.</p><pre>server &lt;- function(input, output, session) {<br>   ...<br>}</pre><p>That “session” variable has the url properties of how the user got to the app:</p><pre>query &lt;- getQueryString(session)</pre><p>Now query$oauth_token and query$oauth_verifier have the two properties we need. The following function will take the app information, oauth_token and oauth_verifier and get the user tokens from them. It does another HTTP request to Twitter to get the tokens, and if the request was successful (it has HTTP status 200) then the response has the users token. The response also has the user name and ID, but you may want to consider anonymizing it:</p><pre>get_access_token &lt;- <br>  function(app, <br>           oauth_token,<br>           oauth_verifier){<br>    url &lt;- <br>      paste0(<br>        &quot;<a href="https://api.twitter.com/oauth/access_token?oauth_token=">https://api.twitter.com/oauth/access_token?oauth_token=</a>&quot;,<br>        oauth_token, &quot;&amp;oauth_verifier=&quot;, oauth_verifier)</pre><pre>    response &lt;- <br>      httr::POST(url, <br>                 oauth_sig(url,<br>                           &quot;POST&quot;,<br>                           private_key = NULL))</pre><pre>    if(response$status_code == 200L){<br>      results &lt;- <br>        content(<br>          response,<br>          type = &quot;application/x-www-form-urlencoded&quot;,<br>          encoding = &quot;UTF-8&quot;)<br>    <br>      # since storing the username might be creepy<br>      results[[&quot;screen_name&quot;]] &lt;- NULL <br>    <br>      # since storing the user id might be creepy<br>      results[[&quot;user_id&quot;]] &lt;- NULL     <br>    <br>      results<br>    } else {<br>      NULL<br>    }<br>}</pre><p>And so by calling the get_access_token function you get what you need to make a valid set of user credentials</p><pre>access_token &lt;- <br>  get_access_token(app, query$oauth_token, query$oauth_verifier)</pre><pre>user_token &lt;- create_token(app=&quot;&quot;, <br>                   keys$consumer_key, <br>                   keys$consumer_secret, <br>                   access_token = access_token$oauth_token, <br>                   access_secret = access_token$oauth_token_secret)</pre><p>And that’s it! You now have credentials for the user and not your app.</p><h4>Step 8: Enjoying the fruits of your labor</h4><p>With this user token you can make any rtweet call you want. For example, you could get the text of 3 tweets the user recently made:</p><pre>tweets &lt;- get_my_timeline(token = user_token)$text[1:3]</pre><p>With these tools we can make a whole Shiny app! <a href="https://gist.github.com/jnolis/49d328f58e6bb0074442d032f4e79c7f">Here is the code for an example app</a> that has an authorization link, and once you click it shows three recent tweets from the user. To run the app make sure you use the command</p><pre>runApp(port=80L, launch.browser=FALSE)</pre><p>And go to “http://127.0.0.1” in your browser. You need to use the right port and the desktop browser for the redirect to work.</p><h3>Next steps</h3><p>Unfortunately, if the user refreshes their browser then Shiny will delete the user token and it won’t work. It would be much better if a user could log in once and then never have to do it again. The good news is that it’s possible! The bad news is that it requires using browser cookies, which requires a bit of engineering since Shiny doesn’t have built-in support for it. In a followup post I’ll work through how to do that!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=48acca246b58" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Small data, big value]]></title>
            <link>https://medium.com/tmobile-tech/small-data-big-value-f783ceca4fdb?source=rss-1adb4927e341------2</link>
            <guid isPermaLink="false">https://medium.com/p/f783ceca4fdb</guid>
            <category><![CDATA[tensorflow]]></category>
            <category><![CDATA[customer-experience]]></category>
            <category><![CDATA[machine-learning]]></category>
            <category><![CDATA[r]]></category>
            <category><![CDATA[keras]]></category>
            <dc:creator><![CDATA[Jacqueline Nolis]]></dc:creator>
            <pubDate>Mon, 18 Nov 2019 19:38:22 GMT</pubDate>
            <atom:updated>2019-12-03T18:37:34.074Z</atom:updated>
            <content:encoded><![CDATA[<h4>How simple and quick machine learning projects can beat out massive technology investments</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ftOvmkYxrze-x57_2weuSQ.png" /></figure><p><strong>(Hate reading? Head straight to the </strong><a href="https://secure.message.t-mobile.com/v1/shiny/is-customer/app/"><strong>demo</strong></a><strong> and test the model yourself!)</strong></p><p><em>This post was coauthored with Joel Werdell, a Principal Product Manager at T-Mobile.</em></p><p>Machine learning journalism focuses solely on massive endeavors: giant datasets being loaded into intensive computing machines and months of work to produce results. When the only stories told are ones of massive budgets and GPU clusters that use a town’s worth of power, it creates a belief that for machine learning to be effective it needs to be a Grand Investment That Will Change the Business. But this is ridiculous! Just like you don’t need to be a bonafide tech company to create software, you don’t need to undergo a massive machine learning transformation to meaningfully drive your business using AI. Models can be created and used in small ways that provide simple victories for companies, immediately lowering risks and costs.</p><p><em>This blog post is the story of one such project at T-Mobile.</em></p><p>At T-Mobile, many people prefer to connect to us through text-channels such as text messages, Twitter, and messaging through the T-Mobile app. The people who message us may be T-Mobile customers interested in topics like how to upgrade a phone or pay a bill. They also may not yet be a customer and want to switch to T-Mobile, so they are looking to have a conversation about joining.</p><p>As we looked for ways to improve the messaging experience, we noticed that lots of conversations had an initial message from the person with a question in it like: “how much to switch 4 lines to T-Mobile?” or “how do I get Netflix on my account?” Our messaging software would respond to customers by asking: “are you a customer?” This was absolutely absurd, since the text of the customer’s question usually answered ours — for instance someone asking about changing their plan is clearly a customer. It seemed like a problem a computer should be able to solve, so we set out to do it. The AI @ T-Mobile team immediately dived in to make this better.</p><p>Thankfully, we had a great set of training data for a machine learning model. We had plenty of historic logs from conversations where people messaged T-Mobile, then immediately selected from our UI if they were a customer or not. Each person’s first message would be the input data to the model, and the selection they made would be what our model was trying to predict. Since we had historic logs of conversations and people’s customer selections (with customer data removed), we were in great shape.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*j5aWfH9t1_EZPJC92CJ7oQ.png" /><figcaption>An example of a message a person sent to T-Mobile and the picker the person selected their choice from.</figcaption></figure><p>Since the data was a set of strings (the messages) for the input and a yes or no variable (if they selected customer) for the output, the data was not large in size per data point. Further, the amount of data points we ultimately needed for the model was in the tens of thousands range, not the millions range. All together, this meant that we could make a machine learning model without having to worry much about big data.</p><p>We decided to train a neural network model on this data. Neural networks are especially well suited for text input since they can easily parse the sequence of words in the text. By using a neural network approach we could trust that the model would be able to find the important parts of the message and we didn’t have to spend time engineering features like we would with a different type of model. Neural networks are built on layers of nodes, where each layer provides a different function for the overall model. Out network had three key layers:</p><ol><li><strong>An embedding layer.</strong> This layer places the words in a small-dimensional space so that similar words in the message are treated similarly by the model (like “payment” and “payments”)</li><li><strong>A convolution layer.</strong> This layer creates features out of sets of five words in a row. By doing so it looks for important phrases in the message (like “pay my bill”)</li><li><strong>A dense layer.</strong> This layer reduces the network down to a single number which is used as the probability for the person being a customer.</li></ol><p>We used R to train the model with the Keras and TensorFlow packages for training the neural network. Since our model was only three simple layers we were able to be quickly train and test it. We left a test set of messages out of the training data to validate the model worked well enough for our messaging channels.</p><p>We then deployed our R neural network as an API in a Docker container. By using Docker containers with the T-Mobile standard engineering pipeline our model was soon put into production and helping people get routed faster. For an introduction to R in production check out our <a href="https://medium.com/tmobile-tech/r-can-api-c184951a24a3">blog posts</a>, <a href="https://github.com/tmobile/r-tensorflow-api">GitHub repo</a>, and <a href="https://resources.rstudio.com/rstudio-conf-2019/push-straight-to-prod-api-development-with-r-and-tensorflow-at-tmobile">RStudio::conf() video</a>.</p><p>With our tool in place we were able to reduce the number of people who saw the automated “are you a customer” selector by half. This was a great business success, removing a point of friction from the customer experience and getting customers to the experts who can help them faster. At T-Mobile we have the core belief that the customer should come first, and this machine learning model allowed us to drive towards that.</p><p>What’s more interesting than the technical approach we took was the things we <em>didn’t</em> need to successfully launch this product:</p><ul><li><strong>Big data platforms like spark.</strong> Because out data was reasonably sized, we were able to train our models locally rather than having complex platforms.</li><li><strong>Setting up virtual machines with GPUs for training.</strong> The simplicity of the problem meant that training on CPUs was fast enough to be practice, no graphics cards necessary.</li><li><strong>Any feature engineering on the data.</strong> Since the input data was just text, there wasn’t anything to engineer. We fed it into the neural network and saw immediate results.</li><li><strong>Cross-validation and other training techniques.</strong> Doing the traditional method of leaving a small percentage of data out of our model when training to use in testing had almost no impact on performance and got us to market more quickly.</li><li><strong>Fancy retraining methods.</strong> when we looked at the data we found almost no change to it over time. Because of this we didn’t have to worry about auto-retraining or complex deploying strategies.</li></ul><p>By doing without the complexities that most people discuss when they talk about machine learning, we were able to quickly get to market and easily maintain our work. As others look for use-cases for machine learning at other companies, consider what you can do if you limit yourself to simple projects.</p><p>Thanks for reading, and <a href="https://secure.message.t-mobile.com/v1/shiny/is-customer/app/">check out our live demo</a> of the “are you a customer” model to try it out for yourself.</p><figure><a href="https://secure.message.t-mobile.com/v1/shiny/is-customer/app/"><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*vMie6UjceYxwih3nHisMCQ.png" /></a></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=f783ceca4fdb" width="1" height="1" alt=""><hr><p><a href="https://medium.com/tmobile-tech/small-data-big-value-f783ceca4fdb">Small data, big value</a> was originally published in <a href="https://medium.com/tmobile-tech">T-Mobile Tech</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[rstudio::conf 2019 takeaways]]></title>
            <link>https://medium.com/@jnolis/rstudio-conf-2019-takeaways-9c60eda17084?source=rss-1adb4927e341------2</link>
            <guid isPermaLink="false">https://medium.com/p/9c60eda17084</guid>
            <category><![CDATA[data-science]]></category>
            <dc:creator><![CDATA[Jacqueline Nolis]]></dc:creator>
            <pubDate>Sun, 20 Jan 2019 04:47:06 GMT</pubDate>
            <atom:updated>2019-01-20T05:13:40.756Z</atom:updated>
            <content:encoded><![CDATA[<h4>Serious Shiny, R in Production, and Data Science Skill Growth</h4><p>rstudio::conf 2019 was a whirlwind conference in Austin, covering a wide range of topics around R and RStudio products. It was a great conference and I had a blast, so now that it’s over and my adrenaline rush is calming I am doing a post-mortem. As an attendee I found that three themes were showing up over and over throughout the event, which sheds some light on where the R community may be heading. A write-up seemed like a good way to not forget them, and if you were unable to attend hopefully this helps with the FOMO!</p><h3>Theme 1: Shiny is a Serious Product</h3><p>Years ago when I was first exposed to Shiny, the R package that lets you make interactive visualizations, it seemed like powerful tool but enormously fickle. Sure you <em>could</em> take your analysis and add sliders and drop downs to it, but it would take a lot of work before it was fully ready. Further, if you wanted to show it to someone else you had to bring your laptop to them. Every time you made changes to the underlying analysis you hoped that didn’t break your Shiny app. If you wanted something quick and simple Shiny was great, but if you wanted something extremely stable, elegant, or robust you were better off with recoding your work in JavaScript:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*BYe-eM2OSz8nZx9qMEkBtA.jpeg" /></figure><p>Today, Shiny has come a long way and there are many more situations where it makes sense to use Shiny:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*cOsavBQAKUDfvL6hehVmVQ.jpeg" /></figure><p>Some of the really helpful improvements to Shiny and new tooling I saw were:</p><ul><li><a href="https://github.com/rstudio/shinytest"><strong>shinytest</strong></a> — This R library lets you write the equivalent of unit tests for your apps. You can make a recording of using the app, and then the package will alert you if changes to the R code make the app unexpectedly change.</li><li><a href="https://github.com/rstudio/shinyloadtest"><strong>shinyloadtest</strong></a><strong> </strong>— Once your app is stable you’ll want to make sure it won’t crash if multiple people use it at once. shinyloadtest is a Java (Java?? 🤔) program that hits your shiny app with multiple users at once and measures performance degradation.</li><li><a href="https://github.com/rstudio/shiny/blob/master/R/render-cached-plot.R"><strong>renderCachedPlot</strong></a> — while renderPlot is the typical way of showing a plot in Shiny, it has to redraw the entire image even if the user has selected the same input before. renderCachedPlot speeds this up by keeping a record of older plots.</li><li><a href="https://www.rstudio.com/products/connect/"><strong>RStudio Connect </strong></a>— this is RStudio’s new enterprise product, which lets data scientists publish their Shiny apps to an internal server at a push of a button.</li></ul><p>As for good Shiny use cases, <a href="https://www.slideshare.net/secret/Ba52FYuH2FoWE">Emily Robinson gave a talk</a> about how she used Shiny to develop the A/B test reporting suite at DataCamp. With Shiny, she was able to create the tools herself instead of having to rely on engineers. <a href="https://github.com/thisisnic/rstudio-conf-2019">Nic Crane presented a Shiny app</a> she worked on for the 100,000 genomes project, which was bursting with functionality and cool HTML widgets.</p><h3>Theme 2: R in Production</h3><p>The opening keynote of rstudio::conf heavily featured the idea of “R in production.” For RStudio, that meant using RStudio Connect to have Shiny apps and Rmarkdown reports that are always up and available for users throughout the company to view. RStudio seemed to be focusing on having R be simpler to share internally within a company, as opposed to say, generating a PDF that gets emailed once and lost forever.</p><p>R in production can also be about creating APIs as software engineers opt to do. Other talks in the conference covered using the R package Plumber to use R as a web service to host a RESTful APIs. The plumber package featured in a talk on <a href="https://github.com/sol-eng/plumber-model">democratizing R by James Blair,</a> it showed up in my Shiny in Production workshop on how to move code out of Shiny, and of course it was a key player in the talk Heather Nolis and I gave on <a href="https://nolisllc.com/rstudio19">R in Production at T-Mobile</a>. In our talk we covered how we use R to power neural networks that do natural language processing every time a T-Mobile customer send a text message to a customer care representative. While at T-Mobile we use Docker containers to deploy our R code as a microservice, this isn’t the best route for everyone. For the use case of running APIs RStudio again suggests its RStudio Connect product.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*6Dboc5BbLN_LlHB2HoacVA.jpeg" /><figcaption>I refuse not to shamelessly share this picture of me and Heather drawn by Brooke Watson</figcaption></figure><p>Other things discussed to make R ready for production were the new pkg function, presented by <a href="https://twitter.com/GaborCsardi">Gabor Csardi</a> and plenty of dependency functionality presented in a <a href="https://speakerdeck.com/jimhester/it-depends">talk from Jim Hester</a>. Together those to talks gave a lot of tools for R users who struggle to maintain which versions of packages their code is using. This is really important if your R code is going to be run by other people, or have to be run in the future when the dependencies may have been updated. Another solution to dependency madness is the new <a href="https://www.rstudio.com/products/package-manager/">RStudio Package Manager</a>, which basically lets your company have its own mini-CRAN that you can put internal packages onto.</p><h3>Theme 3: Data Science Skill Growth</h3><p>A lot of the talks had nothing to do with R itself; they focused on how people can grow their own skills in data science or the skills within their organization. Data science is a young enough field that we don’t have more standardized thinking on how to organize and grow compared to fields like software engineering — not that they have a particularly strong grasp of it either.</p><p><a href="https://twitter.com/felienne">Felienne</a> gave an amazing keynote on how to think about teaching the skills of programming and supporting a community. Programming is traditionally taught as in a “explore puzzles on your own to learn” way which science shows is awful. When teaching people to program you should clearly explain the topics and give structured ways to practice, just like we do with every other topic in schools.</p><p>Other noteworthy talks on this topic I saw include one from <a href="https://twitter.com/beeonaposy">Caitlin Hudon</a>, who did the bold thing I love where she actually revealed mistakes she has made while a data scientist. Understanding the ways that successful people have messed up is a great way to learn, and I have found the data science community is unusually good at it. <a href="https://twitter.com/AngeBassa">Angela Bassa</a> gave a great talk on how to think about data science as a team sport and organizational design.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*-kc_UvVSJXLDXP2J4-y2DA.jpeg" /><figcaption>This question always plagued me but I love Angela’s answer: “don’t worry about it.”</figcaption></figure><p>David Robinson gave the last <a href="https://bit.ly/drob-rstudio-2019">keynote of the conference</a> which covered how to help contribute through the data science community with tweets, blog posts, conference talks, and books (in that order). Contributing to the community with things like blogging is a great way to help other people grow and boost your career (Except this blog post isn’t just to boost my career of course 😅😅😅). As a person who does all these activities A+++++ would recommend.</p><h3>Wrapping it up</h3><p>There were other great talks that didn’t fit into those themes, like:</p><ul><li><a href="https://twitter.com/brookLYNever1y">Brooke Watson</a>’s talk on how the ACLU uses R to understand data on separated asylum-seeking families,</li><li>Rich Iannone giving a standing room only presentation on the <a href="https://github.com/rich-iannone/presentations/tree/master/2019_01-19-rstudio_conf_gt">gt package</a> for making elegant HTML tables in Rmarkdown or Shiny, and</li><li>Sigrid Keydana’s presentation on using <a href="https://github.com/skeydan/rstudio_conf_2019_eager_execution">eager execution in TensorFlow</a> to make more non-standard neural networks.</li></ul><p>Karl Broman did a great job at making one <a href="https://github.com/kbroman/RStudioConf2019Slides/blob/master/ReadMe.md">GitHub repository</a> that has all the slides (and soon RStudio will release the videos of them), so check them out yourself!</p><h3>Emily Robinson on Twitter</h3><p>Love that @hadleywickham shared the Pac-Man rule with everyone - to make #RStudioConf (even) more welcoming, when you&#39;re talking in a group always leave space for someone else to join the conversation</p><p>Overall rstudio::conf was a fantastic time where lots of solid material was presented. But that paled in comparison to how welcoming everyone was! In the first five minutes of the first day Hadley Wickham mentioned the Pacman rule: make every conversation open to new people. I couldn’t believe how much that idea was honored, I was constantly getting to talk to new people and having strangers welcome me to their conversations. There is something special about the R community as a whole (and R-Ladies!) where people are constantly encouraging and helping others.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=9c60eda17084" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Using docker to deploy an R plumber API]]></title>
            <link>https://medium.com/tmobile-tech/using-docker-to-deploy-an-r-plumber-api-863ccf91516d?source=rss-1adb4927e341------2</link>
            <guid isPermaLink="false">https://medium.com/p/863ccf91516d</guid>
            <category><![CDATA[docker]]></category>
            <category><![CDATA[software-development]]></category>
            <category><![CDATA[r]]></category>
            <category><![CDATA[data-science]]></category>
            <dc:creator><![CDATA[Jacqueline Nolis]]></dc:creator>
            <pubDate>Tue, 06 Nov 2018 14:07:12 GMT</pubDate>
            <atom:updated>2019-04-01T17:57:56.688Z</atom:updated>
            <content:encoded><![CDATA[<h4>Get your R code to run anywhere as a service</h4><p><em>[This post is co-authored by Heather Nolis, and is part of a series on R in production. We recommend you start with </em><a href="https://medium.com/@heathernolis/r-can-api-c184951a24a3"><em>part 1</em></a><em>.]</em></p><p>In the <a href="https://medium.com/@heathernolis/r-can-api-c184951a24a3">previous blog post</a> we learned how to use the R library plumber to create a RESTful API. We showed that by running a simple R script, we could have a web service running on our computer straight from RStudio. But what if you want to run the web service somewhere besides your computer? How do you get that code running somewhere else? And how can you do it in a way that’s quick to set up and easy to maintain?</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*5UaV7hnXAgbNDNDbIDI2lw.png" /></figure><p><strong><em>[Before we begin, here is some legalese from our lawyers.]</em></strong></p><p><em>The code in this blog are examples we ran using Docker 18.06, which may need to be modified for your own environment. We will make our best effort to update but we make no guarantees on that. Feel free to modify the code as you see fit. In fact, if you want to fork the code, feel free to do so. All we ask is that you honor any open source licenses and attributions including from us. It goes without saying, but you are responsible for respecting the data you use and ensuring best practices for cybersecurity. In general, before using in production, please have your internal IT department (if they exist) review your code and your data. They know your environment better than we do, and we are not in a position to provide general support. In legalese, “Use is AS IS and without warranty.” Your IT department (if they exist) should be aware of the open source licenses for some of these tools. Most are Apache and BSD. R and Rocker are GPL based. Note that different departments have different policies about open source.</em></p><h4><strong>The </strong>☁️<strong><em>cloud</em></strong>☁️<strong> and virtual machines</strong></h4><p>As a data scientist, you sometimes want to have code running in places that are not your computer. In our case, we want to have our R script run an API continuously, regardless of if our laptop runs out of battery.</p><p>One way we could set this up would be to create a virtual machine in a place like Amazon Web Services. A virtual machine is like a computer that you’ve used before, but it’s simulated–it doesn’t have it’s own process, memory, or hardware. Instead, a different computer is running the machine. Virtual machines are great because many of them can run on a single server, and they can be easily started and stopped.</p><p>If you wanted to run the API on a virtual machine you would log onto AWS and:</p><ol><li><a href="https://www.infoworld.com/article/3223425/cloud-computing/windows-amazon-ec2-tutorial-how-to-set-up-an-ec2-instance.html">Start an EC2 instance</a> (a virtual machine) with the right operating system and set the security group to allow HTTP traffic.</li><li>Install the correct version of R.</li><li>Install the right R libraries, some of which may come from GitHub.</li><li>Put the R scripts for your plumber API on the instance.</li><li>Open port 80 within the virtual machine’s firewall.</li></ol><p>And that works! If you follow these steps you will be able to hit the API endpoint you created. But there are a few downsides with this process:</p><ul><li>Starting the EC2 instance and installing all of these programs takes a ton of time. If the EC2 instance was accidentally deleted, you would have to do it all again. If you no longer worked at your company, no one would know exactly what steps you took to create the EC2.</li><li>Virtual machines take a lot of computing resources. They are entirely simulated computers, so they require an entire OS running and all the programs that come with it.</li></ul><p>Both of these problems are fixed with docker.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*qlDYjmXhfVBpeJXNiMmCew.jpeg" /><figcaption>Docker will leave you feeling as calm and serene as this photo (copyright of flickr user <a href="https://www.flickr.com/photos/stanimirstoyanov/">stanimir.stoyanov</a>)</figcaption></figure><h4><strong>Enter Docker</strong></h4><p>Docker is a way to make the process of configuring and running computers smoother. With docker, you can create a single document that specifies how to set up the computer. The document lets you run these steps at a moments notice. More formally, docker is a way to run virtual machines as containers, which are lightweight executable packages of software. A container is an instance of an image, which is a snapshot of a computer at a moment in time. Images can be full snapshots, or they can just be a small addition to an earlier image. A dockerfile is the specification document for how to build the image.</p><p>Or to put it another way:</p><ul><li>A <em>dockerfile</em> lists how to build the computer we’ll want to run (like the list of steps in the section above).</li><li>An <em>image</em> is a file that’s a snapshot of that computer. Each step of the docker file constructs a new image. That image is used as the starting place for the next step in the docker file.</li><li>A <em>container</em> is when you take an image file and begin running it. Running an image creates a container.</li></ul><p>Docker containers are a great way to have computers set to exact specifications. Software developers love containers because they allow quick creation of many computers running the exact same code. Docker simplifies installation and maintenance of production-level code.</p><p>Docker containers are also smaller than virtual machines because they can share components amongst each other. If we have many docker containers that all need Linux with R installed, then they can all share those core Linux and R components.</p><p>By passing a docker image, you can immediately have someone else run your code! All the setup is taken care of, provided they have docker installed.</p><h4><strong>Using Docker for R and plumber</strong></h4><p>We’ll use the API we created in part 1 of this series as the code we want in our docker container. You can find the R code in our <a href="https://github.com/nolis-llc/r-api-tutorial">GitHub repository</a>. Let’s try making a container out of it and running it on our own machine. In our case we’ll want to set up a computer following roughly the steps above:</p><ol><li>Start a computer with Linux.</li><li>Install R on it.</li><li>Install our R libraries.</li><li>Transfer our R scripts to the computer.</li></ol><p>Since we’re using docker, performing each one of those steps will correspond with creating a new docker image. We’ll start with an image already setup to have Linux on it. Then we’ll create an image that has R installed on top of Linux. After that, we’ll add our R libraries into a third image. Lastly, we’ll transfer our files to the final image.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*6dNQ6368kw6bZlG_mtAxgg.png" /><figcaption>Building our beautiful R plumber API image from other, smaller images</figcaption></figure><p>A great thing about docker is that since so many people use it, you can often find images that other people have made that do what you want to do. In our case, <a href="https://www.rocker-project.org/">the Rocker project</a> has a ton of docker images that support R, including ones with R+RStudio, Shiny, and more. This means we don’t have to devise these images ourselves; we can use those images as starting points for ours. To start on our container, we’ll use the <a href="https://hub.docker.com/r/rocker/r-ver/">“r-ver”</a> docker image, and thus the first two steps are done.</p><p>To use docker, you’ll first need to install it on the computer you’re using (here are links for <a href="https://store.docker.com/editions/community/docker-ce-desktop-windows">windows</a> or <a href="https://store.docker.com/editions/community/docker-ce-desktop-mac">mac</a>). This is relatively painless, but it requires admin rights and may require you to change some operating system settings. Begin by starting docker on your computer. You’ll know you’ve started it if this dashing looking whale stops moving:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/400/1*4882CvQqP8q5UK-iIPNnGQ.png" /><figcaption>Your new best nautical friend</figcaption></figure><p>Once docker has started, go to the terminal (or PowerShell in windows) and type:</p><pre>docker pull rocker/r-ver:3.5.0</pre><p>This will get the Rocker docker image from the internet that has R version 3.5.0 installed on a linux machine. So you are downloading a compressed file that has a full computer’s information in it. It’ll take a few seconds, and during this time you’ll see a screen like this:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*CjNB1AqiLYOe28PtiVmo2Q.png" /></figure><p>Each line represents a sub-image, starting with one that has just the operating system and ending with one that has R installed. All put together, these create the full rocker/r-ver:3.5.0 image.</p><p>Once complete you can run the following command:</p><pre>docker run -ti rocker/r-ver:3.5.0 </pre><p>This runs a rocker container that is set up to run interactive R. You should see the familiar R command line interface. <em>This works even if you don’t have R installed on your own computer!</em> 😱 It’s all happening in this tiny container running concurrently inside your computer. If you were to quit the interactive R session, the container would stop — meaning anything you did inside it would be lost. This makes sense since the container is not your computer, it’s just running <em>on</em> your computer.</p><p>For our example, running R alone isn’t sufficient. We also need to install plumber, copy our files, set up our rest controller, and open the container to port 80 so that it can receive HTTP traffic. To add onto this Rocker image, we need to make the dockerfile.</p><p>In the same directory as the plumber code from part 1, create a plaintext file called dockerfile. In order to build, docker always looks for a plain text file with no extension called dockerfile, so this is important.</p><p>To customize our docker container, we first specify our base container. For us, that’s the rocker/r-ver:3.5.0 image. We do this by using the `FROM` command:</p><pre>FROM rocker/r-ver:3.5.0</pre><p>Then, we need to install the linux packages that are required for the plumber using linux bash commands. To these commands while setting up the image, we use the RUN. We first check for the newest packages and then install two which aren’t included in the standard update.</p><pre>RUN apt-get update -qq &amp;&amp; apt-get install -y \<br>      libssl-dev \<br>      libcurl4-gnutls-dev</pre><p>Install plumber using RUN to execute one line of R code:</p><pre>RUN R -e &quot;install.packages(&#39;plumber&#39;)&quot;</pre><p>Now we have a container with all the required libraries and packages. But we still need to copy any R scripts that we use to run our webservice! To make it easy, let’s just copy everything from the folder containing our dockerfile and the code from part 1 into the image. The COPY command takes the first argument as the location on the computer with the dockerfile and copies it into the specified folder in the image:</p><pre>COPY / /</pre><p>Next we open port 80 to web traffic (since that’s the port plumber listens to) using the EXPOSE command:</p><pre>EXPOSE 80</pre><p>Lastly, we should specify what happens when the container starts. In <a href="https://medium.com/@heathernolis/r-can-api-c184951a24a3">part 1</a> we created a main.R file that starts the plumber web service in R. We want that to happen in our container. So we set the ENTRYPOINT of the container to run the main.R script.</p><pre>ENTRYPOINT [&quot;Rscript&quot;, &quot;main.R&quot;]</pre><p>And that’s our dockerfile! It builds everything we need to run our API from any machine, regardless of the setup! All together it looks like this:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/3bc26d20e2a427d2b8fbf7fbdc3cb2aa/href">https://medium.com/media/3bc26d20e2a427d2b8fbf7fbdc3cb2aa/href</a></iframe><p>To build our image, open a terminal in the project folder and run</p><pre>docker build -t plumber-demo .</pre><p>This builds the image and names it “plumber-demo”. Because installing plumber requires compiling several other R packages, this takes a few minutes. Don’t worry! Once the process is complete, you can run the container by using:</p><pre>docker run --rm -p 80:80 plumber-demo</pre><p>Now, you can run your API just like you did in part 1 — by navigating to this address: <a href="http://127.0.0.1/predict_petal_length?petal_width=1">http://127.0.0.1/predict_petal_length?petal_width=1</a>. Any other person can take your same project run and your web service on their computer — regardless of OS and programs installed.</p><p>Wow! When you’re ready you can stop all running containers by using:</p><pre>docker stop $(docker ps -a -q)</pre><p>If you want to have this web service running on a server in the cloud, it only takes a few more steps. One way to do this is to use a tool like <a href="https://aws.amazon.com/ecs/">Amazon Elastic Container Service (ECS)</a>. ECS lets you take a container you’ve created and deploy it to AWS. At that point your container is running within AWS systems, and you will get an endpoint that anyone can hit with a browser from anywhere. Wild!</p><p>With a better understanding of what docker is, why it’s super cool, and how it can be used to run R plumber APIs anywhere, you’re now empowered to make your own APIs. Take that, engineering team!</p><p>You should be able to create your own simple docker container and understand the basics of what is happening in a dockerfile.</p><p>There is still work left to do if you wanted to use R and plumber in an enterprise setting. In particular:</p><ul><li>You may need your container to support the keras and tensorflow libraries, which require Python.</li><li>You’ll want to make the container as small as reasonably possible</li><li>You definitely want your web service to support encryption via HTTPS, which isn’t supported by plumber.</li><li>You should make the dockerfile something that you never have to touch (so remove things like the list of R libraries to install).</li></ul><p>In the <a href="https://opensource.t-mobile.com/blog/posts/r-tensorflow-api/">final part of this series</a>, we’ll talk about the <a href="https://github.com/tmobile/r-tensorflow-api">r-tensorflow-api</a>. We crafted a small docker container for T-Mobile to run neural networks in R as a RESTful API in an enterprise environment.</p><p>Though docker seems complicated and mysterious at first pass, it is just a way to write a program to build environments for you that guarantee all your dependencies are present. It makes sharing code smooth — something that is a pain point for the vast majority of data scientists.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=863ccf91516d" width="1" height="1" alt=""><hr><p><a href="https://medium.com/tmobile-tech/using-docker-to-deploy-an-r-plumber-api-863ccf91516d">Using docker to deploy an R plumber API</a> was originally published in <a href="https://medium.com/tmobile-tech">T-Mobile Tech</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Guessing the year you were born from baby names using R]]></title>
            <link>https://medium.com/data-science/guessing-the-year-you-were-born-from-baby-names-using-r-17c8cbb8d0a5?source=rss-1adb4927e341------2</link>
            <guid isPermaLink="false">https://medium.com/p/17c8cbb8d0a5</guid>
            <category><![CDATA[data-science]]></category>
            <dc:creator><![CDATA[Jacqueline Nolis]]></dc:creator>
            <pubDate>Wed, 26 Sep 2018 04:19:04 GMT</pubDate>
            <atom:updated>2020-08-16T06:37:49.368Z</atom:updated>
            <content:encoded><![CDATA[<h4>A simple question shows the pains of data science</h4><p>Recently an article has been going around Twitter on <a href="https://qz.com/1390135/the-epic-rise-and-fall-of-the-name-heather/">the rise and fall of the name “Heather.”</a> Heather was an immensely popular baby name during the 1970’s and 80’s, but the name quickly tapered off into obscurity. <a href="https://twitter.com/CMastication">JD Long</a>, a well-known data scientist working in the insurance industry, made this tweet about it:</p><h3>JD Long on Twitter</h3><p>One of those &quot;what age are you without using numbers&quot; answers (at least in the US) is that I am &quot;Chad, Clay, Jennifer, and Lori&quot; years old... https://t.co/Zq4RwUAYPH</p><p>Reading the tweet, and the response by data scientist <a href="https://twitter.com/jent103">Jennifer Thompson</a>, made me wonder what at the time I thought was a simple question:</p><blockquote>What set of four baby names best indicates the year you were born in?</blockquote><p>In JD’s case, he believes that the four baby names for his birth year are Chad, Clay, Jennifer, and Lori. For me, born in the mid 80’s, I would guess the four names of my birth year are Matthew, Michael, Laura, and Elizabeth. But what actually are the best names to pick, and how can we show it with data?</p><p>This kind of question is exactly what data scientists deal with all the time. When you read it, it sounds like a very precise question you can quickly answer. Once you start thinking about it, it turns out to be very tricky to understand. Soon you realize that just how you approach the problem can dramatically alter the answer, and there is no one right approach to it. I ended up taking three different attempts at attacking the problem, with some interesting and distinct results.</p><h4>Attempt 1: Using the names that are most statistically likely to come from the year.</h4><p>To me, the term “best indicates” means that when if you were to tell someone those four names, they know the exact year you were born in. That definition inspires my first way of turning it into a statistical problem: What is the set of four names that if they were drawn randomly from a year are most likely to have been drawn from that year in question?</p><p>To put it another way, suppose I had a bunch of burlap sacks and each sack had a year written on it. In each sack I had marbles with names written on them for each person born that year. If I looked inside the bag and chose four marbles then handed them to you, what would be the four I should choose that would make you guess the year?</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*qqUjRVHjpcpmUJClDTMCzQ.png" /><figcaption>This is a super weird metaphor but like, aren’t most statistical and combinatorial framings?</figcaption></figure><p>With a little bit of mathematics starting with Bayes theorem, it turns out that we want to find the four names that maximize: <em>P(name|year)/P(name)</em>. Or take the probability of pulling the name in the year we care about, and divide it by the probability of pulling the name across all years (I assume the years are equally likely).</p><p>Let’s do this in R! Thankfully, Hadley Wickham made a package for easy baby name analysis using government data. Unfortunately this is using US data only, and there is no way the results extrapolate to other countries. First, let’s load up the libraries we need:</p><pre>library(babynames) # to get the baby name data<br>library(dplyr)<br>library(tidyr)<br>library(ggplot2)</pre><p>The package babynames contains a dataset babynames with a row for each year, baby name, and the assigned gender at birth (which is incorrectly labeled “sex”). It has the number of times that name occurred, and the percent of babies born that year with that name and assigned gender. Only name and gender pairs that occurred at least five times in the year are included.</p><pre>&gt; babynames<br># A tibble: 1,858,689 x 5<br>    year sex   name          n   prop<br>   &lt;dbl&gt; &lt;chr&gt; &lt;chr&gt;     &lt;int&gt;  &lt;dbl&gt;<br> 1  1880 F     Mary       7065 0.0724<br> 2  1880 F     Anna       2604 0.0267<br> 3  1880 F     Emma       2003 0.0205<br> 4  1880 F     Elizabeth  1939 0.0199</pre><p>First, let’s calculate the total probabilities to use as the numerator in that fraction for each name. The code below creates a data frame with a row for each assigned gender and name pair:</p><pre>total_props &lt;-<br>  babynames %&gt;%<br>  complete(year,nesting(sex,name),fill=list(n=0,prop=0)) %&gt;%<br>  group_by(sex,name) %&gt;%<br>  summarize(total_prop = mean(prop)) %&gt;%<br>  ungroup()</pre><p>The code takes the table babynames, fills in the missing rows with 0’s, the takes the average probability for each name and assigned gender pair.</p><p>Then, we compute the probability of each name and assigned gender within the year, and join it to the previous table. We compute the ratio, and look at the top four per year:</p><pre>most_informative_ratio &lt;-<br>  babynames %&gt;%<br>  inner_join(total_props,by=c(&quot;sex&quot;,&quot;name&quot;)) %&gt;%<br>  mutate(value = prop/total_prop) %&gt;%<br>  group_by(year) %&gt;%<br>  filter(row_number(desc(value)) &lt;= 4) %&gt;%<br>  ungroup() %&gt;%<br>  arrange(year,desc(value))</pre><p>Let’s look at the results! Here are the most informative names for 1980:</p><pre>&gt; most_informative_ratio %&gt;% filter(year == 1980)<br># A tibble: 4 x 7<br>   year sex   name           n       prop   total_prop value<br>  &lt;dbl&gt; &lt;chr&gt; &lt;chr&gt;      &lt;int&gt;      &lt;dbl&gt;        &lt;dbl&gt; &lt;dbl&gt;<br>1  1980 F     Nykeba        26 0.0000146  0.000000107    136<br>2  1980 F     Sumeka        14 0.00000786 0.0000000578   136<br>3  1980 F     Renorda       11 0.00000618 0.0000000454   136<br>4  1980 F     Shanndolyn    11 0.00000618 0.0000000454   136</pre><p>What the heck are these names!? Renorda? Shanndolyn? It turns out that these four names <em>only showed up in the data in 1980</em>. So these names are extremely obscure, and very rarely used. So if I said the four names that indicate the birthday of 1980 are “Nykeba, Sumeka, Renorda, and Shanndolyn” then yes, those names were only used in 1980 and thus I indicated the year. However, implicit in the question was the assumption that <em>the person I am talking to has heard the names before.</em> My statistical formulation of the question failed to account for something that was never said but really necessary. So if we want to take into account that the person who you are talking to has to have heard of the names, we need a new approach</p><h4>Attempt 2: Using names that are the most above their average to indicate a year.</h4><p>The issue with attempt one is it didn’t take the popularity of the name into account, only the informative power of the name. The idea of using the average popularity of the name and the popularity within the year seemed like it still had promise, so what if we changed it to the difference between the two numbers?</p><p>This gives formulation two: What set of four names names have the highest increase in their usage from their average in a given year? So if averaged across years male Michaels are 1% likely, if in a particular year male Michaels are 5% of children then we would give that a value of 4%? What names have the highest value?</p><p>So again using the total probability table from before, lets compute a new most informative table. Now the value is the difference between the probability for that year and the total one.</p><pre>most_informative_diff &lt;-<br>  babynames %&gt;%<br>  inner_join(total_props,by=c(&quot;sex&quot;,&quot;name&quot;)) %&gt;%<br>  mutate(value = prop - total_prop) %&gt;%<br>  group_by(year) %&gt;%<br>  filter(row_number(desc(value)) &lt;= 4) %&gt;%<br>  ungroup() %&gt;%<br>  arrange(year,desc(value))</pre><p>And let’s view the table for 1980:</p><pre>&gt; most_informative_diff %&gt;% filter(year == 1980)<br># A tibble: 4 x 7<br>   year sex   name            n   prop total_prop  value<br>  &lt;dbl&gt; &lt;chr&gt; &lt;chr&gt;       &lt;int&gt;  &lt;dbl&gt;      &lt;dbl&gt;  &lt;dbl&gt;<br>1  1980 F     Jennifer    58381 0.0328    0.00609 0.0267<br>2  1980 M     Jason       48173 0.0260    0.00413 0.0218<br>3  1980 M     Michael     68673 0.0370    0.0178  0.0192<br>4  1980 M     Christopher 49088 0.0265    0.00785 0.0186</pre><p>Great! These look like popular names from 1980! And if you look at the different years the names seemed aligned to the popular ones from that time. Unfortunately, now the years tend to blend together. Let’s look at the four names 1978–1982. Here I add the rank of the name within the year, and a name_gender variable I create to make a table. I use the tidyr spread function so we can see all this data at once</p><pre>most_informative_diff %&gt;%<br>  group_by(year) %&gt;%<br>  mutate(rank = paste0(&quot;rank_&quot;,row_number())) %&gt;%<br>  ungroup() %&gt;%<br>  mutate(name_gender = paste0(name,&quot;-&quot;,sex)) %&gt;%<br>  select(year,rank,name_gender) %&gt;%<br>  spread(rank,name_gender) %&gt;%<br>  filter(year &gt;= 1978, year &lt;= 1982)</pre><p>The results are:</p><pre># A tibble: 5 x 5<br>   year rank_1     rank_2        rank_3        rank_4       <br>  &lt;dbl&gt; &lt;chr&gt;      &lt;chr&gt;         &lt;chr&gt;         &lt;chr&gt;        <br>1  1978 Jennifer-F Jason-M       Michael-M     Christopher-M<br>2  1979 Jennifer-F Jason-M       Christopher-M Michael-M    <br>3  1980 Jennifer-F Jason-M       Michael-M     Christopher-M<br>4  1981 Jennifer-F Jessica-F     Michael-M     Christopher-M<br>5  1982 Jennifer-F Christopher-M Jessica-F     Michael-M</pre><p>If you look, the only difference in the names between the five years is that Jason is replaced by Jessica in 1981. <em>That’s not great for our objective of using names to guess the year.</em> Here is a plot of the probabilities of the four names from 1980. You can see that while they all do peak around that time, there is a fair number of other years where they are high:</p><pre>most_informative_diff %&gt;%<br>  filter(year == 1980) %&gt;%<br>  semi_join(babynames, ., by = c(&quot;name&quot;,&quot;sex&quot;)) %&gt;%<br>  mutate(name_gender = paste0(name,&quot;-&quot;,sex)) %&gt;%<br>  ggplot(aes(x=year,y=prop,group=name_gender, color = name_gender))+<br>  geom_line(size=3) +<br>  theme_minimal(20)+<br>  labs(x=&quot;Birth year&quot;,y=&quot;Probability&quot;,color = &quot;Name and assigned gender&quot;)</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*yIqSwBikCN3vVQTS_WQOkQ.png" /></figure><h4>Attempt 3: Fuck it let’s just make a cool interactive visualization to wow people.</h4><p>While I could have spent ten more hours trying to precisely come up with the best statistical framing of the problem, I wanted to try something different. If the goal is to convey some meaning from data, often it’s better to make something interesting that causes the person to think more deeply about it. And sometimes you just have business executives that like playing with things. Whatever your situation, interactive visualizations are great.</p><p>I decided to use the R package shiny to create a random sample classroom. This is a great way to see what the names of the people around you would be like if you were born in a certain year. It conveys the popular names, plus what the unpopular ones are like. <a href="https://skyetetra.shinyapps.io/my-classroom/"><strong>Try it for yourself!</strong></a> If you want to play with the very short code, <a href="https://gist.github.com/jnolis/79bb88a0424322d8cd867ad5710c31dc">it’s available on GitHub</a>.</p><figure><a href="https://skyetetra.shinyapps.io/my-classroom/"><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*2MpAo3tCxvJLMNiBuSuBXw.png" /></a><figcaption>The my-classroom tool showing a class from the year 2000. You can tell the year by the three Jacobs and two Alex…es(?). Click the picture to try it for yourself!</figcaption></figure><p>This small project was a great reminder for me that simple questions may not be easy to solve with data science. Even if you have all the data you could ever need in one single table, coming up with a way of turning the question into an analysis can be a show stopper. While this was a fun mini-project, the same thing can happen with business questions like “which customers have the highest retention?” or “how many products have we produced this quarter?” In these instances the best thing you can do for yourself and the people you are working with is immediately tackle the framing of the question and get buy in before spending a ton of time just making interactive visualizations.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=17c8cbb8d0a5" width="1" height="1" alt=""><hr><p><a href="https://medium.com/data-science/guessing-the-year-you-were-born-from-baby-names-using-r-17c8cbb8d0a5">Guessing the year you were born from baby names using R</a> was originally published in <a href="https://medium.com/data-science">TDS Archive</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Red flags in data science interviews]]></title>
            <link>https://medium.com/data-science/red-flags-in-data-science-interviews-4f492bbed4c4?source=rss-1adb4927e341------2</link>
            <guid isPermaLink="false">https://medium.com/p/4f492bbed4c4</guid>
            <category><![CDATA[interview]]></category>
            <category><![CDATA[data-science]]></category>
            <dc:creator><![CDATA[Jacqueline Nolis]]></dc:creator>
            <pubDate>Wed, 04 Jul 2018 06:13:05 GMT</pubDate>
            <atom:updated>2020-08-16T06:47:23.110Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*04ykGEYruRcTALrKlbYs3Q.jpeg" /></figure><p><em>This post was co-written with </em><a href="http://hookedondata.org/"><em>Emily Robinson</em></a><em>, a data scientist at Warby Parker. She and I also wrote a related book: </em><a href="http://bestbook.cool"><em>Build Your Career in Data Science</em></a><em>.</em></p><p>When interviewing for any position, you should be evaluating the company just as much as they are evaluating you. While you can research the company beforehand on glassdoor and similar sites, interviews are the best place to get a deeper understanding of the company and ask important questions. Companies will never straight up tell you they are bad to work for, so you have to look for the signs yourself.</p><p>Here is our list of 12 signs the company you are interviewing with for a data scientist job should be avoided (and the questions to ask during the interview). The first six mainly apply to companies that already have multiple data scientists or analysts. If you’re thinking of joining a company as their first data scientist, you’ll face a whole different set of challenges, including most likely doing a lot of data engineering work (see flag 1) and spreading a data science mindset. Someone has to do it, but we generally advise against it for your first data science role unless you come from an engineering background and want to do that work. If there’s just a data science leader and they’re building out a team, ask how they plan to handle the issues raised below, but keep in mind it’s always easier to promise an ideal system than implement one.</p><h3>Red flags on how the data science team runs</h3><h4>1. No data engineering or infrastructure.</h4><p>Data science requires data to be easily available for analysis. If the company doesn’t have a well-maintained data infrastructure, you won’t have what you need to do your job. A data engineer is a person who prepares data for analysis, and if your company doesn’t have them you’ll have to do the work yourself. If you feel qualified to take on the role of a data engineer that may be okay, but otherwise you’ll be struggling to deliver anything of value.</p><p><em>Question to ask during the interview: what is your data infrastructure like and who maintains it? What format is the data typically in (Excel, a SQL database, csv)?</em></p><h4>2. No peer review between data scientists.</h4><p>A strong data science team will have ways to ensure mistakes don’t slip through the cracks. These can include code reviews, practice presentations, and consistent check-ins with the team. If the team doesn’t consistently do these, mistakes won’t be found until the work is already delivered, which usually ends with someone getting reprimanded.</p><p><em>Question to ask: what steps does the team take for QA and peer review?</em></p><h4>3. No standard set of languages on the team.</h4><p>Many data science teams take the approach of letting anyone on the team use any language they want. The idea is that if everyone uses their favorite languages work will be completed faster. There is a huge problem with this: when everyone uses separate languages, no one will be able to pass off work to anyone else. Every data science task will have a single person responsible for it, and if they quit, get sick, or just need help no one will be able to do so, creating a very stressful environment. It’s fine to use R, Python, or even dare we say SAS, but just have a consistent set of languages amongst the team.</p><p><em>Question to ask: what languages does your team use, and how do you decide whether to adopt a new one?</em></p><h4>4. They don’t understand the <a href="https://hackernoon.com/the-ai-hierarchy-of-needs-18f111fcc007">data hierarchy of needs</a>.</h4><p>Similar to not having a data infrastructure, some companies get really excited about concepts like AI without having the foundation in place. Machine learning and AI require a company to have a high level of data science maturity, including understanding how to build models, their limitations, and how to deploy them. You might get blamed when their unrealistic expectations meet reality.</p><p><em>Question to ask: how does the company balance spending time on complex approaches like AI with foundational work like cleaning data, checking data quality, and adding logging?</em></p><h4>5. No version control.</h4><p>Mature data science teams use git to keep track of changes to analyses and code. Other teams instead use methods like shared network folders, which don’t let you see when things changed, why they are changed, or previous versions. Occasionally teams don’t share code at all and work just lives on the data scientists individual laptops. Avoid these last groups like the plague. Not having methods of sharing code means the team can’t work together.</p><p><em>Question to ask: how to you share code amongst the team? Is all code shared or just some of it?</em></p><h4>6. No clear delineation between people who run reports vs do analyses.</h4><p>The skillsets required to create and maintain reports, to build data science models, and to put machine learning models into production are all different. If the company doesn’t have a clear way of determining who does what work, you could start your job and end up doing work totally different than what you expected. You don’t want to walk in on your first day expecting to build a time-series forecast and find out your job is to refresh the monthly sales Excel spreadsheet.</p><p><em>Question to ask: how are reporting, analysis, and production-model building tasks split?</em></p><h3>Red flags on how they value people</h3><h4>1. A totally non-structured interview process.</h4><p>A structured interview process means that each candidate gets the same set of questions and can be more equally compared. Not only does [it decrease bias](<a href="https://hbr.org/2016/04/how-to-take-the-bias-out-of-interviews">https://hbr.org/2016/04/how-to-take-the-bias-out-of-interviews</a>), it also requires the team think through what’s important in the people they bring on. If the interview process is unstructured, with the interviewer seemingly asking questions off the top of their head, then it’s a strong sign they haven’t figured out what they want in a candidate and how to get it. If they don’t know what they want you are going to have trouble giving them what they want on the job.</p><p><em>Suggestion: see if they bring a set of questions to the interview, or ask the meta-question of how they chose what to ask you.</em></p><h4>2. No time for your questions.</h4><p>Since interviews are also for you to find out about the company, you need to have time to do so. If there isn’t time for you to ask questions, the interviewer isn’t interested in making you feel comfortable and allowing you to assess your fit.</p><p><em>Suggestion: if you get to the interview and you didn’t have time to ask questions, make a note of it and ask the interviewer when would be a good time to ask them instead.</em></p><h4>3. No coding required in the interview.</h4><p>While programming isn’t the most important skill for a data scientist, it is something you will have to do on the job. The coding part of the interview could be on-site or a take-home test, but it should definitely exist. If the interview process doesn’t include programming it could be for a few reasons: (1) The data science team is new so no one can run the interview. In this case, be aware you won’t have support on the job. (2) The team doesn’t have the time to create a programming interview. This is a sign they don’t value hiring. (3) They don’t program and use BI tools like Tableau and Excel for their work. (4) They trust your resume so much that they don’t need to test you, while is flatting but a sign that they are desperate to hire.</p><p><em>Suggestion: if the interview doesn’t include a programming component, ask them how do they tell which candidates have the technical skills for the job.</em></p><h4>4. No plan for your first few months.</h4><p>Companies put job postings out for good reasons. If they aren’t able to clearly articulate exactly what you’ll be doing in the first few months, that reason is probably “we are totally overwhelmed with work and we are going to throw people at the problem until we can handle it.” That’s an extremely dangerous way to grow a team. What’s worse, this usually happens at the companies that don’t have onboarding processes for new hires. So these situations are extremely stressful for the whole team and that usually falls on you too.</p><p><em>Suggestion: ask if they have a clear project and on-boarding process for your start. If they don’t have an extremely precise answer for this, run.</em></p><h4>5. No support continuing education.</h4><p>Data science is a large and rapidly advancing field and if you don’t keep learning you’ll fall behind. Teams should have some way of helping people keep up, whether it’s by providing funding for online education or attending conferences, monthly meetings where you discuss industry blog posts, encouragement to attend meetups or get involved in open source, or a speaker series. This also shows they’re willing to invest in their people generally.</p><p><em>Suggestion: ask how they support the continued education of the team. Is there funding for conferences or workshops?</em></p><h4>6. Inconsistent answers between interviewers about the role</h4><p>Usually interviews have you talking to many people within the company, including your future manager, teammates, and business stakeholders. If they each tell you different things around the level of responsibility, type of work, what the role delivers, and hours you’ll have to work, they themselves probably don’t agree. If they can’t agree, especially on things related to what work you’ll end up doing, your job will end up being full of conflict.</p><p><em>Suggestion: keep track of what people say in different interviews. If you find an inconsistency, ask why.</em></p><p>While these twelve flags may feel like a lot, companies tend to show none of them or most of them, with only few in the middle. By keeping an eye out of them you can avoid the problem of getting to a job you dislike. Good luck!</p><p>If you want a ton of ways to help grow a career in data science, check out the book Emily Robinson and I wrote: <a href="http://bestbook.cool"><em>Build a Career in Data Science</em></a>. We walk you through getting the skills you need the be a data scientist, finding your first job, then rising to senior levels.</p><figure><a href="http://bestbook.cool"><img alt="Build a Career in Data Science book cover" src="https://cdn-images-1.medium.com/max/1024/1*-8Z7-VCmxy94wKZR19Ta_w.jpeg" /></a></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=4f492bbed4c4" width="1" height="1" alt=""><hr><p><a href="https://medium.com/data-science/red-flags-in-data-science-interviews-4f492bbed4c4">Red flags in data science interviews</a> was originally published in <a href="https://medium.com/data-science">TDS Archive</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
    </channel>
</rss>