Org and Anki

If you took my advice and checked out Ali Abdaal’s videos on evidence-based study techniques, you know that one of the two guiding principles of effective learning is spaced repetition. An easy way to do that is to start with flashcards and use some sort of record keeping to track which questions you need to revisit. There are, of course, some tools available to automate this. One such tool is Anki. You can enter flashcards with a question on the front and an answer on the back and Anki will track your progress and help you review the questions you get wrong more often then the ones you get right.

On the other hand, who wants to deal with inputting questions and answers into some suboptimal, bespoke editor? Fortunately, you can get all the benefits of Anki and still do your editing in Emacs. Cheong Yiufung has an informative post that explains how to write your flashcards in Emacs and Org-mode and export them to Anki. The post has several videos—sadly without useful audio—that demonstrate the app in action.

The nice thing about Anki is that it’s functionally like a physical set of flashcards in that you can sync your deck across all your devices and take it with you on your phone or tablet. That’s perfect for, say, your bus or train ride: you can review your material in those short otherwise lost time spans.

The takeaways from this post are (1) you should be using spaced repetition to help you learn new material and (2) if you want to do spaced repetition with flashcards, Anki and Emacs is a good solution.

Posted in General | Tagged , | Leave a comment

Happy 47th Birthday, Dark Side of the Moon

As I do every year on this day, I want to pause for a brief moment to consider the glory of one of the best albums ever recorded: Pink Floyd’s Dark Side of the Moon. Wikipedia says that it was actually released on March 1, 1973 but I’ve been using March 10 for years—I no longer remember why—and will continue the tradition.

Last year, I embedded a video of the Brain Damage/Eclipse set that ends the album. I and most other folks consider it the jewel of the album but two other cuts, Money and Time were the single hits. Here, from Live 8 in 2005, is the entire band, reunited for the first time in 24 years, doing Money. It was the last time they ever appeared together. Enjoy one of the best rock bands in history.

Posted in General | Tagged , | Leave a comment

COVID-19

Even if you are living under a rock, you’ve no doubt heard a lot about COVID-19 and its potential to be a serious pandemic. There is, it turns out, not much you can do about the threat other than taking common sense precautions. The most important of these is to wash your hands regularly and thoroughly. Via Karl Voit, here is a very useful two-part thread that explains why washing with soap is so effective and hand sanitizers are helpful but not as good as soap:

The introduction sounds as if it might be too technical but it isn’t. It’s accessible, informative, and definitely worth reading.

If you’d like an informal summary of the situation, Ali Abdaal has a 20 and a half minute video that explains what’s going on in a more even handed way than the click bait headlines you’ve been seeing.

Posted in General | Tagged , | Leave a comment

Notion and Org Mode

Ali Abdaal, whom I’ve mentioned a couple of times before, is a physician and YouTuber from Britain. He’s a geek who at least once a week uploads a video usually about medicine, tech, or studying and learning. If you’re a student, you should definitely take a look at his videos on Evidence-Based Study Tips in which he discusses the scientifically-determined best ways of learning new material.

In a recent video he discusses the best note-taking app for students. That app is Notion, which Abdaal has increasingly been using to organize his life. As you can see from the video, Notion is, indeed, a very nice app that has many ways to organize and display your data and make it available across multiple devices. The problem with it is that it violates the important principle that you must maintain control of your data. With Notion, your data is held on the company’s servers and not stored locally. For that reason alone I don’t consider Notion a viable solution and I couldn’t recommend it to others for the same reason.

Still, Notion is an obviously useful and flexible app as you can see from Abdaal’s video. Fortunately, Emacs users can have essentially the same features that Notion offers while maintaining control of their data. Any Org Mode user watching the Abdaal’s video will immediately recognize the almost one-to-one correspondence between the ways Org and Notion operate. To be sure, Notion has a pretty GUI and may have capabilities that Abdaal hasn’t mentioned but as I’ve mentioned before, you can do the same things the video demonstrates with Org mode.

If you’re an Org mode user, take a look at the video and see if you don’t agree. The video is 24 minutes, 12 seconds so plan accordingly.

Posted in General | Tagged , | Leave a comment

