<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Adarsh Verma on Medium]]></title>
        <description><![CDATA[Stories by Adarsh Verma on Medium]]></description>
        <link>https://medium.com/@Adarsh4052?source=rss-9c82163c186b------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*lclJHbcC6fhKTTuFOSHOaA.jpeg</url>
            <title>Stories by Adarsh Verma on Medium</title>
            <link>https://medium.com/@Adarsh4052?source=rss-9c82163c186b------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Fri, 27 Nov 2026 10:19:19 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@Adarsh4052/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Canada's Housing Crisis Isn't About Starting Homes. It's About Finishing Them.]]></title>
            <link>https://medium.com/deepdatascience/canadas-housing-crisis-isn-t-about-starting-homes-it-s-about-finishing-them-2ae87fc02303?source=rss-9c82163c186b------2</link>
            <guid isPermaLink="false">https://medium.com/p/2ae87fc02303</guid>
            <category><![CDATA[real-estate]]></category>
            <category><![CDATA[data-science]]></category>
            <category><![CDATA[canada]]></category>
            <category><![CDATA[housing]]></category>
            <category><![CDATA[data]]></category>
            <dc:creator><![CDATA[Adarsh Verma]]></dc:creator>
            <pubDate>Tue, 02 Jun 2026 15:02:25 GMT</pubDate>
            <atom:updated>2026-06-02T15:02:25.220Z</atom:updated>
            <content:encoded><![CDATA[<p><strong>77 years of data reveal the real bottleneck isn’t starts, it’s the backlog of units taking forever to build.</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*U7MOVh_IsfUa5nuS" /><figcaption>Photo by <a href="https://unsplash.com/@mario?utm_source=medium&amp;utm_medium=referral">Mario Verduzco</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><blockquote><strong><em>TLDR</em></strong></blockquote><ul><li>Units under construction average 40,271/month, roughly 7x higher than starts or completions.</li><li>All three metrics correlate strongly (r=0.73, 0.80), confirming a predictable but cyclical pipeline.</li><li>November 2021 saw the all-time peak of 25,014 housing starts in one month.</li></ul><h3>The hidden scale of Canada’s construction backlog</h3><p>174,929 units. That’s the single-month peak for housing under construction, hit in October 1973. But here’s what makes that number quietly horrifying: it’s not the exception. It’s the normal state of Canada’s building system.</p><p>For nearly eight decades, the Canadian housing pipeline has been dominated by one metric that almost nobody talks about: the massive inventory of units stuck mid-construction. While starts and completions average around 5,800 units per month each, units under construction sit at roughly 40,271. You read that right. Seven times bigger.</p><p>This isn’t a bug in the data. It’s the architecture of Canadian housing itself.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*awNcGKfTtULepU2EAZSzOQ.png" /><figcaption><em>Canada Housing Trends Over Time (Centres 10,000+): Starts, Under Construction &amp; Completions</em></figcaption></figure><p>The data spanning 1948 to 2025 shows that Canada’s housing system isn’t broken because we’re not starting enough homes. We’re stuck because the ones we start take forever to finish. The pipeline is clogged, not empty.</p><blockquote>Seven times more units are under construction than we start each month</blockquote><h3>Why the numbers correlate, but the timelines don’t</h3><p>You’d expect a chaotic system to produce random numbers. Instead, the data shows something stranger: housing starts, units under construction, and completions all move together. The correlation between completions and units under construction hits r=0.802. The rest hover between 0.73 and 0.80.</p><p>But here’s the catch. Strong correlation doesn’t mean fast pipeline. It means predictable slowdown.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*dWLGIkAOZMTg3xTEEih4cg.png" /><figcaption><em>Correlation Matrix: Housing Starts, Under Construction &amp; Completions (Total Units)</em></figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*KTzDqEz9r7_Gtcy0iLa9jA.png" /><figcaption><em>Strongest Correlation: Housing completions vs Housing under construction (r=0.802)</em></figcaption></figure><p>When you start more homes, you do eventually complete more. But the lag time, the duration those units spend under construction, is what’s actually gotten longer over time. The correlation is tight. The timeline is stretched.</p><p>So when policymakers point to November 2021’s record 25,014 starts as proof the system is working, they’re reading only half the equation. Yes, we’re starting. But what happened to the 2020 backlog surge units? Many are still under construction.</p><h3>The 1970s boom: when Canada built 174,929 units in one month</h3><p>The all-time peak wasn’t last year. It was October 1973, during an inflationary spiral and a housing craze that feels almost alien by today’s standards. That single month saw nearly 175,000 units under construction simultaneously across Canada’s centres with 10,000+ people.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*kn6QPFMgXyso_gEKd1L-vQ.png" /><figcaption><em>Canada Housing Under Construction — Anomalies (Z-Score &gt; 2.5)</em></figcaption></figure><p>Three months total flagged as statistical anomalies across the entire 77-year dataset, and the 1970s boom is the most extreme. Construction was chaotic then too, but in the opposite direction: lots happening at once, few guardrails, prices spiraling. The system maxed out.</p><p>Then it crashed. Hard. By the 1990s, Canada’s housing construction entered a prolonged slowdown that felt like a different country altogether. And after 2020, a new surge. The pipeline fills, empties, fills again. But the pattern is always the same: steady starts, then a long wait for completions.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*8K5zLbCDNiqn3c_uEJkRIg.png" /><figcaption><em>Canada Housing Starts (Total Units) — Outliers Highlighted</em></figcaption></figure><h3>Apartments dominate the numbers, but they hide the real story</h3><p>If you look at total value by housing type, apartments and multi-unit dwellings completely dwarf everything else. They’re the volume play. Semi-detached units, row houses, and specialized housing types barely register on the graph.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*HBZGvs2KaRM3nlqWCKAMeA.png" /><figcaption><em>Total Units by Housing Estimate Type and Unit Type</em></figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*nwS3PesIAFr2cC1Qrt4JAw.png" /><figcaption><em>Canada Housing: Total Values by Housing Estimate Type and Unit Type</em></figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*sv1poLvi45JPH5who-Qbzw.png" /><figcaption><em>Top 10 Segments by Total Value</em></figcaption></figure><p>But volume isn’t the same as accessibility. Apartments take longer to construct than single-family homes. Multi-unit buildings require more inspections, more coordination, more time sitting idle waiting for permits or materials or labor. The units under construction metric gets pulled upward by apartment complexity.</p><p>This matters because policy focused on starts per se misses why completions lag. You can fast-track a bungalow subdivision. You cannot fast-track a 20-story condo tower with the same speed.</p><blockquote>Apartments dominate starts but maximize construction delays</blockquote><h3>The 2021 peak, the 2020 backlog, and where we are now</h3><p>November 2021 marked the highest single-month housing starts on record: 25,014 units across all of Canada’s mid-to-large centres. That was real demand. New policies, low rates, immigration, pent-up need. All converging.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*qfurPGbXimdrWhUwSxBVuw.png" /><figcaption><em>Canada Housing Starts (Total Units) — Annual Trend 1948–2025</em></figcaption></figure><p>But look at what didn’t happen next. Those 25,014 starts didn’t immediately convert to 25,014 completions in 2023 or 2024. Instead, they joined the backlog. The units under construction metric surged in the post-2020 period and stayed high because starts outpaced completions. More stuff started. The queue got longer.</p><p>The three structurally significant macro-patterns the data reveals are clear. The 1970s boom. The 1990s bust. And the post-2020 backlog surge we’re living in right now. This one’s different because it’s sustained by policy intervention and demographic pressure, not a speculative bubble about to pop.</p><h3>What the distribution really tells us</h3><p>The data is wildly uneven. Standard deviation of 22,263 units against a mean of just 12,749. Nearly twice as high. Some months, construction barely happens. Other months, it explodes. Some regions surge while others stall. Some housing types get investment; others vanish.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*0x9oifXoxENNmwxVYW1fkQ.png" /><figcaption><em>Distribution of Housing Values by Estimate Type and Unit Type</em></figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*Vwf5a4DIOLlhk8s7eXVs1g.png" /><figcaption><em>Housing Statistics Summary</em></figcaption></figure><p>This variability isn’t noise. It’s structural. It reflects regional inequality, cyclical boom-bust patterns, and the uneven way capital and labor flow through Canadian housing markets. Toronto and Vancouver move at different speeds than Atlantic Canada or the Prairies. Apartment construction clusters; single-family home starts scatter.</p><p>The histogram of housing values shows the distribution is heavily right-skewed. Most months are quiet. A few months are insane. The same pattern you see in stock prices or income inequality, but for housing. Power-law territory.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*7zgE6_IeNDGkkCsC-midMw.png" /><figcaption><em>Top 10: Highest Total Values by Housing Estimate &amp; Unit Type</em></figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*B0GT36WTdAV--zHm78mPmg.png" /><figcaption><em>Bottom 10: Lowest Total Values (&gt;0) by Housing Estimate &amp; Unit Type</em></figcaption></figure><h3>The real bottleneck isn’t starting homes. It’s finishing them.</h3><p>Here’s what the 77-year record actually shows: Canada’s housing crisis isn’t primarily a problem of insufficient starts. It’s a problem of duration. Projects that take too long. Pipelines that clog. Permits that drag. Labor and materials that stall.</p><p>The November 2021 record proves we can start homes fast when demand is high and capital is cheap. The months after 2021 prove that starting and completing are not the same thing.</p><p>The solution isn’t just “build more.” It’s “finish faster.” Streamline permitting. Unblock labor. Stabilize materials costs. Because every month a unit sits under construction, it’s not serving anyone. It’s capital locked in limbo. It’s housing that exists on paper but not in neighborhoods.</p><p>The correlations in this data are tight. But the timelines are loose. That’s the real problem Canada faces.</p><p><strong>Want to dive deeper?</strong> Explore the full interactive data story on <a href="https://canada.datastam.ai/data/34100143/analysis">Datastam</a>.</p><p><a href="https://canada.datastam.ai/data/34100143/analysis">Canada Mortgage and Housing Corporation, housing starts, under construction and completions in centres 10,000 and over, Canada, provinces, selected census metropolitan areas - AI Analysis</a></p><p>Originally published on <a href="https://canada.datastam.ai/data/34100143/analysis">Datastam</a>.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=2ae87fc02303" width="1" height="1" alt=""><hr><p><a href="https://medium.com/deepdatascience/canadas-housing-crisis-isn-t-about-starting-homes-it-s-about-finishing-them-2ae87fc02303">Canada&#39;s Housing Crisis Isn&#39;t About Starting Homes. It&#39;s About Finishing Them.</a> was originally published in <a href="https://medium.com/deepdatascience">Data Stories</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Canada’s Energy Use Rose 16% While Greenhouse Gas emissions dropped 4% from 2009 to 2022.]]></title>
            <link>https://medium.com/deepdatascience/canadas-energy-use-rose-16-while-greenhouse-gas-emissions-dropped-4-from-2009-to-2022-c67ff7e81334?source=rss-9c82163c186b------2</link>
            <guid isPermaLink="false">https://medium.com/p/c67ff7e81334</guid>
            <category><![CDATA[canada]]></category>
            <category><![CDATA[data-visualization]]></category>
            <category><![CDATA[energy]]></category>
            <category><![CDATA[data-science]]></category>
            <category><![CDATA[climate-change]]></category>
            <dc:creator><![CDATA[Adarsh Verma]]></dc:creator>
            <pubDate>Sat, 23 May 2026 21:39:46 GMT</pubDate>
            <atom:updated>2026-05-23T21:40:32.114Z</atom:updated>
            <content:encoded><![CDATA[<h3>Canada’s Energy Use Rose 16% While Greenhouse Gas emissions dropped 4% from 2009 to 2022. Here’s Why.</h3><p><strong>Inside the decoupling trend reshaping Canada’s natural resource sectors</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*Z0jxJ5qLlLByUrLw" /><figcaption>Photo by <a href="https://unsplash.com/@sortino?utm_source=medium&amp;utm_medium=referral">Joshua Sortino</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><h3>The Surprise Nobody’s Talking About</h3><p>Between 2009 and 2022, Canada’s natural resource sectors burned significantly more energy. Direct Energy Use climbed from 20.7 million to 24.0 million terajoules. That’s real growth, measurable and substantial.</p><p>But greenhouse gas emissions actually declined. They dropped from 1.91 million to 1.83 million kilotonnes over the same period. The math doesn’t immediately add up, and that’s the point. You’d expect more energy to mean more emissions. Instead, Canada’s resource industries managed to use 15.9% more fuel while reducing climate pollution by 3.9%.</p><p>This isn’t a rounding error. It’s a genuine decoupling, and it reshapes how we should think about Canadian industrial emissions.</p><h3>Where This Decoupling Actually Came From</h3><p>The story isn’t that Canada went green. It’s that Canada got more efficient at burning fossil fuels. Direct Energy Use and Direct Greenhouse Gas Emissions track together at an almost perfect correlation: 0.993. They’re practically twins.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*lZDZqcVbd4kOv4tyc93WjA.png" /></figure><p>That near-perfect link tells you something crucial. Fossil fuel consumption is the primary driver of emissions across all tracked sectors. There’s no mystery energy source hiding in the data. No massive renewable pivot yet. The decoupling happened because Canadian industries extracted more value from each unit of energy burned. Better machinery. Cleaner combustion. Smarter processes.</p><blockquote>More energy, fewer emissions. The decoupling is real, but fragile.</blockquote><p>It’s progress. But it’s incremental, not transformative.</p><h3>The Numbers Hide a Brutal Imbalance</h3><p>Canada’s natural resource sectors aren’t created equal. The data spans 31 industries across 868 individual records, but the distribution is wildly lopsided. The mean value sits at 395,056, yet the median is only 56,697. When your mean is nearly seven times your median, you’ve got concentration.</p><p>A small number of high-impact sectors dominate the overall footprint. The top 15 sectors by average value account for the bulk of Canada’s natural resource environmental burden. The bottom half? They barely register on the scale.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*pt9hc_nKMhtqg6XNiFcOYQ.png" /></figure><p>This pattern matters. It means your policy levers are limited. You can’t solve Canada’s resource-sector emissions by tweaking dozens of industries. You need to move the needle on a handful of major players.</p><h3>Which Sectors Are Actually Driving This</h3><p>The concentration becomes crystal clear when you rank sectors by their average contribution. The top performers aren’t even close. Some sectors average values orders of magnitude larger than others.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*9LilynfdGhkRtE6mulYJYA.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*7-b_rDSD_FBX8CmShhIVhw.png" /></figure><p>Look at how much space the top 6 sectors occupy. Oil and gas extraction, petroleum refining, mining, chemicals, primary metals. These industries don’t just lead the chart; they dominate it. The rest operate in a different universe entirely.</p><h3>The Distribution Problem Nobody Mentions</h3><p>Here’s the uncomfortable part: the data is heavily right-skewed. Values range from a low of 1,489 to a high of 5,110,710. That’s not a spread; it’s a chasm. Standard deviation: 877,069.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*ne94mV0Wl5SII1TpadX3ug.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*NjyQc3CZOX6cFCJmcds_XA.png" /></figure><p>When a dataset is this skewed, averages become misleading. Means get pulled upward by outliers. Medians tell a truer story. But even medians hide the real issue: you can’t solve a concentrated problem with dilute solutions.</p><p>This skew tells you that emissions reduction targets need to be sector-specific, not one-size-fits-all. A 10% reduction mandate might be trivial for one sector and economically catastrophic for another.</p><h3>Time Didn’t Change the Pattern</h3><p>You might think that over 14 years, the balance would shift. Maybe smaller sectors would grow faster. Maybe the concentration would ease. It didn’t.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*cnaGYvoak8vt0Yx_IpGOrw.png" /></figure><p>The correlation between reference year (the time period) and energy use is near zero: r ≈ 0.02. For emissions, it’s even flatter: r ≈ -0.01. Year-to-year, the aggregate picture stayed remarkably stable. The same sectors that led in 2009 led in 2022. The structural imbalance persisted.</p><p>This stability could mean Canada’s resource sector structure is locked in place. Or it could mean we haven’t tried anything radical enough to shift it.</p><blockquote>The same sectors dominate. The structure hasn’t budged in 14 years.</blockquote><h3>Outliers Point to Specific Warning Signs</h3><p>Statistical analysis flagged 18 data points as outliers using context-sensitive detection across sectors and time periods. These aren’t errors. They’re signals of specific years and industries hitting extremes.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*lbvX3agP2jfnm_dcDC-QYg.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*a3ttkJYTp0lGrvaumaqiCg.png" /></figure><p>An outlier could be a spike from a temporary shutdown. A supply chain disruption. A sudden efficiency gain. Or a crisis. Without digging into each one, you can’t know. But the fact that outliers exist suggests volatility beneath the aggregate calm.</p><p>These anomalies matter for planning. If a major sector can fluctuate beyond normal bounds, your baseline assumptions might need rethinking.</p><h3>The Box Plot Reveals Hidden Spread</h3><p>Beyond outliers, the actual distribution of values within each physical flow category shows real variation.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*pPcwUHn08xt_BWG4QgW58g.png" /></figure><p>Some sectors have tight ranges; their year-to-year values move in a narrow band. Others sprawl across a much wider range. That spread translates to forecast uncertainty. A narrow box means you can predict fairly confidently. A wide box means you’re flying somewhat blind.</p><p>For policy, this matters. If you’re betting carbon targets on sectors with wide volatility, you might miss your goals through no fault of your own. The industry just swings that way.</p><h3>What This Means for Climate Action in Canada</h3><p>The decoupling story is real but limited. Canada’s resource sectors are getting more efficient at burning fossil fuels, not transitioning away from them. That’s progress. It’s not enough.</p><p>The concentration among a handful of sectors is both a threat and an opportunity. It’s a threat because you can’t hide from the problem by spreading effort thin. It’s an opportunity because targeted intervention on five sectors could move the national needle far more than generalized policy.</p><p>The 2009 to 2022 trend line suggests the current pace of decoupling is sustainable but slow. If you’re aiming for net-zero emissions by 2050, incremental improvements won’t get you there. Something more structural needs to shift, and soon.</p><p>The data doesn’t judge. It just shows you where the work actually is.</p><p><strong>Want to dive deeper?</strong> Explore the full interactive data story:</p><p><a href="https://canada.datastam.ai/data/38100140/analysis">Natural resources satellite account, environmental perspective - AI Analysis</a></p><p>Follow for more Data Stories!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=c67ff7e81334" width="1" height="1" alt=""><hr><p><a href="https://medium.com/deepdatascience/canadas-energy-use-rose-16-while-greenhouse-gas-emissions-dropped-4-from-2009-to-2022-c67ff7e81334">Canada’s Energy Use Rose 16% While Greenhouse Gas emissions dropped 4% from 2009 to 2022.</a> was originally published in <a href="https://medium.com/deepdatascience">Data Stories</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Canada’s Electricity Costs Have Soared 321% Since 1981. Here’s What It Means.]]></title>
            <link>https://medium.com/@Adarsh4052/canadas-electricity-costs-have-soared-321-since-1981-here-s-what-it-means-6e85bd23ab1b?source=rss-9c82163c186b------2</link>
            <guid isPermaLink="false">https://medium.com/p/6e85bd23ab1b</guid>
            <category><![CDATA[canada]]></category>
            <category><![CDATA[electricity]]></category>
            <category><![CDATA[data-visualization]]></category>
            <category><![CDATA[business]]></category>
            <category><![CDATA[data-science]]></category>
            <dc:creator><![CDATA[Adarsh Verma]]></dc:creator>
            <pubDate>Thu, 21 May 2026 13:30:18 GMT</pubDate>
            <atom:updated>2026-05-21T13:30:18.880Z</atom:updated>
            <content:encoded><![CDATA[<h3>A 45-year analysis of price trends reveals a steady climb that shows no signs of stopping.</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*M3AdL6sAuil3H4Gy" /><figcaption>Photo by <a href="https://unsplash.com/@matthewhenry?utm_source=medium&amp;utm_medium=referral">Matthew Henry</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><p>If you run a business in Canada that depends on steady power, you need to see this: electricity prices have risen more than 300 percent over the last four and a half decades, and the pattern is almost eerily consistent.</p><p>Statistics Canada’s Electric Power Selling Price Index tells a story of relentless upward pressure. The index climbed from 31.0 in January 1981 to 130.6 in February 2026, using 2014 as the baseline year (where the index equals 100). That 321.3 percent jump isn’t the result of sudden spikes or policy shocks. Instead, it reflects a steady, month-by-month grind that has reshaped energy economics across the country.</p><p>What makes this pattern especially striking for founders and business operators is how uniform it is. The forces driving prices up hit small consumers and large industrial users almost identically. That matters because it means you can’t hide from these costs by switching consumer classes.</p><h3>The Long View: Four Decades of Rising Electricity Costs</h3><p>The scale of this increase is hard to wrap your head around without seeing it over time. When you look at the national total index since 1981, you’re watching what amounts to a consistent escalation punctuated by very few surprises. No dramatic crashes. No wild swings. Just a steady march upward.</p><p>The most recent data, from February 2026, shows prices sitting 30.6 percent above the 2014 baseline. That matters because it tells us the pace hasn’t slowed down. Even after a decade and a change since the base year, electricity remains substantially more expensive than the reference point used to measure national price trends.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*8pXs2nk3HJYFN0IAC6gsnw.png" /></figure><p>What you’re seeing here is the cumulative weight of factors: aging infrastructure, rising maintenance costs, grid modernization, and increases in the underlying commodity costs. None of it is reversing. For business planners, this historical pattern is a useful grounding point. When you’re budgeting for the next five years, you’re almost certainly budgeting for higher electricity costs, not lower ones.</p><h3>Three Consumer Categories, One Direction</h3><p>Statistics Canada tracks the index three ways: a national total, a category for consumers using over 5,000 kW, and a category for those using under 5,000 kW. You might expect these to move differently. Larger industrial users often have negotiating power. Smaller operations face whatever the market offers.</p><p>The data reveals something unexpected: they move in lockstep. The correlation between the national total and the under 5,000 kW category reaches 0.9992. That’s about as close to perfectly correlated as real-world data gets. The over 5,000 kW category shows a similarly strong relationship. All three categories have correlations of 0.9863 or higher.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*CZ44fiWmIG-VvpD5huCUsw.png" /></figure><p>This matters for a simple reason: market forces are bigger than individual negotiating power. Utilities, regulators, and fuel costs move the needle for everyone, regardless of scale. If you’re a founder with a small operation or a mid-sized manufacturer, you’re facing fundamentally the same cost pressures as your larger competitors. The game isn’t tilted by size in the way you might hope.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*PQEO1FhfbSv81_weQihUjg.png" /></figure><h3>Regional Variation: Not All Provinces Feel the Heat Equally</h3><p>Canada isn’t uniform. Alberta, British Columbia, Ontario, and the Atlantic provinces each have different supply chains, regulatory environments, and grid infrastructure. You’d expect electricity prices to reflect those differences, and they do, but perhaps not as dramatically as you’d think.</p><p>The dataset covers 13 regions including Alberta, British Columbia, the Atlantic Region, and Manitoba. Looking at the regional breakdown shows where electricity is cheapest and where it costs the most. That’s practical information if you’re considering where to locate operations or how to price products across different provinces.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*KoiU8d2useXwylEK4ufaHA.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*1d3dyhUvbbR7YtupLS5ePw.png" /></figure><p>The regional picture is useful for understanding where cost advantages might exist. Some provinces have abundant hydroelectric or nuclear resources. Others rely more heavily on natural gas or imported power. Those structural differences persist and show up in the price indexes, but they’re not so extreme that a business can ignore electricity costs by moving to a cheaper region. Cost differences exist, but so do other operational considerations. You’d need to model both.</p><h3>The Data is Remarkably Clean: No Shocks, Just Steady Climbs</h3><p>Here’s what might surprise you: across 542 monthly observations spanning 45 years, no statistical outliers appear. Using both standard statistical methods (interquartile range and Z-scores), the data is clean. There are no sudden spikes or drops large enough to stand out as anomalous.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*YCh3PSRcW-Wp2ifTAVA96g.png" /></figure><p>That’s unusual. Most long time series have moments of volatility. Financial markets spike. Commodity prices whipsaw. Weather-driven demand causes sudden pressure. But electricity prices in Canada, at least as measured by this index, have simply climbed. Month-to-month changes are uniformly modest. No single month registered a change large enough to crack the top 5 percent of anomalies.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*eJhKxYrRUO88qWmzNouivQ.png" /></figure><p>What does this mean for planning purposes? It means you can reasonably expect electricity costs to stay on the historical trend. That’s not a guarantee against sudden policy changes or supply disruptions, but it’s a useful working assumption. The pattern is stable enough that extrapolating it forward isn’t unreasonable for a 3–5 year business plan.</p><h3>The Distribution: Where Prices Actually Land</h3><p>The under 5,000 kW category shows the highest average index value at 80.17 (based on the summary statistics). The over 5,000 kW category shows wider variation, with values ranging from 12.2 to 325.4 and a standard deviation of 31.33. That spread reflects the longer time period being measured and the fact that industrial pricing can vary more widely depending on contract terms and timing.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*mtuMl7oA3L-H-q49yebezw.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*JM9bpVMp3J5D7Wqu5atAcQ.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*r_IoEtLrLhvKdujPw9Lh1A.png" /></figure><p>The distribution skews toward higher values in recent years, which aligns with what we’ve already observed: the overall trend is upward. But the width of the distribution also tells us something about volatility. The tight clustering of recent observations suggests that prices are now operating at a new, higher equilibrium rather than bouncing around wildly.</p><h3>What This Means for Your Business</h3><p>If you’re a founder or business owner managing a product or service that relies on electricity, the data points to three practical takeaways.</p><p>First, electricity costs are going up. The 45-year trend is unambiguous. You should assume they’ll continue rising and budget accordingly. The 30.6 percent increase since 2014 isn’t a one-time adjustment; it’s part of a decades-long pattern.</p><p>Second, you can’t escape this by switching to industrial rates or hunting for cheaper regions. The near-perfect correlation across consumer categories and consistent upward pressure across provinces means that cost pressures are systemic, not localized. They’re embedded in the infrastructure and policy environment.</p><p>Third, the stability of the trend is actually useful. Because prices move predictably and don’t experience sudden shocks, your forecasting can be relatively straightforward. You’re not planning around volatility; you’re planning around a known direction.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*7dktSRbYAM-P5ddEFd8JZA.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*PWthXrxDx8hb1ARDWTT_3w.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*lOLUEh_1vAnboBnq9xS1Wg.png" /></figure><p>The broader context matters too. These aren’t arbitrary increases. They reflect real costs: maintaining and upgrading infrastructure, managing grid reliability as demand patterns shift, and adapting to the energy transition. If you’re in a business that consumes significant electricity, understanding where those costs come from helps you think about longer-term strategies, whether that’s efficiency improvements, on-site generation, or simply building electricity cost assumptions deeper into your pricing models.</p><p>Original Analysis posted on <a href="https://datastam.ai/">Datastam.ai</a></p><p>Here is the link to full analysis contains the underlying data and additional breakdowns if you want to dig into specific regions or time periods.</p><p><a href="https://canada.datastam.ai/data/18100204/analysis">Electric power selling price index, monthly - AI Analysis</a></p><p>Subscribe for more Canadian Data Insights.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=6e85bd23ab1b" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Canadian food prices have risen more than 30% since 2020.]]></title>
            <link>https://medium.com/deepdatascience/canadian-food-prices-have-risen-more-than-30-since-2020-a81ffcb9a364?source=rss-9c82163c186b------2</link>
            <guid isPermaLink="false">https://medium.com/p/a81ffcb9a364</guid>
            <category><![CDATA[data-visualization]]></category>
            <category><![CDATA[data-science]]></category>
            <category><![CDATA[food]]></category>
            <category><![CDATA[data-analysis]]></category>
            <category><![CDATA[canada]]></category>
            <dc:creator><![CDATA[Adarsh Verma]]></dc:creator>
            <pubDate>Sat, 02 May 2026 21:39:54 GMT</pubDate>
            <atom:updated>2026-05-09T12:41:35.386Z</atom:updated>
            <content:encoded><![CDATA[<h3>The data shows where the money went.</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*GVjQkMbgHfOta84j" /><figcaption>Photo by <a href="https://unsplash.com/@socialtyvr?utm_source=medium&amp;utm_medium=referral">Tara Clark</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><h4>You’ve felt it at the checkout. The cart looks the same as it did five years ago, but the total is somehow always higher than you expect. You wonder if you’re buying more, or if prices are really that different and then you quietly remind yourself that yes, they are.</h4><h4>The numbers from Statistics Canada make it official.</h4><p>Using Table 18–10–0004 — the Consumer Price Index, monthly, the picture is unambiguous: <strong>grocery prices in Canada have risen roughly one-third since January 2020</strong>, outpacing general inflation by nearly 9 percentage points over six years.</p><h3>From January 2020 to March 2026, here’s where things stand:</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*xEh8s4hkNe_wCodqW002QA.png" /></figure><p>That gap is significant in human terms. A grocery haul that cost <strong>$100 in early 2020 now runs about $131.50 </strong>while the same $100’s general purchasing power has only eroded by $22. The grocery store has been extracting a premium on top of already-elevated overall inflation.</p><h3>The Timeline: Calm, Then a Cliff</h3><p>Not all of those 31+ percentage points arrived evenly. The story is really about one brutal two-year window.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*BkrkpzsF6HkPNOS1C_G04w.png" /></figure><p>For the first two years of the pandemic, grocery inflation was almost normal inflation hovering around 2%, roughly in line with the Bank of Canada’s target. Then something broke. By November 2022, <strong>year-over-year grocery inflation had hit 11.4%</strong>; the fastest pace in over 40 years. The all-time record in this data series, for context, was 23.4% back in July 1978.</p><p>2024 brought genuine relief, with grocery inflation cooling back down to 2.2% on average. But that respite appears to have been temporary. In 2025 and into early 2026, food-from-stores inflation has re-accelerated to 3.5–4.4% above headline CPI once again, meaning <strong>the gap between grocery prices and everything else continues to widen. Not to mention its accumulative that means 11.4% hit back in Nov 2022 is part of this.</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*oTVh5rRqU6NPAkb6ITdzWw.png" /></figure><h3>Where the Pain Was Concentrated</h3><p>Not all grocery aisles suffered equally. Cumulative price changes since January 2020 by category reveal a clear hierarchy of hurt:</p><p><strong>The hardest hit:</strong></p><ul><li><strong>Meat: +37.0%</strong> — the single biggest jump across all food categories</li><li><strong>Non-alcoholic beverages: +34.6</strong>%</li><li><strong>Other food preparations: +34.5</strong>%</li><li><strong>Dairy products and eggs: +30.4</strong>%</li><li><strong>Sugar and confectionery: +30.3</strong>%</li><li><strong>Bakery and cereal products: +29.0</strong>%</li></ul><p><strong>The relative less impacted, still significant:</strong></p><ul><li><strong>Fresh vegetables: +23.4%</strong></li><li><strong>Fish, seafood and other marine products: +17.3</strong>%</li><li><strong>Fresh fruit: +15.7</strong>% — the only major category that roughly tracked headline CPI</li></ul><p>If you’ve felt like the meat counter and the centre aisles of your grocery store have been the cruelest parts of the bill, you’ve been reading the data correctly all along. Protein, packaged staples, and dairy/eggs all climbed 30–37%.</p><p>The practical implication: <strong>shoppers who shifted toward fresh fruit and vegetables over the past six years were, unknowingly, hedging against the worst of food inflation.</strong></p><h3>What This Means for Canadians</h3><p>The cumulative math is sobering. Grocery inflation has not been a gentle, linear drift. It was a concentrated shock; overwhelmingly delivered in 2022 and 2023; that permanently repriced the weekly shop for Canadian households.</p><p>There’s a psychological dynamic at play too. When grocery prices spike 11% in a single year, families notice. When they then “cool” to 4%, it feels like progress but that 4% is layered on top of an already-elevated base. Prices don’t come back down; the rate of increase simply moderates.</p><p>While headline inflation has stabilized near the Bank of Canada’s 2% target, grocery-specific inflation remains a “stubborn” outlier. Grocery-specific inflation continues to run ahead of that target, and the 9-point cumulative gap between food and overall inflation isn’t closing.</p><p><strong>The grocery bill isn’t lying to you.</strong> The data is right there.</p><p><strong>Analysis done using C</strong><a href="https://canada.datastam.ai/"><strong>anada.datastam.ai</strong></a></p><p>More articles on Data Insights on Consumer Price Index (CPI) data from Stats Canada:</p><ul><li><a href="https://canada.datastam.ai/data/18100256/analysis">Consumer Price Index (CPI) statistics, measures of core inflation and other related statistics - Bank of Canada definitions - AI Analysis</a></li><li><a href="https://canada.datastam.ai/data/18100001/analysis">Monthly average retail prices for gasoline and fuel oil, by geography - AI Analysis</a></li></ul><p><em>Data Source: Statistics Canada, Table 18–10–0004 (Consumer Price Index, monthly, not seasonally adjusted), CPI base 2002=100, Canada-wide. Data through March 2026.</em></p><p>If you found this analysis useful, follow for more data-driven breakdowns of the economic trends shaping everyday life in Canada.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=a81ffcb9a364" width="1" height="1" alt=""><hr><p><a href="https://medium.com/deepdatascience/canadian-food-prices-have-risen-more-than-30-since-2020-a81ffcb9a364">Canadian food prices have risen more than 30% since 2020.</a> was originally published in <a href="https://medium.com/deepdatascience">Data Stories</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[What 569 Tumor Data Reveal About Detecting Breast Cancer]]></title>
            <link>https://medium.com/deepdatascience/what-569-tumor-data-reveal-about-detecting-breast-cancer-240b0ea16cf6?source=rss-9c82163c186b------2</link>
            <guid isPermaLink="false">https://medium.com/p/240b0ea16cf6</guid>
            <category><![CDATA[data-science]]></category>
            <category><![CDATA[data-analysis]]></category>
            <category><![CDATA[medical]]></category>
            <category><![CDATA[breast-cancer]]></category>
            <category><![CDATA[data]]></category>
            <dc:creator><![CDATA[Adarsh Verma]]></dc:creator>
            <pubDate>Wed, 31 Dec 2025 19:37:40 GMT</pubDate>
            <atom:updated>2025-12-31T20:04:33.020Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*mgMsGbvUsPvIBE33" /><figcaption>Photo by <a href="https://unsplash.com/@nci?utm_source=medium&amp;utm_medium=referral">National Cancer Institute</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><h3>I analyzed the Breast Cancer dataset. Two measurements predicted malignancy with 94% accuracy.</h3><p>Breast cancer is the most common cancer among women worldwide. Early detection dramatically improves survival rates but what actually distinguishes a malignant tumor from a benign one?</p><p>The dataset contains measurements from 569 tumor samples (212 malignant and 357 benign). What I found was striking: among 30 different measurements, a handful of features do almost all the predictive work. And some features that sound important? Completely useless.</p><p>Full Report:</p><p><a href="https://datastam.ai/story/what-569-tumor-data-samples-reveal-about-detecting-FjzNV9MPHK">Datastam - Data Story Telling AutoMated</a></p><h3>The Two Features That Matter Most</h3><p>If you could only measure two things about a tumor, these would be your best bets:</p><p><strong>Concave Points</strong> (correlation with malignancy: r = 0.78) <br><strong>Concavity</strong> (correlation with malignancy: r = 0.70)</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*6Y66g0Z35VCQBXfVAEo58w.png" /><figcaption>M = Malignant, B = Benign</figcaption></figure><p>Both describe the same thing: how irregular the tumor’s surface is. Malignant tumors have surfaces with more indentations and irregularities. Benign tumors tend to be smoother. Comparison:</p><ul><li>Malignant tumors have approximately 3.5x higher concavity_mean than benign tumors</li><li>Malignant tumors have approximately 3.4x higher concave points_mean than benign tumors</li><li>Both features are strong predictors of malignancy and could be valuable for diagnostic models</li></ul><h3>Size Matters — A Lot</h3><p>The second major pattern: malignant tumors are significantly larger.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*zAh7QGXZk8luN1BcZ1HRjw.png" /><figcaption>M = Malignant, B = Benign</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*91NNRxJQ3aU2s12LNOQa4w.png" /></figure><p>Malignant tumors are more than twice the size of benign ones on average.</p><p>This led to a practical finding: <strong>tumors with radius ≥ 15.1 AND area ≥ 705 are malignant 94% of the time.</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*un3rGDNPMUnPSKOatmqRxA.png" /><figcaption>M = Malignant, B = Benign</figcaption></figure><p>Of 168 tumors meeting both thresholds, 158 were malignant. That’s a simple rule with high predictive power.</p><h3>The Best Single Predictor</h3><p>If I had to pick one measurement to distinguish tumor types, it would be <strong>area_worst</strong> — the largest area measurement across all cells in the sample.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*iE9LPUzkZPFT3GXUGkVBQQ.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*nmY7IVFBywdo_McheUBZbg.png" /></figure><p>Statistical separation (Cohen’s d): <strong>2.29</strong></p><p>For context, a Cohen’s d above 0.8 is considered “large.” At 2.29, we’re seeing near-complete separation between groups:</p><ul><li>Malignant average: 1,422</li><li>Benign average: 559</li></ul><p>The “worst” measurements (largest values in each sample) consistently outperform “mean” measurements for classification. This makes intuitive sense — cancer is characterized by abnormal cells, and the most abnormal cells in a sample are the most telling.</p><h3>Malignant Tumors Are More Variable</h3><p>Here’s a pattern I didn’t expect: malignant tumors show much higher variability in their measurements.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*_X77aKBnddz705KUQHOEvw.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*y-1utmz0sqo06fD2KXoAbg.png" /><figcaption>M = Malignant, B = Benign</figcaption></figure><p>Standard error comparison:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*2d5ybjSgT4aL-aKEfKwQMQ.png" /></figure><p>This means malignant tumor cells are less uniform. They vary more in size and shape — a hallmark of cancer’s chaotic growth patterns.</p><p>This variability itself becomes a diagnostic signal.</p><h3>The Feature That Might Be Useless</h3><p>Not every measurement helps. <strong>Fractal dimension</strong>, a measure of boundary complexity — provides almost zero diagnostic value.</p><p>The statistics:</p><ul><li>Malignant average: 0.0627</li><li>Benign average: 0.0629</li><li>P-value: 0.76 (not significant)</li><li>Cohen’s d: -0.027 (negligible)</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*h3bSv_z1d-MUvvLrhMiaQQ.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Kh3Ts-YyZ6gRv4tA54nrSA.png" /></figure><p>The values are virtually identical. If you built a model using fractal dimension, it would perform no better than random guessing.</p><p>This matters because fractal dimension sounds sophisticated. It appears in the dataset alongside genuinely predictive features. Without analysis, you might assume it’s useful.</p><p>It isn’t.</p><h3>Compactness: The Shape Signature</h3><p><strong>Compactness</strong> measures how circular a tumor is (calculated as perimeter² / area). Malignant tumors are 81% more compact than benign ones:</p><ul><li>Malignant: 0.145</li><li>Benign: 0.080</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*pdnNdF5J_lp0a5biaqhwAA.png" /><figcaption>M = Malignant, B = Benign</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*AJMZm9z6OhIra25adREEmg.png" /><figcaption>M = Malignant, B = Benign</figcaption></figure><p>Combined with higher concavity, this paints a picture: malignant tumors are denser and more irregular, while benign tumors are larger relative to their perimeter and smoother.</p><h3>The Texture Difference</h3><p><strong>Texture</strong> measures variation in grayscale values in the cell image — essentially, how uniform the tumor appears under imaging.</p><p>Malignant tumors show 21% higher texture values:</p><ul><li>Malignant: 21.6</li><li>Benign: 17.9</li><li>P-value: 4.06e-25 (extremely significant)</li><li>Cohen’s d: 0.95 (large effect)</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*_oF8QG7uEu1xd2O2H5tGeA.png" /><figcaption>M = Malignant, B = Benign</figcaption></figure><p>Higher texture = more internal variation = more chaotic cellular structure.</p><h3>What This Means for Diagnosis</h3><p>The data reveals a clear diagnostic profile:</p><p><strong>Malignant tumors tend to be:</strong></p><ul><li>Larger (2x area on average)</li><li>More irregular surfaces (3.5x more concavity)</li><li>More variable cell sizes (2–3x higher standard error)</li><li>More compact shape</li><li>Higher internal texture variation</li></ul><p><strong>Benign tumors tend to be:</strong></p><ul><li>Smaller</li><li>Smoother surfaces</li><li>More uniform cell sizes</li><li>Less compact</li><li>More uniform internal texture</li></ul><p>A simple two-threshold rule (radius ≥ 15.1 AND area ≥ 705) correctly identifies 94% of malignant cases.</p><h3>The Correlation Structure</h3><p>Within malignant tumors, certain features move together:</p><p><strong>Highly correlated (r &gt; 0.9):</strong></p><ul><li>Radius, perimeter, and area (all size-related)</li><li>Concavity and concave points</li></ul><p><strong>Moderately correlated (r = 0.7–0.85):</strong></p><ul><li>Size features with concavity features</li><li>Compactness with concavity</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*0R6rnHDgEwnAftWz739ANQ.png" /></figure><p>This means many features are redundant. A model using radius, concavity, and texture would capture most of the diagnostic information without needing all 30 features.</p><h3>Practical Thresholds</h3><p>Based on the analysis, here are approximate thresholds where malignancy becomes likely:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*lvnpRZTUXRDPOzhPKdTbuw.png" /></figure><p>When multiple thresholds are exceeded simultaneously, malignancy probability increases substantially.</p><h3>Limitations</h3><p>This analysis is exploratory, not diagnostic. Important caveats:</p><ol><li><strong>This is one dataset.</strong> The Wisconsin dataset is well-studied but represents a specific population and imaging methodology.</li><li><strong>Correlation isn’t causation.</strong> These features predict malignancy but don’t explain why tumors become malignant.</li><li><strong>Clinical diagnosis is complex.</strong> Real diagnosis involves pathology, patient history, imaging, and clinical judgment — not just measurements.</li><li><strong>The 94% threshold has false negatives.</strong> 6% of malignant tumors fall below the thresholds. No simple rule catches everything.</li></ol><p>This analysis shows what’s <em>possible</em> with data. Actual clinical tools require rigorous validation, regulatory approval, and integration with medical workflows.</p><h3>What I Learned</h3><p>Three insights stood out:</p><p><strong>1. A few features do most of the work.</strong> Of 30 measurements, concavity, size, and texture carry most of the predictive signal. Many features are redundant or useless (like fractal dimension).</p><p><strong>2. Variability is informative.</strong> Malignant tumors aren’t just bigger — they’re more chaotic. Cell-to-cell variation within a sample is itself a diagnostic signal.</p><p><strong>3. Simple rules can be powerful.</strong> A two-variable threshold (radius + area) achieves 94% accuracy. Complexity isn’t always necessary.</p><p>Explore Full Report:</p><p><a href="https://datastam.ai/story/what-569-tumor-data-samples-reveal-about-detecting-FjzNV9MPHK">Datastam - Data Story Telling AutoMated</a></p><p>Data Source:</p><p><a href="https://www.kaggle.com/datasets/neurocipher/breast-cancer-dataset/data?select=data.csv">Breast Cancer Dataset</a></p><p><em>Note: This is exploratory data analysis, not medical advice. Clinical diagnosis requires professional medical evaluation.</em></p><p>#DataScience #Cancer #Healthcare, #MedicalData, #DataAnalysis, #CancerResearch</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=240b0ea16cf6" width="1" height="1" alt=""><hr><p><a href="https://medium.com/deepdatascience/what-569-tumor-data-reveal-about-detecting-breast-cancer-240b0ea16cf6">What 569 Tumor Data Reveal About Detecting Breast Cancer</a> was originally published in <a href="https://medium.com/deepdatascience">Data Stories</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[What 76,822 Product Hunt Launches Reveal About Startup Success]]></title>
            <link>https://medium.com/startup-insider-edge/what-76-822-product-hunt-launches-reveal-about-startup-success-2364130a0e96?source=rss-9c82163c186b------2</link>
            <guid isPermaLink="false">https://medium.com/p/2364130a0e96</guid>
            <category><![CDATA[ai]]></category>
            <category><![CDATA[product-management]]></category>
            <category><![CDATA[data]]></category>
            <category><![CDATA[data-visualization]]></category>
            <category><![CDATA[data-science]]></category>
            <dc:creator><![CDATA[Adarsh Verma]]></dc:creator>
            <pubDate>Sat, 27 Dec 2025 17:11:08 GMT</pubDate>
            <atom:updated>2025-12-29T15:01:34.041Z</atom:updated>
            <content:encoded><![CDATA[<p><strong>An 8-Year Deep Dive into the World’s Largest Product Discovery Platform</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*5IWrlNdPZO0aAZfjbucSQw.png" /><figcaption>Top 10 products ranked by their upvote counts</figcaption></figure><p>If you’ve ever wondered what separates a viral Product Hunt launch from one that fades into obscurity, you’re not alone. I recently analyzed nearly 77,000 products launched on Product Hunt between 2014 and 2021, and the findings might just change how you think about your next launch.</p><p>Full Report: <a href="https://datastam.ai/story/what-76-822-product-hunt-launches-reveal-about-sta-HndEumXgXq">https://datastam.ai/story/what-76-822-product-hunt-launches-reveal-about-sta-HndEumXgXq</a></p><p>Data Source: <a href="https://www.kaggle.com/datasets/maneshkarun/producthunt-products-dataset-2014-2021">https://www.kaggle.com/datasets/maneshkarun/producthunt-products-dataset-2014-2021</a></p><h3>The Featured Effect: A 419% Upvote Boost</h3><p>Let’s start with the most striking discovery. Products that earn “Product of the Day” status receive dramatically more engagement than their non-featured counterparts. Featured products average 620 upvotes compared to just 119 for non-featured ones , that’s over five times more engagement.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*kPNGgrEpOLvTTMg7KggJeA.png" /></figure><p>But here’s the kicker: only about 19% of products (roughly 14,600 out of 76,800) ever achieve this coveted status. The competition is fierce, but the rewards are substantial.</p><h3>The Power of Being #1</h3><p>Among the 2,648 products that achieved the #1 ranking, the numbers tell an impressive story. These top-ranked products average 1,079 upvotes, with the highest performer : Startup Stash , reaching an astronomical 21,798 upvotes (over 20x the average). The median of 856 upvotes suggests most #1 products still get substantial recognition.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*y-hVLiCOxhNNfZq_jqX1iw.png" /></figure><p>The correlation between ranking and upvotes is clear: products with better rankings (lower numbers) consistently receive more upvotes. A -0.36 correlation coefficient might sound modest in statistical terms, but in the competitive world of Product Hunt, every position matters.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Tz_m-dduo89gPI4fkSuKMg.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*l8ZPpDgcbwjRZjrGSMZnEQ.png" /></figure><h3>The All-Stars: Top Products and Hunters</h3><p>The most successful products on the platform read like a who’s who of modern productivity tools. Startup Stash leads with nearly 22,000 upvotes, followed by remove.bg (16,888), Startup Pitch Decks (11,060), Pexels 2.0 (10,206), and Hotjar (9,422).</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ChPMYO4LEB64pTCsRSD9pQ.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*flhP9TsxeFGxpKPTpvX8yg.png" /></figure><p>On the hunter side, Chris Messina stands out with over 774,000 total upvotes across 2,582 discovered products. Kevin follows with nearly 745,000 upvotes from 2,370 products. These prolific hunters have become tastemakers in the tech community.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ND-MrOPSP-clk7pKp-Uwfw.png" /></figure><h3>A Surprising Finding: 43.5% of Founders Hunt Their Own Products</h3><p>One of the most revealing statistics: nearly half of all products on Product Hunt are “self-hunted,” meaning the person who submitted the product is also one of its creators. This challenges the notion that you need an influential external hunter to succeed.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*1tKNK4dutNku1yTSLfNENQ.png" /></figure><h3>Description Matters More Than You Think</h3><p>Products with descriptions significantly outperform those without. The numbers show products with descriptions average 241 upvotes compared to 179 for those without, a 35% difference. It seems obvious, but the data confirms that investing time in crafting a compelling product story pays dividends.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*5wrcDjST3X2EfWEoS4TZiQ.png" /></figure><h3>The Market Landscape: Where Competition Lives</h3><p>If you’re planning a launch, know your competitive landscape. TECH is by far the most saturated category with nearly 44,000 products, followed by PRODUCTIVITY (17,400+), IPHONE (13,100+), and WEB APP (11,800+). Emerging categories like ARTIFICIAL INTELLIGENCE (3,795 products) show growing but still manageable competition.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*29e4zqrZIyLWvcaF8w4-Rw.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*GCPnNumK1kvyEqffT26kHQ.png" /></figure><h3>Understanding Success Benchmarks</h3><p>So what constitutes a “successful” Product Hunt launch? The data provides clear benchmarks. The median product receives 104 upvotes and if you hit this, you’re performing better than half of all launches. To reach the top 25%, you’ll need 246+ upvotes. Breaking into the top 10% requires 498+ upvotes.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*KiN0E7YVQ2i7I9qmF4xgng.png" /></figure><h3>The Eight-Year Trend</h3><p>Product Hunt has grown substantially since 2014. Launches started at 7,529 in 2014, peaked at over 11,300 in both 2015 and 2016, dipped slightly in the following years, and then surged to 12,137 in 2021, the highest year on record. The platform’s relevance clearly hasn’t diminished.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Pj642YN4yPMkHhOVdgvhLA.png" /></figure><h3>Key Takeaways for One’s Next Launch</h3><p>Based on this analysis, here’s what matters most for a successful Product Hunt launch:</p><p><strong>Invest in your product description.</strong> The 35% upvote difference between products with and without descriptions is too significant to ignore.</p><p><strong>Aim for the featured spot.</strong> With a 419% upvote boost, earning “Product of the Day” should be a primary goal. Time your launch strategically and engage your community.</p><p><strong>Don’t be afraid to hunt your own product.</strong> With 43.5% of products being self-hunted, the stigma around this practice seems overblown.</p><p><strong>Set realistic expectations.</strong> If you’re hitting 100+ upvotes, you’re already performing above average. 250+ puts you in the top quarter.</p><p><strong>Choose your category wisely.</strong> While TECH and PRODUCTIVITY are crowded, they’re also where the highest upvote counts live. Consider whether you’d rather stand out in a smaller pond or compete for bigger prizes in busier waters.</p><p>Full Report: <a href="https://datastam.ai/story/what-76-822-product-hunt-launches-reveal-about-sta-HndEumXgXq">https://datastam.ai/story/what-76-822-product-hunt-launches-reveal-about-sta-HndEumXgXq</a></p><p><em>This analysis was conducted using Datastam, an AI-powered data storytelling platform that automates the process of extracting insights from complex datasets.</em></p><p>#datascience #dataanalysis #aianalysis #ai #product</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=2364130a0e96" width="1" height="1" alt=""><hr><p><a href="https://medium.com/startup-insider-edge/what-76-822-product-hunt-launches-reveal-about-startup-success-2364130a0e96">What 76,822 Product Hunt Launches Reveal About Startup Success</a> was originally published in <a href="https://medium.com/startup-insider-edge">StartupInsider</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[I Analyzed Child Health Data for 230 Countries, Here’s What Surprised Me]]></title>
            <link>https://medium.com/deepdatascience/i-analyzed-child-health-data-for-230-countries-heres-what-surprised-me-b037cc31b4d8?source=rss-9c82163c186b------2</link>
            <guid isPermaLink="false">https://medium.com/p/b037cc31b4d8</guid>
            <category><![CDATA[data-visualization]]></category>
            <category><![CDATA[ai-analysis]]></category>
            <category><![CDATA[data-science]]></category>
            <category><![CDATA[data-analysis]]></category>
            <category><![CDATA[nasa]]></category>
            <dc:creator><![CDATA[Adarsh Verma]]></dc:creator>
            <pubDate>Wed, 10 Dec 2025 22:03:42 GMT</pubDate>
            <atom:updated>2025-12-14T22:01:08.051Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*a5pU3BGMBtDZAsAA" /><figcaption>Photo by <a href="https://unsplash.com/@planeteelevene?utm_source=medium&amp;utm_medium=referral">Muhammad-Taha Ibrahim</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><h3>I analyzed Nasa’s child mortality, water access, and sanitation data for 230+ countries. The findings are both heartbreaking and hopeful.</h3><p>The dataset covers 230+ countries from 2010 to 2022, tracking child mortality rates, water access, and sanitation infrastructure. I expected to find inequality. I didn’t expect what the data actually revealed.</p><p>Full Report: <a href="https://datastam.ai/story/the-child-health-revolution-nobody-s-talking-about-2HOiQ0yBZm">https://datastam.ai/story/the-child-health-revolution-nobody-s-talking-about-2HOiQ0yBZm</a><br>Data Source: <a href="https://www.earthdata.nasa.gov/data/catalog/sedac-ciesin-sedac-nrmi-nrpchi23-2023.00">https://www.earthdata.nasa.gov/data/catalog/sedac-ciesin-sedac-nrmi-nrpchi23-2023.00</a></p><h3>The Good News: 56% of Countries Are Making Progress</h3><p>Let’s start with hope.</p><p><strong>131 out of 232 countries improved simultaneously across all three metrics:</strong> water access, sanitation, and child survival rates (between 2010 and 2022).</p><p>That’s more than half the world moving in the right direction on multiple fronts at once.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*W5rHCVGCmtRlnG7kiSVtvw.png" /><figcaption>Top 20 countries ranked by their combined improvement across all three metrics</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*HSieEmrsRN6IQbM8LorAYw.png" /><figcaption>Top 5 biggest improvers</figcaption></figure><p>These aren’t wealthy nations with endless resources. They’re some of the world’s poorest countries, and they’re making measurable progress.</p><h3>Haiti’s Remarkable Turnaround</h3><p>The most striking finding: <strong>Haiti reduced child mortality by 76% in 12 years.</strong></p><p>In 2010, Haiti’s child mortality rate was 58.23 per 1,000 births. By 2022, it had fallen to 13.85.</p><p>Context matters here. The <strong>2010 earthquake </strong>devastated Haiti’s healthcare infrastructure, likely inflating that baseline number. But even accounting for that, the sustained improvement is remarkable for a country facing ongoing political instability and natural disasters.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*k7p8_Pd8nf0CvydZ0CGr1A.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*jSCGeHTe9k3BTkQnwDzlOA.png" /></figure><p>Sierra Leone tells a similar story , cutting child mortality from 60.32 to 28.68 despite the 2014–2015 Ebola outbreak.</p><p><strong>The lesson:</strong> Progress is possible even in the most challenging circumstances.</p><h3>The Sanitation Revolution You Haven’t Heard About</h3><p>Three countries transformed their sanitation infrastructure in just 12 years.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*KF7GHeGGptgC8mbjp45Csg.png" /></figure><p><strong>India’s Swachh Bharat Mission</strong> (Clean India Mission), launched in 2014, built over 100 million toilets. The data confirms it worked, sanitation access nearly doubled.</p><p>Cambodia and Nepal achieved similar gains through sustained NGO partnerships and government investment.</p><p>These aren’t incremental improvements. They’re transformational.</p><h3>Now the Hard Truth: 43 Countries in Crisis</h3><p>The data identified <strong>43 countries where children face a deadly combination</strong>: high mortality rates AND limited access to clean water.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*qbIA5eQQwKwoo5UxbWT_0g.png" /></figure><p>The threshold: child mortality above 8.52 per 1,000 (75th percentile) AND water access below 84% (25th percentile).</p><p>The most vulnerable:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*u_yhQt-EmReoST4m1fZXLw.png" /></figure><p><strong>Niger: </strong>A child mortality rate of 59.17 means roughly 1 in 17 children don’t survive. Combined with less than half the population having water access, it represents the most acute child health crisis on the planet.</p><p>These 43 countries aren’t randomly distributed. They cluster in Sub-Saharan Africa and conflict zones . The places where instability compounds infrastructure challenges.</p><h3>The Water-Sanitation Gap Nobody Talks About</h3><p>Here’s a pattern I didn’t expect: <strong>many countries provide clean water but can’t handle wastewater.</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*_LLTxQOrk4cPqEUfX5xvyA.png" /></figure><p>The largest gaps between water access and sanitation:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*0_KDb9x7zfVMJhMf60-vqw.png" /></figure><p><strong>Ghana</strong> can get clean water to 88% of its population, but only 29% have proper sanitation.</p><p>Why the gap? Wells and water distribution are relatively straightforward infrastructure projects. Sewage systems require complex networks, treatment plants, and ongoing maintenance.</p><p>This creates a dangerous cycle. Without proper sanitation, water sources become contaminated. The investment in water access gets undermined by the lack of sanitation infrastructure.</p><h3>The Health-Infrastructure Connection</h3><p>The data reveals a near-perfect relationship between water, sanitation, and child health outcomes.</p><p><strong>Water and sanitation access correlate at 0.89</strong> — countries investing in one almost always invest in both.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*71H8pbMCxO-6Orfe9QIv3Q.png" /></figure><p>More importantly: <strong>child mortality drops predictably as water and sanitation improve.</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*vSyrc_H9GwLGxYyfSdBZCw.png" /></figure><p>Countries with &gt;90% sanitation access have average child mortality under 2 per 1,000. Countries with &lt;50% sanitation access? Average mortality above 25 per 1,000. That’s not correlation — it’s causation. Clean water and proper sanitation directly prevent the waterborne diseases that kill children.</p><p>The pattern is obvious: wealth, stability, and strong healthcare systems.</p><h3>The Top Performers (And What They Share)</h3><p>The 10 countries with the highest child health indicator scores:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*H2RQKIxjKnh78oselHUvSQ.png" /></figure><p>The pattern is obvious: wealth, stability, and strong healthcare systems.</p><p>But here’s what’s interesting — <strong>only 10 countries showed declining child health scores</strong> from 2010 to 2022, and the declines were tiny (less than 1.1 points).</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Vq5VkMVi1V-AboxmpiaFLQ.png" /></figure><p>Even wealthy countries that might have “peaked” continued making marginal improvements. The Marshall Islands (-1.10), Poland (-1.03), and Georgia (-0.34) were the only notable exceptions.</p><h3>18 Countries Beating the Odds</h3><p>The analysis found something unexpected: <strong>18 countries achieved excellent child health outcomes despite below-average water or sanitation access.</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*KQTHcfOwP30zb3f5fbb6HA.png" /></figure><p>These “resilient” countries include Cuba, Iran, Ecuador, and several Eastern European nations.</p><p>How? Strong primary healthcare systems, vaccination programs, and nutrition initiatives can partially compensate for infrastructure gaps.</p><p>Cuba scores 95.13 on child health with only 92% sanitation access — outperforming countries with better infrastructure. Their community-based healthcare model, focused on prevention and early intervention, makes the difference.</p><p><strong>The takeaway:</strong> Infrastructure matters, but it’s not the only lever.</p><h3>What This Data Tells Us</h3><p><strong>1. Progress is real and measurable.</strong> 56% of countries improved across water, sanitation, AND child survival simultaneously. The global trend is positive.</p><p><strong>2. The gap is still deadly.</strong> 43 countries remain in crisis. A child born in Niger is 500x more likely to die before age 5 than one born in Andorra.</p><p><strong>3. Sanitation is the bottleneck.</strong> Many countries solved water access but lag dramatically on sanitation. This undermines other health investments.</p><p><strong>4. Infrastructure isn’t everything.</strong> Healthcare systems, nutrition programs, and community health workers can achieve strong outcomes even with infrastructure challenges.</p><p><strong>5. Investment works.</strong> Cambodia, India, and Nepal prove that sustained focus on sanitation can transform outcomes in a single decade.</p><p>Explore the Data Yourself<strong>:</strong> <a href="https://datastam.ai/">https://datastam.ai</a></p><p>Full Report: <a href="https://datastam.ai/story/the-child-health-revolution-nobody-s-talking-about-2HOiQ0yBZm">https://datastam.ai/story/the-child-health-revolution-nobody-s-talking-about-2HOiQ0yBZm</a></p><p><em>If you found this analysis valuable, follow for more data-driven insights on global development, health, and making sense of complex datasets.</em></p><p>#datascience #dataanalysis #aianalysis #ai #nasa</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=b037cc31b4d8" width="1" height="1" alt=""><hr><p><a href="https://medium.com/deepdatascience/i-analyzed-child-health-data-for-230-countries-heres-what-surprised-me-b037cc31b4d8">I Analyzed Child Health Data for 230 Countries, Here’s What Surprised Me</a> was originally published in <a href="https://medium.com/deepdatascience">Data Stories</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[I Analyzed 180 Countries’ Environmental Performance, Here’s What the Data Reveals]]></title>
            <link>https://medium.com/deepdatascience/i-analyzed-180-countries-environmental-performance-here-s-what-the-data-reveals-a16accc17e38?source=rss-9c82163c186b------2</link>
            <guid isPermaLink="false">https://medium.com/p/a16accc17e38</guid>
            <category><![CDATA[nasa]]></category>
            <category><![CDATA[environment]]></category>
            <category><![CDATA[data-analysis]]></category>
            <category><![CDATA[environmental-issues]]></category>
            <category><![CDATA[data-science]]></category>
            <dc:creator><![CDATA[Adarsh Verma]]></dc:creator>
            <pubDate>Sun, 30 Nov 2025 20:55:15 GMT</pubDate>
            <atom:updated>2025-12-10T22:02:28.562Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*tX-Z8vT1KhNAxjVAaMziXQ.png" /></figure><p>Last week, I ran NASA’s 2022 Environmental Performance Index. The dataset ranks 180 countries across 40 environmental indicators. What I found surprised me.</p><p>Full Report: <a href="https://datastam.ai/story/nasa-s-2022-environmental-performance-index-epi-da-MxgTdVRWiF">https://datastam.ai/story/nasa-s-2022-environmental-performance-index-epi-da-MxgTdVRWiF</a><br>Source: <a href="https://www.earthdata.nasa.gov/data/catalog/sedac-ciesin-sedac-epi-2022-2022.00">https://www.earthdata.nasa.gov/data/catalog/sedac-ciesin-sedac-epi-2022-2022.00</a></p><h3><strong>Europe Dominates, But Not Where You’d Expect</strong></h3><p>The top 5 greenest countries are all European:</p><ol><li><strong>Denmark</strong> — 77.9</li><li><strong>United Kingdom</strong> — 77.7</li><li><strong>Finland</strong> — 76.5</li><li><strong>Malta</strong> — 75.2</li><li><strong>Sweden</strong> — 72.7</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*3eBGdlTsj-1RRLWtlWAwzQ.png" /></figure><p>No surprise there. But here’s what caught my attention:</p><p><strong>Malta jumped 25.4 points</strong> : the biggest improvement globally. A tiny island nation, often overlooked, is now outperforming Germany, France, and Canada.</p><p>The UK climbed 23 points. Finland, 21 points.</p><p>Meanwhile, countries we associate with “green” policies?</p><ul><li><strong>Germany</strong> ranks 13th in recycling (49.8 score)</li><li><strong>Canada</strong> doesn’t crack the top 10 in air quality</li><li><strong>USA</strong> isn’t in the top 15 for climate action</li></ul><h3>The Real Story: Who’s Improving vs. Who’s Declining</h3><p><strong>58 countries got worse.</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*a7nOfVg7iM4Bs9OFjKiicQ.png" /></figure><p>The biggest declines:</p><ul><li>Burundi: -13.0 points</li><li>Nepal: -10.3 points</li><li>Vanuatu: -9.2 points</li><li>Philippines: -7.5 points</li></ul><p>These aren’t wealthy nations with resources to spare. They’re countries already struggling , and falling further behind.</p><p><strong>The gap is widening.</strong></p><p>Global West average: <strong>63.3</strong> Sub-Saharan Africa average: <strong>37.1</strong> Southern Asia average: <strong>31.6</strong></p><p>That’s a 30+ point gap between the richest and poorest regions.</p><h3>Findings That Changed My Perspective</h3><h3>1. South Korea Leads the World in Recycling</h3><p>Not Germany. Not Sweden. <strong>South Korea </strong>with a 67.1 recycling score, nearly 20 points ahead of second place.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Sx6ijkqRvGCe9CIO_gMk-w.png" /></figure><h3>2. Health and Environment Are Linked</h3><p>Countries with better health scores have better ecosystem vitality (correlation: 0.51). This isn’t coincidence, it’s a feedback loop.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*9SKZU356NV8LYOykywTGcw.png" /></figure><p>Clean air → healthier people → more resources for environmental protection → cleaner air.</p><h3>3. The Water Infrastructure Gap Is Alarming</h3><p>UAE has a 90.5 score for drinking water access but only 51.7 for wastewater treatment. That’s a <strong>38.8 point gap</strong>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*NWg1ej2p-ZVP_nQ4GOnGAQ.png" /></figure><p>Thailand, Lebanon, Oman have same pattern. Countries can provide clean water but can’t process what comes out.</p><h3>The Bottom 10 (And What They Share)</h3><p>The lowest-performing countries: India, Myanmar, Vietnam, Bangladesh, Pakistan, Papua New Guinea, Liberia, Haiti, Turkey, Sudan.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*92Mfn136wM-Yo3cuDE2dsw.png" /></figure><p>They score below global averages in <strong>every single category</strong>:</p><ul><li>Health</li><li>Air quality</li><li>Water</li><li>Ecosystem</li><li>Biodiversity</li><li>Climate action</li><li>Agriculture</li></ul><p>These aren’t countries failing at one thing. They’re facing compounding crises across every environmental dimension simultaneously.</p><h3>What This Means</h3><p>Environmental performance isn’t just about policy. It’s about:</p><ul><li><strong>Wealth</strong> (Global West leads every category)</li><li><strong>Geography</strong> (Island nations face unique challenges)</li><li><strong>Compounding effects</strong> (Poor countries get poorer environmental outcomes)</li></ul><p>The countries that need the most help are getting the least attention.</p><p><strong>See the full interactive analysis:</strong> <a href="https://datastam.ai/story/nasa-s-2022-environmental-performance-index-epi-da-MxgTdVRWiF">https://datastam.ai/story/nasa-s-2022-environmental-performance-index-epi-da-MxgTdVRWiF</a></p><p><em>What surprised you most about these findings? Drop a comment below.</em></p><p>#DataAnalysis #Environment #Sustainability #ClimateChange #DataScience</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=a16accc17e38" width="1" height="1" alt=""><hr><p><a href="https://medium.com/deepdatascience/i-analyzed-180-countries-environmental-performance-here-s-what-the-data-reveals-a16accc17e38">I Analyzed 180 Countries’ Environmental Performance, Here’s What the Data Reveals</a> was originally published in <a href="https://medium.com/deepdatascience">Data Stories</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[How to Make A Complete Machine Learning Project?]]></title>
            <link>https://medium.com/deepdatascience/how-to-make-a-complete-machine-learning-project-64c8623fd734?source=rss-9c82163c186b------2</link>
            <guid isPermaLink="false">https://medium.com/p/64c8623fd734</guid>
            <category><![CDATA[data-science]]></category>
            <category><![CDATA[projects]]></category>
            <category><![CDATA[data-preprocessing]]></category>
            <category><![CDATA[text-preprocessing]]></category>
            <category><![CDATA[machine-learning]]></category>
            <dc:creator><![CDATA[Adarsh Verma]]></dc:creator>
            <pubDate>Thu, 05 Mar 2020 21:08:50 GMT</pubDate>
            <atom:updated>2020-03-05T21:08:50.898Z</atom:updated>
            <content:encoded><![CDATA[<h4>A Machine Learning Project A-Z!</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*3HJUvnR2xaDUfCyN" /><figcaption>Photo by <a href="https://unsplash.com/@stanleydai?utm_source=medium&amp;utm_medium=referral">Stanley Dai</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><p>Machine learning is a trending field and it has the ability to solve many business problems effectively. A machine learning project starts with a question, or with the idea of seeking something. We find a data set (or multiple data sets and integrate) accordingly, perform exploratory data analysis and then machine learning algorithms to seek answers or perform some kind of prediction. We can also build meaningful inferences based real-world applications.</p><p>Note: This is a long article, please skip to the section which is more relevant to you.</p><p><strong>Code:</strong> Download from Github <a href="https://github.com/Adarsh4052/Employee-Status-Classification-Based-On-Company-Reviews-Dataset-Using-Machine-Learning">Click here</a></p><p><strong>Dataset:</strong> Downloaded from Kaggle. <a href="https://www.kaggle.com/petersunga/google-amazon-facebook-employee-reviews/home">Click here</a></p><p><strong>[Question/Problem Statement]</strong> In this project, we are focusing on the opinions of the employees about the companies they have worked for or still working; seeking how opinions differ when the employees are working for the company and when they have left the company. Furthermore, these opinions can be used to categorize the employment status of the employees such as a current employee (label-0) or former employee (label-1). I have used Machine learning algorithms to find out if the employees are former or current employees of a company depending on the feedback they gave. Please check the <a href="https://github.com/Adarsh4052/Employee-Status-Classification-Based-On-Company-Reviews-Dataset-Using-Machine-Learning">code</a> to follow along.</p><p><strong>Project Name:</strong> <em>Employee’s status (Former or Current ) classification based on company reviews given by employees</em></p><p>The project is divided into 4 main parts:</p><ul><li>Data Pre-processing &amp; Exploratory Analysis</li><li>Experiment 1: <em>Predictive Modeling with Numeric Data only</em></li><li>Experiment 2: <em>Predictive Modeling with Text Data only</em></li><li>Experiment 3: <em>Predictive Modeling with Numeric &amp; Text Data</em></li></ul><p>This project is developed from scratch while focusing on every step of a machine learning project. It consists of the following steps:</p><p><strong>A. Data Pre-processing</strong></p><ul><li><em>Class Imbalance</em></li><li><em>Feature Separation</em></li><li><em>Data Cleaning</em></li><li><em>Treatment of missing values</em></li><li><em>Feature Engineering</em></li><li><em>Text Pre-processing with NLP</em></li><li><em>Conversion of Categorical features into Numerical features</em></li><li><em>Data Standardization</em></li></ul><p><strong>B. Model Training &amp; Selection Using K-fold Cross-Validation</strong></p><ul><li><em>K-fold cross validation</em></li><li><em>Train-test split</em></li><li><em>Model selection</em></li></ul><p>Models used — <em>Dummy Classifier (base line); Logistic Regression; Linear Support Vector Classifier (SVC); Decision Tree Classifier; K Neighbors Classifier; Multinomial Naïve Bayes;</em></p><p>Ensemble/Meta-modelling — <em>ADABoost, Bagging Classifier, Random Forest Classifier, Voting Classifier</em></p><p><strong>C. Model Evaluation</strong> — <em>Accuracy, Precision, Recall, F1-Score, AUC</em></p><p><strong>D. Statistical Testing </strong>— Paired t-test</p><p><strong>E. Fine Tuning the Model for Performance</strong></p><p><strong>Goal: </strong>The classification task we want to perform on our dataset is between current and former employees (job status) through the reviews and other features. Hence, the model, given a feedback instance, will classify the into a former or a current employee of the company.</p><p>Have a look at the data:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/624/1*ueqffMcK251WTVFGCV9DAQ.png" /></figure><h3>A. Data Pre-processing</h3><p>The dataset contains over 67k employee reviews for Google, Amazon, Facebook, Apple and Microsoft web scrapped from Glassdoor. The original dataset contains 17 features which contain both numeric (ratings) and text data (feedback comments).</p><ul><li><strong><em>Class Imbalance — </em></strong>Class imbalance is a very common challenge while handling a classification problem in Machine Learning. As we are considering ‘job_status’ as our target label for the classification, we need to consider if all the classes of ‘job_status’ are equally distributed in the dataset. Our dataset has 2 categories of ‘job_status’ namely ‘current_employee’ and ‘former_employee’, and we discovered that ‘current_employee’ has a significantly greater number of instances (~42k) than ‘former_employee’ (~24k). The difference between the number of instances for the two class labels was above 15,000 and this may lead to a biased model. Of course, there are many solutions for this problem but specific to our data set is under-sampling will work just fine. We chose 20k instances randomly from both of the classes and created a balanced data set.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/592/1*aR2X9FpLUbGLtfk8bYp3mg.png" /><figcaption>Class Imbalance (left) handling with Under-sampling; Balanced dataset (right)</figcaption></figure><ul><li><strong><em>Feature Separation:</em></strong> Our dataset has a uniqueness to it because it contains three categories of data type — numeric, categorical and text data. I chose this dataset because it’s challenging for pre-processing but at the same time it gives back more experience in terms of data preprocessing and a variety of model building. Furthermore, there is a wide array of Machine learning algorithms that work well on numeric data while there are other machine learning algorithms that work better on text data. So, the type of algorithms we choose depends on the nature of the data. The diversity in the context of our dataset makes it appropriate to separate text and numeric data and run different experiments on them. For this step, data was vertically divided into text and numerical data for further exploration, processing, and predictive modeling.</li><li><strong><em>Text pre-processing</em></strong> — We can extract key features from text such as word count, average word length, frequency of words, TF-IDF etc. through data exploration. Please follow the below articles for text data pre-processing and feature extraction and intuition behind extracting those features.</li></ul><ul><li><a href="https://medium.com/100-days-of-ml-and-code/feature-extraction-from-text-text-data-preprocessing-594b11af19f5">Feature Extraction from Text (text data preprocessing)</a></li><li><a href="https://medium.com/100-days-of-ml-and-code/text-preprocessing-in-python-383af6c7fd68">Text Preprocessing in Python</a></li></ul><p>Text and numeric data are pre-processed separately. The below sections perform data pre-processing on the numeric data.</p><p><strong>Numeric &amp; Categorical data pre-processing —</strong></p><ul><li><strong>Imputing missing values and feature conversion — to Numeric Data:</strong> Our dataset has ratings such as work-life balance ratings, culture, and values ratings etc. given by either current or former employees for different companies. We found that there were missing values in these ratings. Missing values should be treated carefully and the treatment method varies from data to data while keeping the context in mind. Since these ratings were ordinal in nature, we replace the missing values with the numeric value ‘2.5’ (mean rating). The reason why we chose ‘2.5’ is that it is not too high nor too low and thus, will not have a significant impact on our models, and we can potentially avoid biases.</li><li>We also discovered that our dataset contains categorical data, and we want to convert them to numeric data. For instance, ‘company’ has 6 different categories, so we can use dummy encoding that map employees to their respective companies. The way it works is value ‘1’ will be set if the employee works or worked in that particular company and the rest will be set to ‘0’. Figure 4 shows a snippet of our dummy encoding technique. For other categorical features such as ‘location’ and ‘job title’, we can replace the categorical data with their respective frequency distribution, which is a numeric data. The formula used for frequency distribution:</li></ul><p>Frequency distribution for feature A = sum(∀x in A)/sum(all different values in feature A)</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/748/1*uMxZ7npTmEM4OW9RQPWOrw.png" /><figcaption>Dummy Encoding for ’Company’ feature</figcaption></figure><p><strong><em>Feature extraction — Numeric Data: </em></strong>Some features in our dataset contain values that can be separated and form new features of its own. One such feature is ‘Date’ where we separated its values and formed 3 new features namely ‘Post month’, ‘Post Year’ and ‘Post Day’. Another such column is ‘Job title’ which is in the format — &lt;Current/former Employee&gt; — &lt;Job Title&gt;. Two examples: Current Employee — Software Engineer and Current Employee — Manager. Hence we separated job status &lt;Current/former Employee&gt; and job title into two columns: job_status and designation.</p><p><strong><em>Target Variable Conversion — </em></strong>‘job_status’ is the target which is converted from categorical to numerical values by assigning the values 0 and 1. We found that using ‘job_status’ as our target label will be most appropriate with respect to the dataset that we have. Current Employee = 0, Former Employee = 1</p><p><strong><em>Data Standardization— </em></strong>Since our input space has a range of values from 0–3000 (helpful count), we decided to apply data standardization, which will bring the data between 0 and 1. Otherwise variables might not contribute equally to the model and larger values might dominate. This can be easily done with Scikit-learn’s MinMaxScaler function.</p><h3><strong>B. Model Training &amp; Selection Using K-fold Cross-Validation</strong></h3><p>Please refer to the below post for train-test split, k-cross validation, accuracy, precision, recall and F1-Score in a simplified way!</p><p><a href="https://medium.com/deepdatascience/machine-learning-train-test-model-evaluation-techniques-easy-way-a60735836a38">Machine Learning Train, Test &amp; Model Evaluation Techniques — Easy way!</a></p><p>In this project, we used 10-cross validation. Dataset was divided in 10 sets; models were trained for 10 iterations; in each iteration 9 sets (90% data ) were used for training and 1 set (10%) for testing. Models used for k-cross validation:</p><p><em>Dummy Classifier (base line); Logistic Regression; Linear Support Vector Classifier (SVC); Decision Tree Classifier; K Neighbors Classifier; Multinomial Naïve Bayes;</em></p><p>Ensemble/Meta-modelling — <em>ADABoost, Bagging Classifier, Random Forest Classifier, Voting Classifier</em></p><p><strong>Experiment 1:<em> Predictive Modeling for Numeric Data — </em></strong>For our model construction, we have implemented six models i.e. Linear classifier, Tree-based model, Distance-based, Rule-based model, Probabilistic model, and Ensembles. The numeric dataset has 18 features which became our inputs for the models and ‘job_status’ as the target label. The section below provides a brief description of each model and its performance on the numeric data.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/358/1*laerPMKsbVGYbd24qOxC1A.png" /><figcaption>Sample of Numeric Data</figcaption></figure><p><strong><em>K-cross validation on numeric data:</em></strong> The below figure shows the accuracy performance of various Machine learning models that were tested on our numeric data. As we can see here that Decision Tree Classifier performed the best with an accuracy of 73.7% over a 10-fold cross-validation while Dummy Classifier performed the worst with an accuracy of just 49.7%, much like random guessing. From this, we decided to apply ensembling on our Decision Tree Classifier which we hope will give better performance on the accuracy metric.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/288/1*PdNszza--emhZqp2E8FJsQ.png" /><figcaption>Accuracy performance of different ML models on Numeric Data</figcaption></figure><p><strong><em>Ensemble:</em></strong> Ensembles are used to increase the performance of different models, become less prone to overfitting, and also increase the diversity in the learning style. We have used 10 decision trees for Random Forest while for Bagging — 20 decision trees were used. For Boosting, AdaBoost has used 10 decision trees. Below figure shows the accuracy of the ensemble methods we used. The 3 ensemble models didn’t have a significant difference in their accuracy performance with a range between 73%-75%.</p><p>Now to check the precision, recall, f1-score and support, the dataset was split into 2 parts with 80% as the training set and 20% as the testing set.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/288/1*Gqzk-pfy3Q0Au7yf5w3yIw.png" /><figcaption>Accuracy performance of different ensemble models on Numeric Data</figcaption></figure><p>A custom voting classifier was also used which is essentially a <strong>meta-meta-model</strong> consisting of AdaBoost, Bagging classifier and Random Forest. The voting was set to ‘hard’ so that voting is done on the labels and not on the probabilities. The classifier was applied to the dataset (8/10 part training and 2/10 part testing) and the accuracy was measured. Below figure shows the accuracy with f1-score, support, precision, recall of the custom voting classifier.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/440/1*4_R84PKRc8i_CxXHwpdQzg.png" /><figcaption>Different statistical metric values on customer Voting Classifier on Numeric Data</figcaption></figure><p>From all the four ensemble models and the class label ‘cur- rent_employee’, AdaBoost has the highest precision score i.e. 0.74, Random Forest has the highest recall i.e. 0.77 while both Random Forest and the custom voting classifier has highest f1- score i.e. 0.75. For the class label ‘former_employee’, Random forest has the highest precision score i.e. 0.76, AdaBoost with the highest recall i.e. 0.73 and the custom voting classifier with the highest f1-score i.e. 0.74 and the rest with a score of 0.73. On the overall accuracy, the voting classifier performed the best with an accuracy of 74%.</p><p><strong>AUC (Area Under Curve) for Ensembles:</strong> Finally, for the numeric data, we calculated the AUC, and we can see here that the custom classifier has the highest AUC with a value of 0.74146 . From visual observations, all of them are almost performing the same but the <strong>custom voting classifier is the winner here and Random Forest runner up!</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/496/1*C4zAgvbeNsaa14q7xAgBZA.png" /><figcaption>AUC of the four ensemble models on Numeric Data</figcaption></figure><p><strong>Experiment 2<em>: Predictive Modeling for Text Data</em>: </strong>The final features selected after text processing were the calculated TF-IDF for feedback, the average word length and the feedback word count, which became the input space with ‘job_status’ as the target label. For the selected features, we ran our four models i.e. Logistic Regression and Linear SVC (Support Vector Classifier), Multinomial Naïve Bayes classifier and Random Forest Classifier with a 5 fold cross-validation. Below figure shows the mean accuracy of the four models. From the results, Logistic Regression was performing better than the other models. However, with text features, we couldn’t achieve significant accuracy!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/285/1*MUHF42Ds6VQLm35H8iD6cw.png" /><figcaption>Accuracy performance of different machine learning models on Text Data</figcaption></figure><p><strong>Experiment 3: <em>Predictive Modeling on Combined Data and Selected Models</em>:</strong> For the predictive modeling on the combined dataset — <strong>numeric + text features</strong>, we selected all the features on the numeric dataset and three features for the text dataset namely ‘feedback_word_count’, ‘avg_word_length’ and ‘sentiment_score’. Totally, the final input space contained 22 features with 40,000 instances with no class imbalance. The target label remained the same with ‘job_status’ feature for classification.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/593/1*wpyIwwiIQJ4-FwuoPGuhOg.png" /></figure><p>The feature ‘sentiment score’ was re-scaled between 0–1 since it contains negative values and Multinomial Naïve Bayes cannot work with negative values. Again,10-fold cross-validation was applied on all the models while keeping track of the accuracy metric. We found that Decision Tree Classifier was performing better than the other models.</p><p>Again we build ensemble models considering Decision Tree Classifier as base model and found Random Forest performed the best with an accuracy of ~74%. We discarded other base models.</p><p><strong>AUC(Area Under Curve) for ensemble models:</strong> We calculated the AUC, and we can see here that Random Forest has the highest AUC with a value of 0.7399 for our dataset.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/488/1*SBRcPYSESF27zKO90YAgkQ.png" /><figcaption>ROC Curves of the four ensemble models on Combined Dataset</figcaption></figure><h3>F. Statistical Testing</h3><p>As we can see there’s not much difference between the accuracies of Random Forest and Voting Classifier. Hence to <strong>chose one final model</strong> we need to perform statistical test if there’s an actual difference between accuracies or just by chance. As we have only one dataset, we need to use a standard test that can test the models on multiple folds of the single dataset but with multiple algorithms. Student’s t-test is suitable statistical test for this problem. We need to identify if, <strong><em>for a significance level 0.05, is there a statistical difference or the difference is by chance? </em></strong>Our null hypothesis is “there’s no difference in the accuracies of Random Forest and Voting Classifier”.</p><p>With significance level α = 0.05 ; all the p values we found were smaller than 0.05, hence we reject the null hypothesis. That means there’s significant difference between the algorithm’s results. So <strong>we choose Random Forest as our final model for future predictions.</strong></p><h3>G. IMPLICATIONS AND FUTURE WORK</h3><p>Employee satisfaction is one of the reasons behind the great productivity of the employees, and it also keeps the attrition rate minimum. In this project, we have explored the employee’s review dataset and tried to find out the reviews given by employees are from the former employee or current employees. The classification between the current and former employees was done depending on their reviews with ~73% accuracy.</p><p>Further work can be done on top of this project. Data could be collected and integrated from different sources to make the models more accurate for the predictions. Intentions of the current employees can also be determined if they’re thinking of leaving the company. Hence, employee satisfaction and retention can be improved by human resources in companies. There are also many hidden insights present in the data, which can be mined and provided to the companies to help them improve the policies for the betterment of the employees.</p><p>Cheers! Shoot comments if need more clarification on any part :)</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=64c8623fd734" width="1" height="1" alt=""><hr><p><a href="https://medium.com/deepdatascience/how-to-make-a-complete-machine-learning-project-64c8623fd734">How to Make A Complete Machine Learning Project?</a> was originally published in <a href="https://medium.com/deepdatascience">Data Stories</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Machine Learning Train, Test & Model Evaluation Techniques — Easy way!]]></title>
            <link>https://medium.com/deepdatascience/machine-learning-train-test-model-evaluation-techniques-easy-way-a60735836a38?source=rss-9c82163c186b------2</link>
            <guid isPermaLink="false">https://medium.com/p/a60735836a38</guid>
            <category><![CDATA[machine-learning]]></category>
            <category><![CDATA[deep-learning]]></category>
            <category><![CDATA[train-test-split]]></category>
            <category><![CDATA[model-evaluation]]></category>
            <category><![CDATA[accuracy-and-precision]]></category>
            <dc:creator><![CDATA[Adarsh Verma]]></dc:creator>
            <pubDate>Thu, 05 Mar 2020 20:58:16 GMT</pubDate>
            <atom:updated>2020-03-05T21:09:12.763Z</atom:updated>
            <content:encoded><![CDATA[<h3>Machine Learning Train, Test &amp; Model Evaluation Techniques — Easy way!</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*2PyAFgAm2ChPaMuD" /><figcaption>Photo by <a href="https://unsplash.com/@askkell?utm_source=medium&amp;utm_medium=referral">Andy Kelly</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><p>In this post we will discuss train-test split, k-cross validation, accuracy, precision, recall and F1-Score in a simplified way!</p><p><strong>Train and Test Techniques Overview:</strong></p><p>There are three main techniques are being used for the training and selection of the models for classification problem.</p><ol><li><strong><em>Train-Test Split — </em></strong>Train test split is a simple and fast technique to divide the dataset into 2 parts: training data and testing data. Usually, the splits are 80%–20%, 75%–25% and 70%–30% which means the first portion is for training the models and the second portion is for testing. Consider 80%–20% split, where 80% of the data will be used for training and 20% for the testing. There is one <strong>issue</strong> with the train-test split is that models can give different accuracy for different splits dataset for training and testing. This technique can be used with scikit-learn’s train_test_split method.</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*4ReYdyV-8N2AnUIjEBMXcQ.png" /><figcaption>Python Code for train-test split</figcaption></figure><p><strong><em>2. Train-Validation-Test Split — </em></strong>This technique is very similar to <em>Train-Test Split</em><strong><em> </em></strong>technique and generally used in deep learning where we do not want to show the data to the model while training. Therefore, model is trained on training data, validated on the validation dataset. Parameters of the model are tuned according to result of validation data. Then we finally test our model on the test data.</p><p><strong><em>3. K-fold Cross-Validation — </em></strong>Cross-Validation technique overcomes the challenge of the train-test split techniques and gives a more generalized accuracy of the model trained on a dataset. In K-fold cross-validation, the dataset is divided into k sets. There are k iterations of training and testing the dataset. In each iteration there, k-1 sets are used for training and 1 set is used for testing and at the end, the average of all the results is taken to provide a more general result. For example, if we use 10-cross validation. Dataset will be divided in 10 sets; models will be trained for 10 iterations; in each iteration 9 sets (90% data ) will be used for training and 1 set (10%) for testing. There is one <strong>issue </strong>with this technique is that after 1 iteration, the data set starts repeating itself.</p><h3>Model Evaluation Techniques- understanding in a very easy way!!!</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*-A0KdeAbl-QBSVWc" /><figcaption>Photo by <a href="https://unsplash.com/@agkdesign?utm_source=medium&amp;utm_medium=referral">Alex Knight</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><p>Let’s understand in way that will make it hard to forget.</p><p>Imagine there’s a bucket which has 10 diamonds and 10 stones. You built a robot to find diamonds from the bucket. You asked the robot to get the diamonds out of the bucket and leave the stones. Robot digs its arm in the bucket, tries to separate the diamonds from the stones and comes up with the 11 (what it thought) diamonds. Now when you examined you found that the diamonds, robot came up with, are actually 9 diamonds but 2 stones. Also, what it left in the bucket thought they are stones, are actually 8 stones but 1 diamond. (Mind the numbers!)</p><p><em>“You’re guessing it correctly that in this scenario; there are 2 classes — diamond — our positive class, stone — our negative class; robot — our classification model and finding diamonds from the bucket is our classification task.”</em></p><p>You knew that Robot did some misclassification but was accurate for 9 diamonds and 8 stones out of 20 (total). Hence you calculated the accuracy of the robot = (number of correct predictions/ total number of prediction)</p><p>(9+8) / 20 = 17/20 = 0.85 or 85%</p><p>Now, you want to know how <strong>precise </strong>the robot is? or in other words, wanted to find out <strong>“<em>Out of all the predictions for diamonds, how many are correct predictions for diamonds?</em></strong></p><p>Let’s see: robot predicted total 11 diamonds; but there were actually 9 diamonds: hence robot’s precision = 9/(9+2) = 9/11 = ~0.82</p><p>Furthermore, you wanted to find out <strong>“<em>How many are correct predictions for diamond out of all the diamonds present?”</em></strong></p><p>Let’s see: robot predicted 9 diamonds but total diamonds were 10; hence <strong>recall </strong>= 9/(9+1) = 9/10 = 0.90</p><p><strong>More formal definitions:</strong></p><p><strong>Accuracy — </strong>Ratio of correctly predicted instances to the total instances. Accuracy answers below question: <em>How many instances are correctly classified?</em>Accuracy = Number of Correct predictions / Total number of Predictions</p><blockquote>Our aim is to achieve high accuracy.</blockquote><p><strong>Precision — </strong>Ratio of correct predictions for a class (true positive) to total predictions for that class ( sum of true positive and false positive). Precision answers below question:</p><p><em>Example: Out of all the instances which were predicted as Class positive, how many of them actually belonged to Class positive?</em></p><blockquote>Our aim is to achieve high precision.</blockquote><p><strong>Recall — </strong>Ratio of correct predictions (true positive) to all the actual instances (sum of true positive and false negative). Recall answers below question:</p><p><em>Example: Out of all the instances that actually belong to Class positive, how many are predicted as Class positive?</em></p><blockquote>Our aim is to achieve high recall.</blockquote><p><strong>F1-Score</strong> — It’s a bit complicated to keep track of the precision and recall, specially when we are dealing with many classes(more than 2). we need a single measure. That’s when F1-score comes in, it’s a harmonic mean of precision and recall.</p><p>F1-Score = 2X (Precision X Recall )/ (Precision + Recall)</p><p>We can also use a factor of beta to emphasize on one of the precision or recall more than the other. <a href="https://en.wikipedia.org/wiki/Precision_and_recall">More here</a></p><blockquote>We always aim for high F1-score</blockquote><p>More on machine learning project, <a href="https://medium.com/deepdatascience/how-to-make-a-complete-machine-learning-project-64c8623fd734">here</a>.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=a60735836a38" width="1" height="1" alt=""><hr><p><a href="https://medium.com/deepdatascience/machine-learning-train-test-model-evaluation-techniques-easy-way-a60735836a38">Machine Learning Train, Test &amp; Model Evaluation Techniques — Easy way!</a> was originally published in <a href="https://medium.com/deepdatascience">Data Stories</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
    </channel>
</rss>