Category Archives: Technology

2018 Predictions

Untestable knowledgeable cannot be scientific.  To avoid the problems of retroactively placing events into your narrative of the world, predictions must be laid out before events happen. If you try to use your model of the world to create testable predictions, those predictions can be proven right or wrong, and you can actually learn something. Incorrect predictions can help update our models.

This is, of course, the basis for the scientific method, and generally increasing our understanding of the world. Making predictions is also important for making us more humble; we don’t know everything and so putting our beliefs to the test requires us to reduce our certainty until we’ve researched a subject before making baseless claims.  Confidence levels are an important part of predictions, as they force us to think in the context of value and betting: a 90% confidence level means I would take a $100 bet that required me to put up anything less that $90. Moreover, it’s not just a good idea to make predictions to help increase your knowledge; people who have opinions but refuse to predict things with accompanying confidence levels, and therefore refuse to subject their theories to scrutiny and testability, must be classified as more fraudulent and intellectually dishonest.

First let’s take a look at how I did this past year, and see if my calibration levels were correct. Incorrect predictions are crossed out.

Predictions for 2017:

World Events

  1. Trump Approval Rating end of June <50% (Reuters or Gallup): 60%
  2. Trump Approval Rating end of year <50% (Reuters or Gallup): 80%
  3. Trump Approval Rating end of year <45% (Reuters or Gallup): 60%
  4. Trump 2017 Average Approval Rating (Gallup) <50%: 70% (reference)
  5. ISIS to still exist as a fighting force in Palmyra, Mosul, or Al-Raqqah: 60%
  6. ISIS to kill < 100 Americans: 80%
  7. US will not get involved in any new major war with death toll of > 100 US soldiers: 60%
  8. No terrorist attack in the USA will kill > 100 people: 90% (reference)
  9. France will not vote to leave to the EU: 80%
  10. The UK will trigger Article 50 this year: 70% (reference)
  11. The UK will not fully leave the EU this year: 99%
  12. No country will leave the Euro (adopt another currency as their national currency): 80%
  13. S&P 500 2017 >10% growth: 60%
  14. S&P 500 will be between 2000 and 2850: 80% (80% confidence interval)
  15. Unemployment rate December 2017 < 6% : 70%
  16. WTI Crude Oil price > $60 : 70%
  17. Price of Bitcoin > $750: 60%
  18. Price of Bitcoin < $1000: 50%
  19. Price of Bitcoin < $2000: 80%
  20. There will not be another cryptocurrency with market cap above $1B: 80%
  21. There will not be another cryptocurrency with market cap above $500M: 50%
  22. Sentient General AI will not be created this year: 99%
  23. Self-driving cars will not be available this year for general purchase: 90%
  24. Self-driving cars will not be available this year to purchase / legally operate for < $100k: 99%
  25. I will not be able to buy trips on self-driving cars from Uber/Lyft in a location I am living: 80%
  26. I will not be able to buy a trip on a self-driving car from Uber/Lyft without a backup employee in the car anywhere in the US: 90%
  27. Humans will not land on moon by end of 2017: 95%
  28. SpaceX will bring humans to low earth orbit: 50%
  29. SpaceX successfully launches a reused rocket: 60%
  30. No SpaceX rockets explode without launching their payload to orbit: 60%
  31. Actual wall on Mexican border not built: 99%
  32. Some increased spending on immigration through expanding CBP, ICE, or the border fence: 80%
  33. Corporate Tax Rate will be cut to 20% or below: 50% (it was 21%)
  34. Obamacare (at least mandate, community pricing, pre-existing conditions) not reversed: 80%
  35. Budget deficit will increase: 90% (Not if you go by National Debt increase January to January)
  36. Increase in spending or action on Drug War (e.g. raiding marijuana dispensaries, increased spending on DEA, etc): 70% (hard to say: Rohrbacher Amendment, FY2018 DoJ changes)
  37. Some tariffs raised: 90% (reference)
  38. The US will not significantly change its relationship to NAFTA: 60%
  39. Federal government institutes some interference with state level legal marijuana: 60%
  40. At least one instance where the executive branch violates a citable civil liberties court case: 70% (I made this too broad as I can cite Berger v New York and the NSA violates it every day)
  41. Trump administration does not file a lawsuit against any news organization for defamation: 60%
  42. Trump not impeached (also no Trump resignation): 95%

