4 ms·
Ask HN: How does Medium calculate how long it will take to read a post?
Medium and many other sites have a calculation for how long it might take you to read that particular post. How is that calculated and is there a library to add that to any site?
- zachlatta 13y agoI'd assume that they're taking a word count and then using a predefined number of words per minute to figure out approximately how long the article will take to read. For example, https://medium.com/fragmented-musings/295cc75cd1fd https://medium.com/fragmented-musings/295cc75cd1fd has approximately 600 words and has an approximate reading time of 3 minutes. From this we can deduce that they're assuming that around 200 words can be read in a minute. By diving 600 by 200, we arrive at 3.
- joezydeco 13y agoIf I was doing this I'd also scale by a readability score, like the Gunning Fog index: http://en.wikipedia.org/wiki/Gunning-Fog_Index http://en.wikipedia.org/wiki/Gunning-Fog_Index http://www.readability-score.com/ http://www.readability-score.com/ is an online calculator that will check your text and give you an average of a few scales like the Gunning.
- jogzden 13y agoMost likely. http://www.spreeder.com/ http://www.spreeder.com/ says: "To train to read faster, you must first find your base rate. Your base rate is the speed that you can read a passage of text with full comprehension. We've defaulted to 300 wpm, showing one word at a time, which is about the average that works best for our users. Now, read that passage using spreeder at that base rate." I wouldn't be surprised if Medium is calculating read time the same way. It's just aesthetically pleasing and somewhat useful.
- jreed91 13y agoThis is what I assumed just wondered how they decided what the average words per minute is.
- kylebragger 13y agoI'm guessing simply dividing word count by average words per minute[1] 1. http://en.wikipedia.org/wiki/Words_per_minute#Reading_and_comprehension http://en.wikipedia.org/wiki/Words_per_minute#Reading_and_co...
- danielhellier 13y agoGet your articles total word count, and divide by the average word read per minute. Here's a WP plugin that does this: http://codecanyon.net/item/minutes-to-read/full_screen_preview/6126659 http://codecanyon.net/item/minutes-to-read/full_screen_previ...