tag:verbadam.com,2014:/feedAdam Phillabaum2015-08-14T23:28:04-07:00Adam Phillabaumhttp://verbadam.comSvbtle.comtag:verbadam.com,2014:Post/counting-redis-client-connections2015-08-14T23:28:04-07:002015-08-14T23:28:04-07:00REDIS: Connection Count by Client<p>I just wanted a quick way to see where connections to my redis server were coming from, and how many there were. The redis <a href="http://redis.io/commands/client-list">CLIENT LIST</a> command had all the info, I just needed to massage it.</p>
<pre><code class="prettyprint lang-bash">AdamP@cartographer ~> redis-cli -h myredisserver CLIENT LIST | sed -n 's|.*addr=\(.*\)\:.*|\1|p' | sort | uniq -c
2 127.0.0.1
686 192.168.0.141
2 192.168.0.144
8 192.168.0.20
6 192.168.0.66
4 192.168.0.67
</code></pre>
<p>May your google searches lead you here, to prevent you from having to pipe this yourself.</p>
tag:verbadam.com,2014:Post/when-in-doubt-delete2015-05-05T09:00:17-07:002015-05-05T09:00:17-07:00When In Doubt: Delete<p>People have known about effective communication for a long time, here is one of the best and earliest expressions of it, by <a href="http://en.wikiquote.org/wiki/Blaise_Pascal">Blaise Pascal in 1656</a>.</p>
<blockquote class="short">
<p>I would have written a shorter letter, but I did not have the time.</p>
</blockquote>
<p>And, here is my implementation of that rule: <strong>Delete things that aren’t important.</strong></p>
<p><a href="https://www.flickr.com/photos/ervins_strauhmanis/10135243453" title="Delete key by Ervins Strauhmanis, on Flickr"><img src="https://farm3.staticflickr.com/2894/10135243453_d66ac7be69_z.jpg" width="640" height="427" alt="Delete key"></a></p>
<h2 id="definitions_2">Definitions <a class="head_anchor" href="#definitions_2">#</a>
</h2>
<p>In general communications, verbosity is bad. Conciseness is good. By nature, I’m verbose. So, to become a better communicator, I’ve had to actually think and practice at it. It’s all about clarity, which is balancing accuracy, precision.</p>
<ul>
<li>Accuracy: how true is this statement.</li>
<li>Precision: how much detail is in this statement</li>
<li>Clarity: <em>I’ll spend more time on this below</em>
</li>
</ul>
<p>Here is a statement that is <strong>entirely accurate, and only a little precise</strong>: George H.W. Bush was born in Massachusetts.</p>
<p>Here is a statement that is <strong>precise, but not entirely accurate</strong>: George H.W. Bush was born in a Seattle, a rural community in western Washington. President Bush spent his days galavanting around the oil fields and cranberry bogs.</p>
<h2 id="example_2">Example <a class="head_anchor" href="#example_2">#</a>
</h2>
<p>The most success I’ve had with this is when I’m making blanket statements about software to non-technical people. I’ll illustrate it with an example from real life.</p>
<p>The original ‘bad clarity’ version of a statement:</p>
<blockquote>
<p>When we prop code (that’s what we call it when we deploy), we typically have no downtime. In the last 2 years, we’ve only had one prop with an issue that caused downtime. When we prop, a controlled fraction of our servers are taken out of service and updated, so it all happens transparently to the user.</p>
</blockquote>
<p>Here is a ‘good clarity’ version:</p>
<blockquote class="short">
<p>When we deploy a new feature to the website, we have no downtime.</p>
</blockquote>
<p>This is clarity in action. The sentence is not 100% accurate, but it’s probably 99.9% accurate. And, by reducing the precision we’ve increased the clarity 1000-fold.</p>
<h2 id="final-thoughts_2">Final Thoughts <a class="head_anchor" href="#final-thoughts_2">#</a>
</h2>
<p>One caveat to all of this: when precision matters, don’t sacrifice! Sometimes you need to be very verbose… just recognize your audience and your message.</p>
<p>I recognize that this is a long-winded post on being concise and clear. The irony is not lost on me. I’m just trying to write this down as fast as possible. If I had more time, I would have written a short blog post.</p>
<p>Small side story: the name for this blog was born as my coworkers were mocking me for being too verbose, or Verbadam as it became known as.</p>
<p>Anyways: if you’re verbose like me, delete unnecessarily precise stuff.</p>
<p><a href="https://news.ycombinator.com/item?id=9494124">Discuss on HackerNews</a></p>
<p><a href="https://svbtleusercontent.com/alsxcjpqumgtfg.jpg"><img src="https://svbtleusercontent.com/alsxcjpqumgtfg_small.jpg" alt="R48tmGG.jpg"></a></p>
tag:verbadam.com,2014:Post/analysis-of-how-much-candy-i-ate2014-11-05T21:08:27-08:002014-11-05T21:08:27-08:00The Halloween Calorie Penalty<p><img src="https://svbtleusercontent.com/lhzpt6fnt8hifw_small.png" alt="Candy Analysis Spreadsheet"><br>
This is the first year we’ve lived in a house in a neighborhood that might have kids trick-or-treating, so naturally, we bought the big bag of candy from Costco – 150 pieces.</p>
<p>We had 8 kids show up. And, we tried to push a bunch on them, but we still only offloaded about 20 pieces on the kids. My wife is on her way to canonization for how little of the candy she’s eaten (and, my daughter pulled in her own stash)</p>
<p>So, I wanted to figure out just how much candy I’ve eaten in the 5 days that have elapsed since we opened the bag.</p>
<ul>
<li>Snickers: 1,450 calories</li>
<li>Reese’s: 924 calories</li>
<li>Milky Way: 870 calories</li>
<li>Plus the calories from Crunch bars, Peanut M&Ms, Kit Kats, Almond Joys, and Twix (no plain M&M’s were consumed, because they’re nothing compared to the others in this bag)</li>
</ul>
<p>For a grand total of 5,651 calories of candy in the last 5 days. That’s a lot of calories. So, to put it into perspective, <a href="http://www.runnersworld.com/weight-loss/how-many-calories-are-you-really-burning?page=single">I’ve converted it into miles jogging</a>: 53 miles.</p>
<p>Want to see the data, here is my <a href="https://docs.google.com/a/phillabaum.us/spreadsheets/d/1FlgRi1MqYyQkujhYfTyXw_XNGvVcBJNxkjeUUYymV1Q/edit?usp=sharing%5B!%5BScreen%20Shot%202014-11-05%20at%209.03.11%20PM.png%5D(https://svbtleusercontent.com/ldkkqjnji9bkq_small.png)%5D(https://svbtleusercontent.com/ldkkqjnji9bkq.png)">2014 Halloween Candy Consumption spreadsheet</a>.</p>
tag:verbadam.com,2014:Post/watch-what-i-do-dont-listen-to-what-i-say2014-09-29T10:45:50-07:002014-09-29T10:45:50-07:00Watch What I Do, Don't Listen to What I Say.<p><a href="https://www.flickr.com/photos/vestman/3871170258/"><img src="https://svbtleusercontent.com/vtdae6pzfklyzw_small.jpg" alt="Binoculars"></a></p>
<p>Let me preface this whole thing by saying: I <em>love</em> in-person user tests. In fact, we do them about once every-other-week at <a href="http://www.rivaliq.com">Rival IQ</a>, just to watch a new user interact with our app. It’s always eye-opening and definitely helps you reset your perspective on your latest work(s). We’ll always do them.</p>
<p>With all that said: it’s almost total bullshit. </p>
<p>You have to take everything you see with a grain of salt. User tests are nigh impossible to run well enough to get concrete direction from. So, this blog post is about not doing that (maybe I’ll write one about users tests another time).</p>
<p>My biggest beef is that the user is in a totally foreign context. “Come to our office, sit in this unfamiliar chair, use this Mac, talk out loud about everything you’re doing, feel awkwardly watched and, oh, can you be here at exactly 2:30PM? And, one more thing, we’re recording this and simulcasting it to the other room where eight more people are watching.”</p>
<p>Here is how someone normally uses your product for the first time: “Oh shit! I’ve got a boat load of reporting to do for my next meeting. What was that website that Jamie told me about? I should use that next time.” Repeat that 5 times, and then at some point you’ll finally visit our site. You’ll probably be sitting at your desk, using your normal computer, drinking coffee, get interrupted by email, coworkers, lunch, coffee, and you won’t feel like you’re being watched.</p>
<p>So, what to do? Your first step is to watch people use your product in their normal context. Use tools like <a href="http://www.inspectlet.com/">Inspectlet</a> and <a href="http://mouseflow.com/">Mouseflow</a>. These are great. Use them.</p>
<p>But, this is the real thing I want you to do: <strong>instrument the ever-loving-hell out of your app</strong>, and look at how people use your site in bulk. Some really smart and cheap people (like myself) tend to favor Google Analytics, some favor Kiss Metrics, and even some favor homegrown logging with Tableau and/or Splunk (those people tend to work at really well funded companies, because the price tag isn’t small).</p>
<p>If you don’t suck at building things on the internet, your site will eventually have more traffic than you can evaluate by watching everyone on the site. Inspectlet, Mouseflow, and user tests become gut checks… but reality doesn’t come until your metrics are measuring a meaningful difference.</p>
<p>Here are my two insanely actionable pieces of advice (sorry, I’ve been reading too much buzzfeed and inbound.org recently)</p>
<p>How should you instrument? Here is a piece of advice from my dad about interacting with air traffic controllers: <strong>“Tell ‘em who you are, where you are, and what you are doing.”</strong> Turns out, it applies to remote chunks of code reporting to a centralized service too.</p>
<p>What should you instrument? <strong>Everything the user does on the site and everything the site does for the user</strong>. So, you’ll track: page views, button clicks, etc. And, you’ll track emails sent, remote data collected, batch processes running on their behalf, etc.</p>
<p>Here is a bonus piece of insanely actionable advice: <strong>Make sure your user data is joinable to your metrics data</strong>. I guarantee when you get to that “I don’t suck at the internet” level of users, you’ll want to know things like: “how do users with gmail addresses behave?” Or “How likely is someone who analyzes a big/medium/small company to buy our product?”</p>
<p>Adam, out.</p>
<p><a href="https://www.flickr.com/photos/vestman/3871170258/">Cover photo by Vestman</a>.</p>
tag:verbadam.com,2014:Post/assume-youre-wrong2014-07-08T21:29:29-07:002014-07-08T21:29:29-07:00Assume You're Wrong<p>I was at <a href="http://www.payscale.com/">PayScale</a> for a little over 7. <a href="https://www.linkedin.com/profile/view?id=14483039">I’ve</a> <a href="https://www.linkedin.com/profile/view?id=364586">had</a> <a href="https://www.linkedin.com/profile/view?id=542416">some</a> <a href="https://www.linkedin.com/profile/view?id=117119">really</a> <a href="https://www.linkedin.com/profile/view?id=1269287">incredible</a> <a href="https://www.linkedin.com/profile/view?id=386439">mentors</a> along the way, and after several years, I’ve synthesized a lot of my learning into one simple sentence: <strong>Assume You’re Wrong</strong>.</p>
<p><a href="https://svbtleusercontent.com/bi6i9iu41cm2jg.jpg"><img src="https://svbtleusercontent.com/bi6i9iu41cm2jg_small.jpg" alt="Facepalm"></a></p>
<p>I started taking this philosophy after designing several A/B tests and having all of our awesome designs and ideas ultimately fail when put in front of users. For the next test, my boss at the time, <a href="http://douglastarr.com/">Doug</a>, said: “Adam, what do we learn when this test fails?” I remember thinking: “oh sh*t. This is such an obvious thing to be asking myself, but I haven’t been.” It was one of my rare moments of introspection that help transform me: I need to assume that I’ve gotten at least one thing wrong, and that that was OK, but I needed to understand that a flaw existed.</p>
<p>One of the most difficult problems as a program or product manager is that you become attached to your <u>solution</u> to a problem, and forget that a flaw exists in your plan. Then, when someone criticizes that solution, you become defensive. If you take the approach that what you’ve come up with just <u>one</u> of the many possible solutions to that problem and that another solution to that problem may be better, you’re leaving yourself open to improving your product. </p>
<p>And, even before you’re talking or showing a potential solution to others, you can use this position to help you be critical of your own work. When you assume that there is a flaw in your logic or solution, you’ll be looking for one, and odds are that you’ll find one.</p>
<p>Feedback can come from anywhere. Don’t discount it even if it came from source you don’t like. Assume they know something, and that you may be wrong.</p>
tag:verbadam.com,2014:Post/how-to-make-1200-with-r2014-04-25T23:26:31-07:002014-04-25T23:26:31-07:00How to Make $1,200 with R<p>“How much should I rent my condo for?”<br>
Turns out, the answer is: “Guess.”<br>
So, I built the data-driven solution this problem.</p>
<p>Our family has spent the last year trying to buy a house in Seattle, and we’ve finally hit the mark and we’re moving in a couple week. But, what should we do with our condo? We’ve decided to keep it, and rent it out. But, as a mediocre software engineer and a person obsessed with data, how should I go about it? Zillow has rental zestimates, but they seem to be really lagging. Guessing didn’t seem right. So, I’ll do my own.</p>
<h2 id="getting-the-data_2">Getting the Data <a class="head_anchor" href="#getting-the-data_2">#</a>
</h2>
<p>I know craigslist is the king of rental listings, so I went there to see if I could find some units comparable to mine. Turns out, it was super easy, I just filtered it to “queen anne” units with 2+ bedrooms. And, there is an associated RSS feed for this page now too.</p>
<p>Here is my example search, and the associated RSS.</p>
<p>This list is neither comprehensive nor perfect. But, definitely good enough to make this as a proof-of-concept and help me figure out the value of my unit.</p>
<h2 id="formatting-the-data_2">Formatting the Data <a class="head_anchor" href="#formatting-the-data_2">#</a>
</h2>
<p><a href="https://svbtleusercontent.com/dto3ntc8ohsgrq.png"><img src="https://svbtleusercontent.com/dto3ntc8ohsgrq_small.png" alt="1-dq_T3OBWPioZG59HPc5O_w.png"></a><br>
I’ve chosen to use <a href="http://www.r-project.org/">R</a> as my tool of choice to do this analysis, because (a) everybody else seems to be using it, and (b) I think it’ll make what I want to do super easy. Unfortunately, I’m damn-near illiterate in R, and I’m too stubborn to read an intro or anything. So, I muddled my way through on my little knowledge and a lot of hacks.</p>
<p>The second (and almost always the hardest) step in a problem like this is getting the data into a “learnable” format. I had the data as an RSS, but how could I get that into R? Well, I had to figure out how to turn it into a CSV, because that’s the only way I know how to get data into R.</p>
<p>If you don’t know, there are a couple of amazing functions in Google Spreadsheet that make web scraping easy (and RSS scraping borderline illegal): ImportXML, ImportHTML, <a href="https://support.google.com/drive/answer/3093337?hl=en">ImportFeed</a> and ImportData.</p>
<p>In cell A1, I put this formula: </p>
<pre><code class="prettyprint">=importFeed(“http://seattle.craigslist.org/search/apa?bedrooms=2&catAbb=apa&query=queen%20anne&s=0&format=rss”)
</code></pre>
<p>And, I instantly had 20 rows of data from craigslist. Now, for some things to regress on. Based purely on intuition (thanks Andrew Ng for using that word so often during the Coursera Machine Learning class) and effort-level required to extract the data, I was going to build a model on:</p>
<ul>
<li>Square footage</li>
<li>number of bed rooms</li>
<li>number of bathrooms</li>
</ul>
<p>There are a couple of other things that I’d like to take into account later, but haven’t had the time to yet: WalkScore, year built and quality (judging the pictures)<br>
With a couple of simple formulas, I was able to get the easy stuff out:</p>
<pre><code class="prettyprint">Price:
=iferror(REGEXEXTRACT(A2,”\$(….)”),””)
Square footage:
=iferror(REGEXEXTRACT(A2,”([0-9]{3,4})sqft”),””)
Number of bedrooms:
=iferror(REGEXEXTRACT(A2,”(.)bd”)&”bed”,””)
Number of bathrooms: =iferror(REGEXEXTRACT(A2,”(\d)\s{0,1}ba”)&”bath”,””)
</code></pre>
<p>Turns out the number of bathrooms was unusable because the number is not in a standardized format in the title like the others. So, I ended up excluding it from my model because it wouldn’t have been able to contribute anything. Also, bathrooms are usually listed as: 1, 1.25, 1.5, 1.75, 2, 2.25, etc… so this regex doesn’t work well</p>
<p>Next, it’s much easier to build a model when you’ve “dummy coded” the categorical values. So, I had to get the number of bedrooms split up. I’ve included a screenshot of what this looks like. But basically, I created a column called “2bed”, and put a 1 in the row if that was a 2 bedroom unit, 0 if it was something else. Then did the same for 3 bedrooms, and 4 bedrooms</p>
<p>Now, I just saved this to CSV.</p>
<p>For those of you who prefer the “just effin’ show me!” approach, <a href="https://docs.google.com/spreadsheet/ccc?key=0Ar4kfZZXcgkddGpkTGhVRnpzNWlwdGtPM1RRcmJzb1E&usp=sharing">here is the spreadsheet</a>.</p>
<h2 id="building-the-linear-model-in-r_2">Building the Linear Model in R <a class="head_anchor" href="#building-the-linear-model-in-r_2">#</a>
</h2>
<p><a href="https://svbtleusercontent.com/toe8uddgpwrhbg.png"><img src="https://svbtleusercontent.com/toe8uddgpwrhbg_small.png" alt="1-OLNYYpOtbFrrowRtTFF1yw.png"></a><br>
This might be cheating… but I’m actually using <a href="https://www.rstudio.com/ide/download/">RStudio</a>. It seems to make things a little easier to understand. Once I had usable data in a CSV, building the model was actually really easy. It was only a few lines!</p>
<pre><code class="prettyprint">rents = read.csv(“Documents/adam/house/qarents.csv”)
rents <- head(rents,20)
m <- glm(price ~ sqft + X2bed + X3bed, data=rents)
predict(m,data.frame(sqft=909,X2bed=1,X3bed=0,X4bed=0))
</code></pre>
<p>Et viola! I’ve got an answer for what I’m going to rent our condo for! (kind of)</p>
<h2 id="conclusion_2">Conclusion <a class="head_anchor" href="#conclusion_2">#</a>
</h2>
<p>Based on my work, I think I’m actually going to ask for $100/month more than I had planned.</p>
<p>I noticed that professional property management companies are purposely posting units several times at slightly different locations, and us “do it yourselfers” stick to the rules (a little). Properties with professional management are typically higher-valued-units. Therefore, the ratio of high-to-low cost units on craigslist is disproportional to reality. So, I just kind of dropped my price a little.</p>
<p>Anyways, this was a fun Friday-night-while-watching-DS9-and-drinking-High-Life project.</p>
<h3 id="changes_3">Changes <a class="head_anchor" href="#changes_3">#</a>
</h3>
<p>Google Spreadsheets will refresh the data from the RSS feed, so to streamline the process of getting new data, I quit using Excel and save to CSV straight from Google Spreadsheet.streamline the process of getting new data, I quit using Excel and save to CSV straight from Google Spreadsheet.</p>
<p><a href="https://medium.com/data-and-analysis/24ef2d227985">Originally posted on Medium</a>.</p>
tag:verbadam.com,2014:Post/my-tips-for-presentations2014-04-25T23:15:05-07:002014-04-25T23:15:05-07:00My Tips For Presentations<p>I have a problem: I naturally give horrible presentations. </p>
<p><a href="https://svbtleusercontent.com/ywiww7iwt9ipmg.png"><img src="https://svbtleusercontent.com/ywiww7iwt9ipmg_small.png" alt="Adam_at_Dept_of_Education_Datapalooza.png"></a></p>
<p>In January, I had to give a <a href="https://www.youtube.com/watch?v=y3P5-DvUZPU">presentation</a> to ~600 people in Washington DC. I was scared out of my damned mind. So I came with a couple of “todos” in my preparation:</p>
<ol>
<li>Prepare like I’ve never prepared before. </li>
<li>In general, get more comfortable giving presentations, so I wouldn’t be so scared.</li>
</ol>
<p>I know, the last thing the world needs is a bullet-point list saying: “don’t use bullet points.” So, I’ll leave the irony to others. And, yes, I’m aware that there are literally <a href="https://www.google.com/search?q=tips+for+presentations">~55,000,000</a> <a href="http://www.lifehack.org/articles/communication/18-tips-for-killer-presentations.html">articles</a> <a href="http://www.washington.edu/doit/TeamN/present_tips.html">on</a> <a href="http://www.ted.com/talks/nancy_duarte_the_secret_structure_of_great_talks">the</a> <a href="http://www.inc.com/ss/5-tips-for-a-great-powerpoint-presentation">internet</a> <a href="http://www.slideshare.net/soappresentations/52-presentation-tips-the-best-of-2013">about</a> <a href="http://www.toastmasters.org/mainmenucategories/freeresources/needhelpgivingaspeech/tipstechniques/10tipsforpublicspeaking.aspx">this</a> (well, I’m aware now that I’ve looked that up). But, this doc is as much for me as it is for you. </p>
<p>Now that I’ve done a couple presentations in public forums of varying shapes and sizes, here are a few tips:</p>
<ul>
<li>Practice. Seriously. Do it. Practice your presentation at least twice. Once to find the “bugs” and a second pass to test your fixes. If you have the guts, video yourself.</li>
<li>Make it flow. Transitions between slides shouldn’t feel abrupt, they should feel like a natural progression of your talking. These become really obvious when you practice your presentation.</li>
<li>If you’re using slides, make them not suck. Lots of text on slides is bad in most scenarios. My rule is: one word is best, but never more than one piece of punctuation. There are several tools out there to help with this: <a href="http://slidebureau.com/">Slide Bureau</a>, <a href="http://www.haikudeck.com/">Haiku Deck</a>, and more. But know this: one of the best presentations I’ve seen in recent history had NO slides. Don’t feel required to make slides!</li>
<li>Do not drink alcohol beforehand. It will not make you loose and freeflowing and engaging. It will make you hard to understand and incoherent. Yeah, you could probably sip on a beer, but honestly… why risk it?</li>
<li>There is a time limit. Either, it’s an official one and someone is timing you OR there is a threshold at which 80% of the crowd switches to “done yet?” mode. Recognize these things. You’ve never been mad at someone for being done with a presentation quickly, but you sure as heck have for some long and rambly presentation. Going past your limit is ALWAYS bad, mmmmkay.</li>
<li>You may have spend the last 7 years of your life working on whatever you’re presenting on, but the audience (likely) hasn’t. Give everyone a high-level background, so they can understand what the eff you’re talking about.</li>
</ul>
<p>Recognize that all of these tips come from my repertoire of mistakes. And as an old German guy once said: “A fool learns from his mistakes, but a truly wise man learns from the mistakes of others.” Be smarter than I.</p>
<p>And, if you’re wondering, I did pretty well in my presentation. I’d score it a 7/10. You wouldn’t watch me at TED (or even TEDx), but people weren’t boo'ing me either.</p>
<p><a href="https://svbtleusercontent.com/qpvrratbv1veg.jpg"><img src="https://svbtleusercontent.com/qpvrratbv1veg_small.jpg" alt="tumblr_lqrrylVyfU1qkb66ro1_400.jpg"></a></p>
<p>Thanks <a href="https://twitter.com/myronm">@myronm</a> for the proofread.</p>