Sports

  1. Miami Heat do not make playoffs:  95%
  2. Miami Heat get top 6 draft pick: 60%
  3. Duke basketball wins 1 game or more against UNC: 80%
  4. Duke basketball makes it to Round of 32 in NCAA Tournament: 90%
  5. Duke basketball makes Final Four: 50%
  6. Duke basketball does not win NCAA tournament: 80%
  7. Warriors or Cavs will win the NBA title: 60%
  8. Lebron James will not be highest paid NBA player during 2017-18 season: 70%

Personal

  1. Employed in current job:  90%
  2. I will have less than 300 Twitter followers: 60%
  3. I will change my registered party from Republican to Libertarian: 70%
  4. I will have authored > 14 more blog posts (not just on this blog) by June 30, 2017: 90%
  5. I will have authored > 30 more blog posts (not just on this blog) by December 31, 2017: 80%
  6. michaelelgart.com to have >3,000 page loads 2017: 70%
  7. These predictions are under-confident: 70%

I missed all the ones I marked as 50% confident, but I’ve realized that 50% predictions do not convey any information. I could have also listed the predictions as simultaneously saying that there was a 50% chance the exact opposite of the statement occurred, so actually, I got exactly half of them right, and I will always get exactly half of them right. This makes the category completely useless, and so I have decided to avoid posting any predictions of exactly 50% accuracy for next year.

In the other categories:

  • Of items I marked as 60% confident, 11 were correct out of 13.
  • Of items I marked as 70% confident, 8 were correct out of 9.
  • Of items I marked as 80% confident, 10 were correct out of 13.
  • Of items I marked as 90% confident, 6 were correct out of 8.
  • Of items I marked as 95% confident, 3 were correct out of 3.
  • Of items I marked as 99% confident, 4 were correct out of 4.

2017 Predictions

This doesn’t look that impressive or well-calibrated, although one point I will make is that one of the 90% confidence predictions I missed was a personal goal to blog more. I only missed this by one blog post, and it makes sense that I was overconfident in it. Taking that one out, my 90% predictions come in at 87.5%, which is pretty good.

I did better than I should have on my 60% confidence predictions. In retrospect, predictions about the number of Twitter followers I would have, and about Trump’s approval rating were really under-confident (affected my 70% predictions as well). I severely cut the number of tweets on my personal twitter account in favor of one with more anonymity, and Trump never really recovered from his initial approval ratings, information I had pretty readily available. Additionally, my 60% confidence that Bitcoin’s price would be above $750 seems woefully incorrect, and it’s clear in this case, that I really had no idea what Bitcoin was going to do.

Predictions for 2018:

