Cover....1
Title Page....2
Copyright....3
Table of Contents....5
About the Author....13
About the Contributing Editor....14
About the Technical Reviewer....15
Acknowledgments....16
Why I Wrote This Book....17
Foreword....21
Chapter 1: Introduction....23
The Inexact (Data) Science of SEO....23
Noisy Feedback Loop....23
Diminishing Value of the Channel....24
Making Ads Look More like Organic Listings....24
Lack of Sample Data....24
Things That Can’t Be Measured....25
High Costs....26
Why You Should Turn to Data Science for SEO....26
SEO Is Data Rich....26
SEO Is Automatable....27
Data Science Is Cheap....27
Summary....27
Chapter 2: Keyword Research....28
Data Sources....28
Google Search Console (GSC)....29
Import, Clean, and Arrange the Data....30
Segment by Query Type....32
Round the Position Data into Whole Numbers....33
Calculate the Segment Average and Variation....34
Compare Impression Levels to the Average....36
Explore the Data....36
Export Your High Value Keyword List....39
Activation....39
Google Trends....40
Single Keyword....40
Multiple Keywords....41
Visualizing Google Trends....44
Forecast Future Demand....45
Exploring Your Data....46
Decomposing the Trend....48
Fitting Your SARIMA Model....51
Test the Model....54
Forecast the Future....56
Clustering by Search Intent....59
Starting Point....61
Filter Data for Page 1....62
Convert Ranking URLs to a String....62
Compare SERP Distance....64
SERP Competitor Titles....78
Filter and Clean the Data for Sections Covering Only What You Sell....79
Extract Keywords from the Title Tags....81
Filter Using SERPs Data....82
Summary....83
Chapter 3: Technical....84
Where Data Science Fits In....85
Modeling Page Authority....85
Filtering in Web Pages....87
Examine the Distribution of Authority Before Optimization....88
Calculating the New Distribution....91
Internal Link Optimization....98
By Site Level....102
Site-Level URLs That Are Underlinked....111
By Page Authority....118
Page Authority URLs That Are Underlinked....125
Content Type....128
Combining Site Level and Page Authority....130
Anchor Texts....132
Anchor Issues by Site Level....135
Anchor Text Relevance....138
Location....142
Anchor Text Words....143
Core Web Vitals (CWV)....146
Landscape....146
Onsite CWV....162
Summary....171
Chapter 4: Content and UX....172
Content That Best Satisfies the User Query....173
Data Sources....173
Keyword Mapping....173
String Matching....174
String Distance to Map Keyword Evaluation....180
Content Gap Analysis....181
Getting the Data....182
Creating the Combinations....189
Finding the Content Intersection....190
Establishing Gap....192
Content Creation: Planning Landing Page Content....195
Getting SERP Data....197
Crawling the Content....200
Extracting the Headings....203
Cleaning and Selecting Headings....208
Cluster Headings....212
Reflections....218
Summary....219
Chapter 5: Authority....220
Some SEO History....220
A Little More History....221
Authority, Links, and Other....221
Examining Your Own Links....222
Importing and Cleaning the Target Link Data....223
Targeting Domain Authority....227
Domain Authority Over Time....229
Targeting Link Volumes....233
Analyzing Your Competitor’s Links....237
Data Importing and Cleaning....237
Anatomy of a Good Link....242
Link Quality....246
Link Volumes....252
Link Velocity....255
Link Capital....256
Finding Power Networks....259
Taking It Further....264
Summary....265
Chapter 6: Competitors....266
And Algorithm Recovery Too!....266
Defining the Problem....266
Outcome Metric....267
Why Ranking?....267
Features....267
Data Strategy....267
Data Sources....269
Explore, Clean, and Transform....270
Import Data – Both SERPs and Features....271
Start with the Keywords....273
Focus on the Competitors....275
Join the Data....289
Derive New Features....291
Single-Level Factors (SLFs)....295
Rescale Your Data....298
Near Zero Variance (NZVs)....300
Median Impute....305
One Hot Encoding (OHE)....307
Eliminate NAs....309
Modeling the SERPs....310
Evaluate the SERPs ML Model....313
The Most Predictive Drivers of Rank....314
How Much Rank a Ranking Factor Is Worth....317
The Winning Benchmark for a Ranking Factor....320
Tips to Make Your Model More Robust....320
Activation....320
Automating This Analysis....320
Summary....321
Chapter 7: Experiments....322
How Experiments Fit into the SEO Process....322
Generating Hypotheses....323
Competitor Analysis....323
Website Articles and Social Media....323
You/Your Team’s Ideas....324
Recent Website Updates....324
Conference Events and Industry Peers....324
Past Experiment Failures....325
Experiment Design....325
Zero Inflation....329
Split A/A Analysis....332
Determining the Sample Size....341
Test and Control Assignment....343
Running Your Experiment....348
Ending A/B Tests Prematurely....348
Not Basing Tests on a Hypothesis....349
Simultaneous Changes to Both Test and Control....349
Non-QA of Test Implementation and Experiment Evaluation....350
Split A/B Exploratory Analysis....353
Inconclusive Experiment Outcomes....361
Summary....362
Chapter 8: Dashboards....363
Data Sources....363
Don’t Plug Directly into Google Data Studio....364
Using Data Warehouses....364
Extract, Transform, and Load (ETL)....364
Extracting Data....365
Google Analytics....365
DataForSEO SERPs API....371
Google Search Console (GSC)....376
Google PageSpeed API....382
Transforming Data....385
Loading Data....390
Visualization....393
Automation....394
Summary....394
Chapter 9: Site Migration Planning....396
Verifying Traffic and Ranking Changes....396
Identifying the Parent and Child Nodes....398
Separating Migration Documents....404
Finding the Closest Matching Category URL....408
Mapping Current URLs to the New Category URLs....412
Mapping the Remaining URLs to the Migration URL....414
Importing the URLs....418
Migration Forensics....431
Traffic Trends....432
Segmenting URLs....442
Time Trends and Change Point Analysis....456
Segmented Time Trends....459
Analysis Impact....461
Diagnostics....473
Road Map....482
Summary....486
Chapter 10: Google Updates....487
Algo Updates....488
Dedupe....495
Domains....497
Reach Stratified....503
Rankings....511
WAVG Search Volume....513
Visibility....514
Result Types....522
Cannibalization....530
Keywords....538
Token Length....538
Token Length Deep Dive....543
Target Level....551
Keywords....551
Pages....555
Segments....562
Top Competitors....562
Visibility....568
Snippets....575
Summary....579
Chapter 11: The Future of SEO....580
Aggregation....580
Distributions....581
String Matching....581
Clustering....582
Machine Learning (ML) Modeling....582
Set Theory....583
What Computers Can and Can’t Do....583
For the SEO Experts....583
Summary....584
Index....585
Solve SEO problems using data science. This hands-on book is packed with Python code and data science techniques to help you generate data-driven recommendations and automate the SEO workload.
This book is a practical, modern introduction to data science in the SEO context using Python. With social media, mobile, changing search engine algorithms, and ever-increasing expectations of users for super web experiences, too much data is generated for an SEO professional to make sense of in spreadsheets. For any modern-day SEO professional to succeed, it is relevant to find an alternate solution, and data science equips SEOs to grasp the issue at hand and solve it. From machine learning to Natural Language Processing (NLP) techniques, Data-Driven SEO with Python provides tried and tested techniques with full explanations for solving both everyday and complex SEO problems.
This book is ideal for SEO professionals who want to take their industry skills to the next level and enhance their business value, whether they are a new starter or highly experienced in SEO, Python programming, or both.
SEO practitioners, either at the department head level or all the way to the new career starter looking to improve their skills. Readers should have basic knowledge of Python to perform tasks like querying an API with some data exploration and visualization.