{"id":94,"date":"2017-09-22T14:22:32","date_gmt":"2017-09-22T21:22:32","guid":{"rendered":"http:\/\/www.ootp.cavebutter.net\/blog\/?p=94"},"modified":"2017-09-22T14:22:32","modified_gmt":"2017-09-22T21:22:32","slug":"run-environment-2-run-values-part-1","status":"publish","type":"post","link":"http:\/\/www.ootp.cavebutter.net\/blog\/archives\/94","title":{"rendered":"<font color='#1e73be'>Run Environment 2: Run Values Part 1<\/font>"},"content":{"rendered":"<p>I am not a statistician by any stretch of the imagination. \u00a0Nor am I a sabermetrician. \u00a0I can barely follow along with the conversation threads with the big brains on Tango&#8217;s website. \u00a0As a result, I have to take some things on faith. \u00a0Sometimes I feel good about that, sometimes not. \u00a0The things I am taking on faith for this first Run Values view are giving me heartburn. \u00a0Here&#8217;s what&#8217;s happening:<\/p>\n<p>In the previous view, we established a run environment for each league year. \u00a0That is, we determined how many runs were scored for every plate appearance and for every out. \u00a0In this next view, we are adding a run value to the runs per out for every non-out batting outcome. \u00a0For example, let&#8217;s say that in 2009 the RperOut for my league was .172. \u00a0That&#8217;s basically saying that, no matter the outcome, stepping up to the plate in 2009 was worth <em>at least<\/em> .172 runs on average. \u00a0That RperOut establishes a baseline to which successful outcomes will add value. \u00a0How much value? \u00a0Here&#8217;s where the heartburn comes in.<\/p>\n<p>The value added is a constant for each event. \u00a0Across all years and leagues. \u00a0A walk is worth 0.14 runs more than an out in every year, league, planet, park, etc. \u00a0It&#8217;s difficult to accept for real world historical MLB and it&#8217;s even harder to accept in OOTP where the baseball environment can be much different. \u00a0I have been looking, and will continue to look, for an explanation of how these constants were derived. \u00a0Haven&#8217;t found one yet and I&#8217;m anxious to move forward, so I will accept them for now. \u00a0However, when I start getting wacky results for my OOTP stats, this is the first place I am going to look.<\/p>\n<p>It&#8217;s to do with Run Expectancy, and this <a href=\"http:\/\/www.insidethebook.com\/ee\/index.php\/site\/article\/linear_weights_by_run_environment\/\">Tango post<\/a> and <a href=\"http:\/\/www.retrosheet.org\/Research\/RuaneT\/valueadd_art.htm\">this article<\/a> talk about it, but I was having some trouble parsing it, so I am leaving it for now, but with some misgivings. \u00a0So to recap, this view we are adding an expected run value to the runs per out for every non-out batting outcome. \u00a0Here&#8217;s that view:<\/p>\n<pre class=\"line-numbers\"><code class=\"language-sql\">CREATE OR REPLACE VIEW vRunValues AS\r\nSELECT l.year\r\n, l.league_id\r\n, l.rperout\r\n, l.rperout+0.14 AS runBB\r\n, l.rperout+0.14+0.025 AS runHB\r\n, l.rperout+0.14+0.155 AS run1b\r\n, l.rperout+0.14+0.155+0.3 AS run2b\r\n, l.rperout+0.14+0.155+0.3+0.27 AS run3b\r\n, 1.4 AS runHR\r\n, 0.2 AS runSB\r\n, (2*l.RperOut)+0.075 AS runCS\r\nFROM vLeagueRunsPerOut AS l;<\/code><\/pre>\n","protected":false},"excerpt":{"rendered":"<p>I am not a statistician by any stretch of the imagination. \u00a0Nor am I a sabermetrician. \u00a0I can barely follow along with the conversation threads with the big brains on Tango&#8217;s website. \u00a0As a result, I have to take some things on faith. \u00a0Sometimes I feel good about that, sometimes not. \u00a0The things I am&hellip; <a class=\"more-link\" href=\"http:\/\/www.ootp.cavebutter.net\/blog\/archives\/94\">Continue reading <span class=\"screen-reader-text\">Run Environment 2: Run Values Part 1<\/span> <span class=\"meta-nav\" aria-hidden=\"true\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_feature_clip_id":0,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":true,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2},"jetpack_post_was_ever_published":false},"categories":[23],"tags":[14,7,4,15,24],"class_list":["post-94","post","type-post","status-publish","format-standard","hentry","category-run-environment","tag-batting","tag-mysql","tag-ootp","tag-pitching","tag-view"],"aioseo_notices":[],"aioseo_head":"\n\t\t<!-- All in One SEO 5.0.1 - aioseo.com -->\n\t<meta name=\"robots\" content=\"max-image-preview:large\" \/>\n\t<meta name=\"author\" content=\"cavebutter\"\/>\n\t<link rel=\"canonical\" href=\"http:\/\/www.ootp.cavebutter.net\/blog\/archives\/94\" \/>\n\t<meta name=\"generator\" content=\"All in One SEO (AIOSEO) 5.0.1\" \/>\n\t\t<meta property=\"og:locale\" content=\"en_US\" \/>\n\t\t<meta property=\"og:site_name\" content=\"MySQL MyStruggle | Rolling my own MySQL Database with OOTP\" \/>\n\t\t<meta property=\"og:type\" content=\"article\" \/>\n\t\t<meta property=\"og:title\" content=\"Run Environment 2: Run Values Part 1 | MySQL MyStruggle\" \/>\n\t\t<meta property=\"og:url\" content=\"http:\/\/www.ootp.cavebutter.net\/blog\/archives\/94\" \/>\n\t\t<meta property=\"article:published_time\" content=\"2017-09-22T21:22:32+00:00\" \/>\n\t\t<meta property=\"article:modified_time\" content=\"2017-09-22T21:22:32+00:00\" \/>\n\t\t<meta name=\"twitter:card\" content=\"summary\" \/>\n\t\t<meta name=\"twitter:title\" content=\"Run Environment 2: Run Values Part 1 | MySQL MyStruggle\" \/>\n\t\t<script type=\"application\/ld+json\" class=\"aioseo-schema\">\n\t\t\t{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"http:\\\/\\\/www.ootp.cavebutter.net\\\/blog\\\/archives\\\/94#article\",\"name\":\"Run Environment 2: Run Values Part 1 | MySQL MyStruggle\",\"headline\":\"Run Environment 2: Run Values Part 1\",\"author\":{\"@id\":\"http:\\\/\\\/www.ootp.cavebutter.net\\\/blog\\\/archives\\\/author\\\/cavebutter#author\"},\"publisher\":{\"@id\":\"http:\\\/\\\/www.ootp.cavebutter.net\\\/blog\\\/#organization\"},\"datePublished\":\"2017-09-22T14:22:32-07:00\",\"dateModified\":\"2017-09-22T14:22:32-07:00\",\"inLanguage\":\"en-US\",\"mainEntityOfPage\":{\"@id\":\"http:\\\/\\\/www.ootp.cavebutter.net\\\/blog\\\/archives\\\/94#webpage\"},\"isPartOf\":{\"@id\":\"http:\\\/\\\/www.ootp.cavebutter.net\\\/blog\\\/archives\\\/94#webpage\"},\"articleSection\":\"Run Environment, batting, mysql, OOTP, pitching, view\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"http:\\\/\\\/www.ootp.cavebutter.net\\\/blog\\\/archives\\\/94#breadcrumblist\",\"itemListElement\":[{\"@type\":\"ListItem\",\"@id\":\"http:\\\/\\\/www.ootp.cavebutter.net\\\/blog#listItem\",\"position\":1,\"name\":\"Home\",\"item\":\"http:\\\/\\\/www.ootp.cavebutter.net\\\/blog\",\"nextItem\":{\"@type\":\"ListItem\",\"@id\":\"http:\\\/\\\/www.ootp.cavebutter.net\\\/blog\\\/archives\\\/category\\\/run-environment#listItem\",\"name\":\"Run Environment\"}},{\"@type\":\"ListItem\",\"@id\":\"http:\\\/\\\/www.ootp.cavebutter.net\\\/blog\\\/archives\\\/category\\\/run-environment#listItem\",\"position\":2,\"name\":\"Run Environment\",\"item\":\"http:\\\/\\\/www.ootp.cavebutter.net\\\/blog\\\/archives\\\/category\\\/run-environment\",\"nextItem\":{\"@type\":\"ListItem\",\"@id\":\"http:\\\/\\\/www.ootp.cavebutter.net\\\/blog\\\/archives\\\/94#listItem\",\"name\":\"Run Environment 2: Run Values Part 1\"},\"previousItem\":{\"@type\":\"ListItem\",\"@id\":\"http:\\\/\\\/www.ootp.cavebutter.net\\\/blog#listItem\",\"name\":\"Home\"}},{\"@type\":\"ListItem\",\"@id\":\"http:\\\/\\\/www.ootp.cavebutter.net\\\/blog\\\/archives\\\/94#listItem\",\"position\":3,\"name\":\"Run Environment 2: Run Values Part 1\",\"previousItem\":{\"@type\":\"ListItem\",\"@id\":\"http:\\\/\\\/www.ootp.cavebutter.net\\\/blog\\\/archives\\\/category\\\/run-environment#listItem\",\"name\":\"Run Environment\"}}]},{\"@type\":\"Organization\",\"@id\":\"http:\\\/\\\/www.ootp.cavebutter.net\\\/blog\\\/#organization\",\"name\":\"MySQL MyStruggle\",\"description\":\"Rolling my own MySQL Database with OOTP\",\"url\":\"http:\\\/\\\/www.ootp.cavebutter.net\\\/blog\\\/\"},{\"@type\":\"Person\",\"@id\":\"http:\\\/\\\/www.ootp.cavebutter.net\\\/blog\\\/archives\\\/author\\\/cavebutter#author\",\"url\":\"http:\\\/\\\/www.ootp.cavebutter.net\\\/blog\\\/archives\\\/author\\\/cavebutter\",\"name\":\"cavebutter\",\"image\":{\"@type\":\"ImageObject\",\"@id\":\"http:\\\/\\\/www.ootp.cavebutter.net\\\/blog\\\/archives\\\/94#authorImage\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/3841893aa5a48e51f3ff3699f735196959f8b88a5ed3851eda2fed141b75cadc?s=96&d=mm&r=g\",\"width\":96,\"height\":96,\"caption\":\"cavebutter\"}},{\"@type\":\"WebPage\",\"@id\":\"http:\\\/\\\/www.ootp.cavebutter.net\\\/blog\\\/archives\\\/94#webpage\",\"url\":\"http:\\\/\\\/www.ootp.cavebutter.net\\\/blog\\\/archives\\\/94\",\"name\":\"Run Environment 2: Run Values Part 1 | MySQL MyStruggle\",\"inLanguage\":\"en-US\",\"isPartOf\":{\"@id\":\"http:\\\/\\\/www.ootp.cavebutter.net\\\/blog\\\/#website\"},\"breadcrumb\":{\"@id\":\"http:\\\/\\\/www.ootp.cavebutter.net\\\/blog\\\/archives\\\/94#breadcrumblist\"},\"author\":{\"@id\":\"http:\\\/\\\/www.ootp.cavebutter.net\\\/blog\\\/archives\\\/author\\\/cavebutter#author\"},\"creator\":{\"@id\":\"http:\\\/\\\/www.ootp.cavebutter.net\\\/blog\\\/archives\\\/author\\\/cavebutter#author\"},\"datePublished\":\"2017-09-22T14:22:32-07:00\",\"dateModified\":\"2017-09-22T14:22:32-07:00\"},{\"@type\":\"WebSite\",\"@id\":\"http:\\\/\\\/www.ootp.cavebutter.net\\\/blog\\\/#website\",\"url\":\"http:\\\/\\\/www.ootp.cavebutter.net\\\/blog\\\/\",\"name\":\"MySQL MyStruggle\",\"description\":\"Rolling my own MySQL Database with OOTP\",\"inLanguage\":\"en-US\",\"publisher\":{\"@id\":\"http:\\\/\\\/www.ootp.cavebutter.net\\\/blog\\\/#organization\"}}]}\n\t\t<\/script>\n\t\t<!-- All in One SEO -->\n\n","aioseo_head_json":{"title":"Run Environment 2: Run Values Part 1 | MySQL MyStruggle","description":"","canonical_url":"http:\/\/www.ootp.cavebutter.net\/blog\/archives\/94","robots":"max-image-preview:large","keywords":"","webmasterTools":{"miscellaneous":""},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"http:\/\/www.ootp.cavebutter.net\/blog\/archives\/94#article","name":"Run Environment 2: Run Values Part 1 | MySQL MyStruggle","headline":"Run Environment 2: Run Values Part 1","author":{"@id":"http:\/\/www.ootp.cavebutter.net\/blog\/archives\/author\/cavebutter#author"},"publisher":{"@id":"http:\/\/www.ootp.cavebutter.net\/blog\/#organization"},"datePublished":"2017-09-22T14:22:32-07:00","dateModified":"2017-09-22T14:22:32-07:00","inLanguage":"en-US","mainEntityOfPage":{"@id":"http:\/\/www.ootp.cavebutter.net\/blog\/archives\/94#webpage"},"isPartOf":{"@id":"http:\/\/www.ootp.cavebutter.net\/blog\/archives\/94#webpage"},"articleSection":"Run Environment, batting, mysql, OOTP, pitching, view"},{"@type":"BreadcrumbList","@id":"http:\/\/www.ootp.cavebutter.net\/blog\/archives\/94#breadcrumblist","itemListElement":[{"@type":"ListItem","@id":"http:\/\/www.ootp.cavebutter.net\/blog#listItem","position":1,"name":"Home","item":"http:\/\/www.ootp.cavebutter.net\/blog","nextItem":{"@type":"ListItem","@id":"http:\/\/www.ootp.cavebutter.net\/blog\/archives\/category\/run-environment#listItem","name":"Run Environment"}},{"@type":"ListItem","@id":"http:\/\/www.ootp.cavebutter.net\/blog\/archives\/category\/run-environment#listItem","position":2,"name":"Run Environment","item":"http:\/\/www.ootp.cavebutter.net\/blog\/archives\/category\/run-environment","nextItem":{"@type":"ListItem","@id":"http:\/\/www.ootp.cavebutter.net\/blog\/archives\/94#listItem","name":"Run Environment 2: Run Values Part 1"},"previousItem":{"@type":"ListItem","@id":"http:\/\/www.ootp.cavebutter.net\/blog#listItem","name":"Home"}},{"@type":"ListItem","@id":"http:\/\/www.ootp.cavebutter.net\/blog\/archives\/94#listItem","position":3,"name":"Run Environment 2: Run Values Part 1","previousItem":{"@type":"ListItem","@id":"http:\/\/www.ootp.cavebutter.net\/blog\/archives\/category\/run-environment#listItem","name":"Run Environment"}}]},{"@type":"Organization","@id":"http:\/\/www.ootp.cavebutter.net\/blog\/#organization","name":"MySQL MyStruggle","description":"Rolling my own MySQL Database with OOTP","url":"http:\/\/www.ootp.cavebutter.net\/blog\/"},{"@type":"Person","@id":"http:\/\/www.ootp.cavebutter.net\/blog\/archives\/author\/cavebutter#author","url":"http:\/\/www.ootp.cavebutter.net\/blog\/archives\/author\/cavebutter","name":"cavebutter","image":{"@type":"ImageObject","@id":"http:\/\/www.ootp.cavebutter.net\/blog\/archives\/94#authorImage","url":"https:\/\/secure.gravatar.com\/avatar\/3841893aa5a48e51f3ff3699f735196959f8b88a5ed3851eda2fed141b75cadc?s=96&d=mm&r=g","width":96,"height":96,"caption":"cavebutter"}},{"@type":"WebPage","@id":"http:\/\/www.ootp.cavebutter.net\/blog\/archives\/94#webpage","url":"http:\/\/www.ootp.cavebutter.net\/blog\/archives\/94","name":"Run Environment 2: Run Values Part 1 | MySQL MyStruggle","inLanguage":"en-US","isPartOf":{"@id":"http:\/\/www.ootp.cavebutter.net\/blog\/#website"},"breadcrumb":{"@id":"http:\/\/www.ootp.cavebutter.net\/blog\/archives\/94#breadcrumblist"},"author":{"@id":"http:\/\/www.ootp.cavebutter.net\/blog\/archives\/author\/cavebutter#author"},"creator":{"@id":"http:\/\/www.ootp.cavebutter.net\/blog\/archives\/author\/cavebutter#author"},"datePublished":"2017-09-22T14:22:32-07:00","dateModified":"2017-09-22T14:22:32-07:00"},{"@type":"WebSite","@id":"http:\/\/www.ootp.cavebutter.net\/blog\/#website","url":"http:\/\/www.ootp.cavebutter.net\/blog\/","name":"MySQL MyStruggle","description":"Rolling my own MySQL Database with OOTP","inLanguage":"en-US","publisher":{"@id":"http:\/\/www.ootp.cavebutter.net\/blog\/#organization"}}]},"og:locale":"en_US","og:site_name":"MySQL MyStruggle | Rolling my own MySQL Database with OOTP","og:type":"article","og:title":"Run Environment 2: Run Values Part 1 | MySQL MyStruggle","og:url":"http:\/\/www.ootp.cavebutter.net\/blog\/archives\/94","article:published_time":"2017-09-22T21:22:32+00:00","article:modified_time":"2017-09-22T21:22:32+00:00","twitter:card":"summary","twitter:title":"Run Environment 2: Run Values Part 1 | MySQL MyStruggle"},"aioseo_meta_data":{"post_id":"94","title":null,"description":null,"keywords":null,"keyphrases":null,"primary_term":null,"canonical_url":null,"og_title":null,"og_description":null,"og_object_type":"default","og_image_type":"default","og_image_url":null,"og_image_width":null,"og_image_height":null,"og_image_custom_url":null,"og_image_custom_fields":null,"og_video":null,"og_custom_url":null,"og_article_section":null,"og_article_tags":null,"twitter_use_og":false,"twitter_card":"default","twitter_image_type":"default","twitter_image_url":null,"twitter_image_custom_url":null,"twitter_image_custom_fields":null,"twitter_title":null,"twitter_description":null,"schema":{"blockGraphs":[],"customGraphs":[],"default":{"data":{"Article":[],"Course":[],"Dataset":[],"FAQPage":[],"Movie":[],"Person":[],"Product":[],"ProductReview":[],"Car":[],"Recipe":[],"Service":[],"SoftwareApplication":[],"WebPage":[]},"graphName":"Article","isEnabled":true},"graphs":[]},"schema_type":null,"schema_type_options":null,"pillar_content":false,"robots_default":true,"robots_noindex":false,"robots_noarchive":false,"robots_nosnippet":false,"robots_nofollow":false,"robots_noimageindex":false,"robots_noodp":false,"robots_notranslate":false,"robots_max_snippet":null,"robots_max_videopreview":null,"robots_max_imagepreview":"large","priority":null,"frequency":null,"location":null,"local_seo":null,"breadcrumb_settings":null,"limit_modified_date":false,"ai":null,"created":"2021-02-03 03:39:37","updated":"2025-12-10 01:12:40","seo_analyzer_scan_date":null,"focus_keyword":null,"additional_keywords":null,"truseo_locale":null},"aioseo_breadcrumb":"<div class=\"aioseo-breadcrumbs\"><span class=\"aioseo-breadcrumb\">\n\t\t\t<a href=\"http:\/\/www.ootp.cavebutter.net\/blog\" title=\"Home\">Home<\/a>\n\t\t<\/span><span class=\"aioseo-breadcrumb-separator\">&raquo;<\/span><span class=\"aioseo-breadcrumb\">\n\t\t\t<a href=\"http:\/\/www.ootp.cavebutter.net\/blog\/archives\/category\/run-environment\" title=\"Run Environment\">Run Environment<\/a>\n\t\t<\/span><span class=\"aioseo-breadcrumb-separator\">&raquo;<\/span><span class=\"aioseo-breadcrumb\">\n\t\t\t<font color=\"#1e73be\">Run Environment 2: Run Values Part 1<\/font>\n\t\t<\/span><\/div>","aioseo_breadcrumb_json":[{"label":"Home","link":"http:\/\/www.ootp.cavebutter.net\/blog"},{"label":"Run Environment","link":"http:\/\/www.ootp.cavebutter.net\/blog\/archives\/category\/run-environment"},{"label":"<font color='#1e73be'>Run Environment 2: Run Values Part 1<\/font>","link":"http:\/\/www.ootp.cavebutter.net\/blog\/archives\/94"}],"jetpack_publicize_connections":[],"jetpack_sharing_enabled":true,"jetpack_shortlink":"https:\/\/wp.me\/p9cxb5-1w","jetpack_likes_enabled":true,"jetpack-related-posts":[],"jetpack_featured_media_url":"","_links":{"self":[{"href":"http:\/\/www.ootp.cavebutter.net\/blog\/wp-json\/wp\/v2\/posts\/94","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/www.ootp.cavebutter.net\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/www.ootp.cavebutter.net\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/www.ootp.cavebutter.net\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"http:\/\/www.ootp.cavebutter.net\/blog\/wp-json\/wp\/v2\/comments?post=94"}],"version-history":[{"count":1,"href":"http:\/\/www.ootp.cavebutter.net\/blog\/wp-json\/wp\/v2\/posts\/94\/revisions"}],"predecessor-version":[{"id":95,"href":"http:\/\/www.ootp.cavebutter.net\/blog\/wp-json\/wp\/v2\/posts\/94\/revisions\/95"}],"wp:attachment":[{"href":"http:\/\/www.ootp.cavebutter.net\/blog\/wp-json\/wp\/v2\/media?parent=94"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/www.ootp.cavebutter.net\/blog\/wp-json\/wp\/v2\/categories?post=94"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/www.ootp.cavebutter.net\/blog\/wp-json\/wp\/v2\/tags?post=94"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}