World Events

  1. Trump Approval Rating end of year <50% (Gallup): 95%
  2. Trump Approval Rating end of year <45% (Gallup): 90%
  3. Trump Approval Rating end of year < 40% (Gallup): 80%
  4. US will not get involved in any new major war with death toll of > 100 US soldiers: 60%
  5. No single terrorist attack in the USA will kill > 100 people: 95%
  6. The UK will not fully leave the EU this year: 99%
  7. No country will leave the Euro (adopt another currency as their national currency): 80%
  8. North Korea will still be controlled by the Kim dynasty: 95%
  9. North Korea will conduct a nuclear test this year: 70%
  10. North Korea will conduct a missile test this year: 95%
  11. Yemeni civil war will still be happening: 70%
  12. S&P 500 2018 >10% growth: 60%
  13. S&P 500 will be between 2500 and 3200: 80% (80% confidence interval)
  14. Unemployment rate December 2018 < 6%: 80%
  15. Unemployment rate December 2018 < 5%: 60%
  16. WTI Crude Oil price up by 10%: 60%
  17. Price of Bitcoin > $10,000: 70%
  18. Price of Bitcoin < $30,000: 60%
  19. Price of Bitcoin < $100,000: 70%
  20. Lightning Network available (I can complete a transaction on LN): 80%
  21. Drivechain development “complete”: 70%
  22. Drivechain opcodes not soft-forked into Bitcoin: 70%
  23. No drivechains soft-forked into existence: 95%
  24. US government does not make Bitcoin ownership or exchange illegal: 90%
  25. Self-driving cars will not be available this year for general purchase: 95%
  26. Self-driving cars will not be available this year to purchase / legally operate for < $100k: 99%
  27. I will not be able to buy trips on self-driving cars from Uber/Lyft in a location I am living: 95%
  28. I will not be able to buy a trip on a self-driving car from Uber/Lyft without a backup employee in the car anywhere in the US: 90%
  29. Humans will not be in lunar orbit in 2018: 95%
  30. SpaceX Falcon Heavy rocket will attempt to launch this year (can fail on launch): 95%
  31. SpaceX will bring humans to low earth orbit: 70%
  32. No SpaceX rockets explode without launching their payload to orbit: 60%
  33. Mexican government does not pay for wall: 99%
  34. Border wall construction not complete by end of 2018: 99%
  35. Some increased spending on immigration through expanding CBP, ICE, or the border fence: 80%
  36. No full year US government budget will be passed (only several months spending): 90%
  37. US National Debt to increase by more than 2017 increase (~$500B): 70%
  38. Increase in spending or action on Drug War (e.g. raiding marijuana dispensaries, increased spending on DEA, etc): 70%
  39. Some tariffs raised: 90%
  40. The US will not significantly change its relationship to NAFTA: 70%
  41. Federal government institutes some interference with state level legal marijuana: 70%
  42. Trump administration does not file a lawsuit against any news organization for defamation: 90%
  43. Mexican government does not pay for wall 99%
  44. Trump not removed from office (also no Trump resignation): 95%
  45. Democrats do not win control of Senate: 60%
  46. Democrats win control of House: 60%

Sports

  1. Miami Heat make playoffs: 80%
  2. Miami Heat do not make it second round of playoffs: 80%
  3. Duke basketball wins 1 game or more against UNC: 90%
  4. Duke basketball makes it to Round of 32 in NCAA Tournament: 90%
  5. Duke basketball does not make Final Four: 80%
  6. Duke basketball does not win NCAA tournament: 95%
  7. Warriors or Cavs will win the NBA title: 60%
  8. Steph Curry will be highest paid NBA player during 2017-18 season: 60%

Personal

  1. Employed in current job:  90%
  2. I will vote this year in the general election: 80%
  3. I will have authored > 12 more blog posts (not just on this blog) by June 30, 2018: 90%
  4. I will have authored > 25 more blog posts (not just on this blog) by December 31, 2018: 80%
  5. I will have read 6 additional books this year: 80%
  6. These predictions are under-confident: 70%

Python Partition Calculator

I had been looking to do a little bit more hobby-coding, and I came across this simple math problem which can be solved with a cool recursive Python script.

A partition is a concept in number theory where a positive integer is written as a sum. For example, the only partition of 1 is (1). 2 has (2) and (1+1). 3 has (1+2), (1+1+1), and (3), and so on. Because it’s a sum, order is not important.

The problem of figuring out partitions is not difficult, but it is time-consuming and repetitive once you go beyond calculating all partitions for 4 or 5. Something that makes it a good candidate for automation. It also can be done with some recursion.