Innumeracy and the Press

It’s no secret that Irreal doesn’t hold the press in very high regard. There are, of course, exceptions but too many journalists are ignorant and lazy. That seems overwrought but consider this example: Mekita Rivas, a journalist who writes for The Washington Post, among other venues, tweeted:

“Bloomberg spent \$500 million on ads. The U.S. population is 327 million. He could have given each American \$1 million and still have money left over. I feel like a \$1 million check would be life-changing for most people. Yet he wasted it all on ads and STILL LOST.”1

There was, of course, immediate blowback along with a fair bit of snark about Rivas’ math abilities. Not to be deterred, she doubled down with:

“blah blah math blah blah people are telling me my numbers are wrong but the point still stands: he could easily afford to give everyone \$1 million and literally never notice”

So far, this is just an embarrassing slip and although it does show a lack of attention to detail and an unwillingness to revisit disputed facts, it was only a tweet. Then the press proper got involved.

These aren’t some freelancers from the Tapioca Weekly News. They’re two prominent and well established national journalists. Gay, in addition to her anchor duties, is a member of the New York Times editorial board. And don’t forget the layers of fact checkers and the producer that signed off on this piece. There’s a graphic so the story was planned and not just an off-the-cuff remark. Notice the lede above the video: Williams and Gay “do the math and conclude that Journalist Mekita Rivas is right” so they’re not just repeating her figures. They did the math. Just not very well. And notice that the “math” here is a single division.

Whatever your thoughts about income inequality, it is a current subject of public discourse in the U.S. and elsewhere so it deserves a fair airing. That means, among other things, getting the facts right. It’s not that hard and we all have calculators on our smart phones in case the division is too strenuous. You just have to take the effort.

Adam Ozimek, an economist with Upwork has an apt final word:

Footnotes:

1

Rivas has locked her twitter account so I can’t show the actual tweets but this and the next are verbatim quotes.

Posted in General | Tagged , | Leave a comment

Some Simple Tramp Tricks

One of the great and mostly underappreciated features of Emacs is the Tramp system that lets you seamlessly edit files on a remote computer. There are, of course, situations where Tramp is not the right answer—working with large files on remote servers connected over a slow or buggy connection, for example—but most of the time it’s exactly what you need to deal with remote files.

If you’re a Vim user, the typical answer is to just install Vim on the remote machine and SSH into it when you need to edit a file. That works pretty well especially if you don’t have much in your Vim configuration file. With Emacs and Tramp, you don’t have to install anything on the remote and your full Emacs system with all your configurations and tweaks are available because you’re working on your local machine. When you’re finished and save the file, it’s synced back to the remote machine just as if you’d been working on it instead of your local machine.

Will Schenk has a short post of some of the typical Tramp use cases. That includes editing a file on the remote machine even if you need to edit it as root. If you connect to a directory instead of a file, you get a Dired listing and can interact with it in the usual way even though all the files it lists are remote. You can even start a shell on the remote host right from Emacs using Meta+x shell in the normal way.

One of the most useful Tramp tricks is working on a remote machine that’s behind a gateway. Tramp has a mechanism that let’s you connect to the gateway machine and then to the target machine. That’s really handy especially if you’re trying to make a quick fix to one of your work machines from home. It’s a whole lot easier than having to go into work.

Finally, Schenk discusses connecting to a Docker image and shows a bit of Elisp to make it easy. You may or may not need that capability but it’s nice to know it’s available.

If you edit files on remote machines and you’re not using Tramp, you’re working too hard. It’s easy to get started: just try it on remote files for a while and after you get comfortable, you can try some of the more complicated tricks. Schenk’s post provides a nice go-by for some of the easier tasks but be sure to check out the documentation for the full story.

Posted in General | Tagged | Leave a comment

File Hierarchies

A nice post from Karl Voit has been languishing in my blog queue since January and I realized that it was time to write about it. In the post, Voit argues that complex file hierarchies are the wrong answer. If you’ve ever used one, you know that that’s true. The problem is that you always encounter edge cases where it’s not clear where to store or search for a given file. Voit recommends a fairly flat hierarchy. That makes storage easier but what about retrieval?

