A Solid Database Situational Query

Wednesday, March 6, 2019 3:56 PM UTC

Wednesday, Mar. 6, 2019 3:56 PM UTC

New to wagering? Rather than going with your gut, we offer analysis and discussion of machine learning and deep learning, to identify winning propositions.

I have created well over 1,100 algorithms in the past year and when I work on them via the Python code I find my mind thinking of providing insight for new bettors given the new age of legalized sports gambling. These abstracts will also be helpful to the new student of sports wagering and database query design utilizing SQL, Python, MYSQL, SDQL, and other technologies. Last, in future articles, I will discuss using machine learning and deep learning, which are simply two subsets of artificial intelligence, to identify high percentage winning situations.

A good money-making query must be consistent over time with minimal loss streaks. I spent 18 years on Wall Street and learned many ways of grading a crude oil, S&P 500, bond, currency, soybean, futures trader’s performance. One of the common metrics was maximum drawdown as a percentage of capital at risk, which means what was the worst overall stretch of losses. Return on investment (ROI) is an extremely important key performance measure for any query just as it is on Wall Street. In many cases you will see examples of a sports database query producing exciting 70% and higher ROI, which is certainly hard to find in the stock market. This is not a statement to put all of your retirement investments and savings into sports wagering, but rather to consider using sports wagering as a sector to diversify risk and produce enhanced returns overall.

So, to begin, we will look at a simple query with a few specific parameters that has produced solid returns over the last five seasons. Keep in mind always, that past performance is no guarantee of future profits and should never be relied upon as such. However, making an educated well-informed decision to adopt the discipline that specific queries provide will certainly enhance the probabilities of making money in sports wagering.

The Situational Query

This query measures a team and their opponent most recent extremes and exploits the human wagering behavior that results from those recent trends.

A query and algorithm are essentially the same things, but the algorithm sounds so much more complex and "smart" than a query. An informal definition could be "a set of rules that precisely defines a sequence of operations", which would include all computer programs, including programs that do not perform numeric calculations. Generally, a program is only an algorithm if it stops eventually. Computer scientists may classify database-management systems according to the database models that they support. Relational Databases are perhaps the most common and had their origins back on the mid 19080’s. Relational databases model data as rows and columns in a series of tables and the vast majority use Microsoft’s SQL for writing and querying data. So, a query is also a set list of parameters and qualifications that return summary results. The use of Pivot tables in Excel is an example of a query.

The query we will examine in this abstract has three rules.

  1. Play ‘UNDER’ the posted total with a line between 130 and 139.5-points
  2. After going over the total by more than 12 points in two consecutive games.
  3. With the game taking place in the month of March.

The pythonic code looks something like this:

The results of this query show 65.8% against the spread (ATS) winners on a 73-38-3 record. The third number 3, located after the 38 losses are games that tied against the spread, commonly called pushes.

The following spreadsheet shows all qualifying games for the last five seasons. The column headers are expanded to show the layman wording for greater understanding. Win Percentage is based on the OVER result. So, the highlighted area shows 22 wins, 44 losses, and 1 push (tie) for 33% OVER winners. This is the same as saying 67% UNDER winners. Also, there is only one season where this query failed to produce a profit and that was 2017 with a 6-6 even record.

So, for the first installment of this topic, I will conclude here. I will be steadily building a warehouse of queries that will be a wager model for all of us to take advantage of and make some money along the way. If you are an experienced sports gambler, then consider making disciplined wagers based on these opportunities. Tracking for beginning bettors is by far the best and safest way to learn. Always bet with your head and not over it.

comment here