The first thing that needs to be done is a recursive call to calculate all the combinations of numbers that would form a partition. I’m going to return a list of lists, where each sublist is a partition. The obvious part to take care of first is the base case:

#returns a list of lists. Each sublist sums to the partition_goal 
def recursive_partition(partition_goal):
    return_list =[]
    if partition_goal==1:
        return_list.append([1])

Next, let’s take a look at when the partition_goal is some number larger than one. The first thing we’d need is to add a list consisting of just that number:

#returns a list of lists. Each sublist sums to the partition_goal 
def recursive_partition(partition_goal):
    return_list =[]
    if partition_goal==1:
        return_list.append([1])
    else:
        return_list.append([partition_goal])

Now we need to loop over all the cases where the lists are more complicated. Let’s take 3, because it’s pretty simple. Once we’ve added the single item list [3] in the step above, we need to add the integer 1 to all lists that add up to 3 – 1, the integer 2 to all lists that add up to 3 – 2 and so on.

#returns a list of lists. Each sublist sums to the partition_goal 
def recursive_partition(partition_goal):
    return_list =[]
    if partition_goal==1:
        return_list.append([1])
    else:
        return_list.append([partition_goal])
        for i in range(1,partition_goal):
            for j in recursive_partition(partition_goal - i):
                j.append(i)
                return_list.append(j)
    return return_list

So for each of the numbers in the i range, we are adding that number to every list we can create recursively (j) where that list sums to partition_goal – i. Lastly, we need to call our recursive method, and then remove all the sublists which are identical when unordered ([1,1,2] and [1,2,1] are just one partition of 4). We do this using the Counter module.

#returns a list of lists. Each sublist sums to the partition_goal 
def recursive_partition(partition_goal):
    return_list =[]
    if partition_goal==1:
        return_list.append([1])
    else:
        return_list.append([partition_goal])
        for i in range(1,partition_goal):
            for j in recursive_partition(partition_goal - i):
                j.append(i)
                return_list.append(j)
    return return_list

list_of_lists = recursive_partition(n)

counted = Counter(tuple(sorted(entry)) for entry in list_of_lists)

print(list(counted.keys()))

The variable counted actually gets a dictionary Python object, so I turned it into a list in the print statement. The keys of a Counter are tuples, so the end result is a list of tuples where every tuple is a partition. Lastly let’s make some interface changes so we can take command line arguments or ask the user for input.

from collections import Counter
import sys

n = 1
# partition goal
if len(sys.argv) > 1:
    n = sys.argv[1]
else:
    n = int(input("What number do you want the partitions for?"))

#returns a list of lists. Each sublist sums to the partition_goal 
def recursive_partition(partition_goal):
    return_list =[]
    if partition_goal==1:
        return_list.append([1])
    else:
        return_list.append([partition_goal])
        for i in range(1,partition_goal):
            for j in recursive_partition(partition_goal - i):
                j.append(i)
                return_list.append(j)
    return return_list

list_of_lists = recursive_partition(n)

counted = Counter(tuple(sorted(entry)) for entry in list_of_lists)

print(list(counted.keys()))

And remember this is Python 3 notation. You can find this little project on Github here.

2016 Predictions

How confident should we be? People tend to be overconfident.  One way to figure out if our confidence levels are correct is to test our calibration levels by making predictions and seeing how many of them pan out. Inspired by Slate Star Codex’s predictions, here are my predictions and accompanying confidence levels. For the sake of convenience I will choose from confidence levels of 50%, 60%, 70%, 80%, 90%, 95% or 99%. All predictions are by December 31, 2016 unless noted otherwise.