One solution is searching. Almost no one does this but it’s a very useful strategy. Searching can involve looking for a particular file name, perhaps fuzzily, or a content search using a grep-like facility. That’s a powerful method but it brings its own set of problems as Voit describes.

If you follow Voit, you won’t be surprised at his preferred solution: he likes to use a tag-based system. You can read his post and follow the links in it to see exactly how his scheme works but any Emacs user can use a lightweight version of the idea with Org-mode. That’s what I use and it works well. Most of my data is spread across five Org files all of which are tagged. When I want to locate a particular piece of data, I do an Agenda TAGS search to narrow the candidates to a very few possibilities, which I can easy scan to choose the proper one. I could, and sometimes do, use a grep for this but then I have to remember key words from the item I want. With tags, I just need to remember a general concept.

As Voit says, assigning tags is not easy and takes some practice but once you get reasonably good at it, it’s an excellent way for classifying your data. Voit’s system is much richer but may be too heavy weight for some users. If you’re looking for an easier way, Org tags is a good solution or it’s a way of easing into a more complex system such as the one Voit uses.

Posted in General | Tagged , , | Leave a comment

The First Pretest for Emacs 27.1 is Ready

Nicolas Petton writes that the first pretest for Emacs 27.1, Emacs 27.0.90, is available for download and testing. If you don’t mind living a bit on the edge and would like to try out the latest and greatest, give it a try. You’ll be helping the developers by testing the new software and moving us toward the final release of Emacs 27.1.

As always, thanks to Nico, Eli, John and everyone else involved for their hard work in moving Emacs forward.

Posted in General | Tagged | Leave a comment

Raw Data and Reproducible Research

I’ve often written that reproducible research is the best way to do science. Over at Molecular Brain, it’s editor, Tsuyoshi Miyakawa, has a long and interesting editorial that argues that if you aren’t providing raw data, you aren’t doing science. In other words, reproducible research isn’t the best way of doing science, it’s the only way.

The editorial, No raw data, no science: another possible source of the reproducibility crisis, relates some startling facts. For example, in cancer research the reproducible rate, according to one study is only 20–25% and according to another it is only 11%. In cancer research. This is serious research with life altering consequences but more than 75% of the time the results can’t be verified.

It gets worse. Miyakawa’s policy is that if the results appear “too beautiful to be true” he will asks the authors for raw data before sending the paper out for review. That’s an excellent policy but what happens next is also startling. Since 2017, Miyakawa has asked for raw data 41 times. In 21 cases the papers were withdrawn without providing the data. Of the other 20 cases, only one paper was accepted. Miyakawa rejected the others for providing insufficient data.

Even if you haven’t achieved Irreal levels of cynicism, it’s hard to avoid concluding that in some of these cases fraud is involved. Miyakawa concludes the same. Journals could make significant inroads into this problem if, like Molecular Brain, they insisted that researchers provide their data. Organizations providing research grants could do their part by insisting that the raw data gathered by the research they fund be made available. What’s happening now is absurd.

Posted in General | Tagged | Leave a comment

TECO

If you’ve ever wanted to play around with the patriarch of the Emacs family, now you can. The TECO editor was developed in 1962 to work with paper tapes. In fact, TECO originally stood for “Tape Editor and Corrector” but the acronym’s meaning was changed to “Text Editor and Corrector” as it was adapted for other media. The other salient fact about TECO is that the original Emacs—the literal Editing MACroS—was implemented as TECO macros.

Every once in a while I see someone proudly announce that they still use, or at least prefer, TECO but until Mike Zamansky’s Emacs vs. Vi rant I had never seen it in action. I assumed that those still using it were one of the people who collect old computers such as the PDP-1 on which it was originally implemented. It turns out, though, that it was ported to C and is available in a GitHub repository maintained by Blake McBride.

Of course, if you think line editors such as ed are a pain, you should know that TECO is a character editor—presumably from its heritage as a paper tape editor. The README for the repository and the manual have more details on how it works. If you feel like having a retro moment, now you know where to get it.

Posted in General | Tagged | Leave a comment