Another Git cheatsheet

This one is pretty cool.

Git Cheatsheet

It shows all commands relative to what portion of the conceptual workspace they modify – e.g. stash, workspace, index, local repository or remote repository.

That said, it stops at the one-line summary for a command. In looking at this, it would be cool if you could see commands in action in terms of how they modify data, but still at the logical level, not as yet another of the interactive git tutorials.

Towards a new reading list for software engineers

I need to update my recommended reading list for engineers, particularly to give it more depth, so I’ve been looking at lots of books lately. My first lists were aimed at relatively new engineers, covering the basics of what you need to be a competent journeyman engineer. So, it focused a lot on algorithms and languages, as well as project management and working in teams.

But there’s a lot more that’s expected and needed from architects, leads, technologists and so on, so I need to start collecting books. This is particularly challenging since I only recommend books that I have read. For now, this is my reading list: books I need to evaluate to see if they do belong on my recommended reading list. In some cases, I’ve already read part of the book and am sure it will be on the list. In other cases, I’ve only read snippets from the book or had it recommended. Also, for my reading list, I assume you will read every book on the list; this is not a survey or compendium, it’s the essential knowledge you need. So I try to keep the list as short as possible, with as little overlap as possible.

Concurrency: State Models and Java Programs, Jeff Magee and Jeff Kramer, 2000. Covers basics of concurrency, but looks like a comprehensive modern text. The examples are in Java, but you should ignore that part, this is not teaching how Java supports concurrency, this is teaching principles of concurrency. I became interested in the book after seeing some online course notes based on the book at

Performance Modeling and Design of Computer Systems: Queueing Theory in Action, Mor Harchol-Balter, 2013. This is the best book to date that I’ve seen on queueing theory for computer systems. I’m working my way through it, and it’s a must for engineers who work on systems.

A Tour of C++, Bjarne Stroustroup, 2013. This is a cut-down version of his bigger The C++ Programming Language book. This will probably be my default recommendation for C++ book to junior engineers or people new to C++, because it’s short but comprehensive.

More R and ggplot2

You would think to annotate a graph by stringing on more geom calls, like so:

p <- ggplot(ve, aes(x=V1) + stat_ecdf() + geom_vline(xintercept=10)

However, this applies geom_vline for all data in the frame. Instead, get the object from gglot and use annotate()

p <- ggplot(ve, aes(x=V1) + stat_ecdf()
p + geom_vline(xintercept=10)

You can also use geom_hline for horizontal lines and geom_abline to specify slope and intercept. And since this is R, you can compute results from your data and use that to place lines or text objects.

The intention is to use annotate(), but ggplot2 originally didn’t have annotate, and geom_vline etc were modifed to handle annotations properly.

annotate(“text”) adds text annotations.

annotate(“segment”) adds line segments.

annotate(“rect”) adds shaded rectangles.

coord_cartesian(xlim=c(..), ylim=c(..)) zooms the viewport in or out to show the specified range. This is generally what you want instead of scale_y_continuous; in the latter, data outside the range is removed from consideration, which can affect presentation.

Queueing theory

There are some decent references on the Internet.

Dimitri Bertsekas has made his book Data Networks available on his web page at MIT:

Kevin Ross put up some very concise notes a class at UCSC

Research on arrival rates (Poisson is too simple)?

The explanation for inter-arrival time distribution in a Poisson process

Distribution models and how to select them from U. Narayan Bhat’s Fundamentals of Queueing Theory

“Look at all the books!”

I think there is still hope for the world. Here’s why.

Every year, millions of kids of all ages go around to houses in various neighborhoods and ask for candy or treats. They dress up in costumes, walk up to doors, ring doorbells or knock, and say “Trick or Treat!” when the door is opened. Adults of all ages smile, say “how cute” to the littlest ones, and hand out candy.

This year, I let our two youngest go out on their own, which was a milestone for them. I stayed home. I didn’t hand out candy, but I listened. And to my amazement, what I heard more often than not, when the door opened, was a variant of:

“Woah! Look at all the books! That’s awesome! This is the best house ever!”

From the front door, you can see a wall of books; my father built some mounted bookshelves for me as a Christmas present some years ago, and one is visible from the front door.

That kids were more excited about books that candy is, I think, a very good sign.

There’s hope.

PS: next year, I’m handing out books along with the candy.