World Events

  1. Liberland will be recognized by <5 UN members: 99%
  2. Free State Project to reach goal of 20,000 people in 2016: 50%
  3. ISIS to still exist: 80%
  4. ISIS to kill < 100 Americans 2016: 80%
  5. US will not get involved in any new major war with death toll of > 100 US soldiers: 80%
  6. No terrorist attack in the USA will kill > 100 people: 80%
  7. Donald Trump will not be Republican Nominee: 80%
  8. Hillary Clinton to be Democratic nominee: 90%
  9. Republicans to hold Senate: 60%
  10. Republicans to hold House: 80%
  11. Republicans to win Presidential Election: 50%
  12. I will vote for the Libertarian Presidential Candidate: 70%
  13. S&P 500 level end of year < 2500: 70%
  14. Unemployment rate December 2016 < 6% : 70%
  15. WTI Crude Oil price < $50 : 80%
  16. Price of Bitcoin > $500:  60%
  17. Price of Bitcoin < $1000: 80%
  18. Sentient General AI will not be created this year: 99%
  19. Self-driving cars will not be available this year to purchase / legally operate for < $100k: 99%
  20. I will not be able to rent trips on self-driving cars from Uber/ Lyft: 90%
  21. Humans will not land on moon by end of 2016: 95%
  22. Edward Snowden will not be pardoned by end of Obama Administration: 80%

Personal

  1. Employed in current job:  90%
  2. I will have less than 300 Twitter followers: 60%
  3. I will have authored > 12 more blog posts by June 30, 2016:  50%
  4. michaelelgart.com to have >4,000 page loads 2016: 50%
  5. These predictions are underconfident: 70%

Sports

  1. Miami Heat make playoffs 2016:  80%
  2. Miami Heat will not make Eastern Conference Finals:  90%
  3. Duke basketball wins 1 game or more against UNC: 60%
  4. Duke basketball makes it to Round of 32 in NCAA Tournament: 70%
  5. Duke basketball does not make Final Four: 90%
  6. USA wins Olympic gold medal in basketball: 70%
  7. Kevin Durant will not be highest paid NBA player during 2016-17 season: 70%

New Horizons, Prediction Markets, and other Links

This morning, the New Horizons probe had its closest approach to Pluto.  It’s pretty cool that human ingenuity has gotten to the point where it’s possible to launch a rocket, and then 10 years later get it within a couple thousand miles of a (dwarf) planet orbiting ~6 billion kilometers away from us. But keeping with this blog’s theme, this doesn’t seem very libertarian! Isn’t this a big waste of money and resources for the government to be sending probes to Pluto?  Well, yes, obviously.

 - Public Domain Photo from NASA

This picture of Pluto cost $650M

Continue reading

Updated Links

I’ve updated the links to add a new section for reference websites that aren’t updated in the same way blogs are.  All of the new sites listed under “Reference” I would highly recommend, but for different reasons.

Basketball-reference.com is the best way to get basketball stats hands-down. If you are at all into sports data, this site has data on games, teams, players, and coaches for college and professional levels going back decades. It even has more advanced stats, pace-adjusted, whatever you could want for free.

Learn Liberty, Libertarianism.org, and the Library of Economics and Liberty are awesome libertarian/economic websites. Libertarianism.org (run by the Cato Institute) is the best site for introductory essays discussing libertarianism and classical liberalism, and Learn Liberty (run by IHS) is similar but with an emphasis on videos.  The Library of Economics and Liberty has tons of publications from classical liberal thinkers going back centuries.

Steve Gibson’s Sci-Fi Book Guide is a list of science fiction novels compiled by computer security expert Steve Gibson (whose Podcast is in my blog list).  It’s different from your normal sci-fi book list and I’ve enjoyed his recommendations so far. I plan on having a more in depth blog on sci-fi novels soon.

Things Every CS Major Should Know is a way too long of a list of things that I don’t know, but an excellent guide for self education for anyone interested in computers and coding.  Professor Might’s blog is awesome but is often more technical than I need, so I don’t have it in my blog list.

I’d also like to highlight one relatively new addition to my blog links: Slate Star Codex. Scott Alexander, the author of this blog, is the most impressive writer I’ve seen in a blogger.  He writes volumes, and has an emphasis on rationality and rhetoric.  He’s also libertarian leaning, but I would describe his position as rational, libertarian-leaning political skeptic. I would highly recommend his blog.

Links for Tuesday, February 11

Here are the links I’ve tweeted about recently. Check them out:
We have really dumb protections on sugar imports in the US because those 4500 sugar growers know their politics http://t.co/41yim0W0Ra
RT @emmakelly93: http://t.co/bXS7AB8c1u Why buying likes on Facebook not only costs you money but costs you likes from your target audience!
The Economist is all over this. You can be deported for pot violations 20 years ago. Makes no sense. http://t.co/JXHLQdoTdo
US Deportation and Border Patrol costs more than all other federal law enforcement combined http://t.co/ZyOQ61WEgq
Bill Nye did an excellent job critiquing creationism, but should he have stooped so low as to debate at all? http://t.co/yoJIDtWgS7
Not so much an LGBT rights issue as a public schools issue @emmakelly93 http://t.co/UFpo2ehIbf
RT @emmakelly93: http://t.co/dcgP8GIKqa 8 US states limit speech about homosexuality. Not quite as much as Russia, but still. #HomeOfTheFre…
Worst of the Month—January 2014, police shot a 90 pound, mentally-ill teen being held down by 2 officers http://t.co/Zch880YcCA via @NPMRP

Copyright needs Reform

You are reading an article whose copyright will expire in over a century.  Given the life expectancy of an American male born in 1992, I’m scheduled to exit the scene sometime around 2070-2075.  70 years after that, my copyrights will expire, meaning you will be free to incorporate this article into a movie or perhaps a 3D hologram, sometime around 2140.  Of course, that assumes copyright law won’t change in the intervening 130 years.  History seems to indicate otherwise, as 130 years ago, my copyright would have only lasted 56 years, which suggests my copyright might not expire until 2170, or maybe even 2200!

Continue reading

Links for Tuesday, January 28

Here are the links I’ve tweeted about recently. Check them out:

RT @danielfstrunk: Response to “Think twice about 40 percent” | The Chronicle http://t.co/wpCmocgxdU via @dukechronicle

RT @EFF: The Republican National Committee formally rejects NSA mass spying. https://t.co/1sUJuoTQcF Civil liberties transcend partisan loy…

If you agree with the editorial board, sign the petition! http://t.co/JeRYAZebVs The Chronicle endorses the 40% plan! http://t.co/StYun01Un6

RT @MargRev: How well does a minimum wage boost target the poor?: There has been a recent kerfluffle over the Sabia and Bur… http://t.co/…

Links for Thursday, November 21

Here are the links I’ve tweeted about recently. Check them out:
You can build bombs w/stuff purchased *after* security check. Why do we still have the TSA? http://t.co/zaznsR9ksv #securityTheater

RT @zmre: Airport silverware silliness. #securitytheater http://t.co/BI13XqB9kB
The Senate’s bitcoin hearing was actually pretty positive. Of course there’s always one…http://t.co/l7Pa4GWR8d
Police on being recorded when on duty: “the ubiquitous tracking is too invasive of their personal privacy” http://t.co/ASy2TXxnzj
Hey Windows 8 UI people. When you give me a pop-up I don’t want, and don’t let me click around it, I get angry. http://t.co/tiNoj5BJaI
Just read Kozinski’s dissent in White v Samsung. Finally, someone who makes sense in IP law. Read it: http://t.co/78wdNAnUBj
Pentagon says it has no idea where the money is that it’s supposed to spend. The numbers are staggering. http://t.co/QFOY6XiWU8
RT @declanm: Yahoo “plans to have all data encrypted by the end of March”: http://t.co/yakjH0L6qO Yahoo’s users might want to thank Edward Snowden …
RT @TracyOpp: I interviewed Terry Bressi on in-country #immigration #checkpoints and recording his 300+ interactions http://t.co/h9kMUIhikz