Pet Insurance Providers

Project Motivation

I left my full-time job in February 2024 to spend more time with family. I decided to try my hand as a freelance analyst instead of working on a permanent, full-time basis.

Initially, I turned to the popular freelance website Upwork. After navigating the endless list of “Build Large Language Model (LLM)” or “Develop AI Chatbot” postings for fixed rates less than the vanilla latte in my hand, I applied for and accepted my first contract. The client request was relatively straightforward and boiled down to helping them uncover differentiating characteristics across pet insurance providers.

As luck would have it, I was also shopping for pet insurance for my almost two-year-old black lab named Falco (adopted name so jury is still out whether he was named after Keanu Reave’s character in the Replacements, the Austrian musician from the 80s (“Rock Me Amadeus” for any fellow members of the MTV generation), or the character from the Nintendo Super Smash Bros. series).

The company I left provided an embarrassment of riches of employee perks and subsidized pet insurance is one of many I was fortunate enough to take advantage of. Falco’s coverage would terminate shortly after my departure and as a result, this proved to be a great opportunity to inform my decision in tandem with assisting the client.

Web Scraping

Providers: 10

Reviews: 26,878

Note: AKC missing from logo above
Source: Trustpilot

Sentiment Analysis

Sentiment Analysis performed using two popular Python libraries:

  • TextBlob
  • Vader

Model Evaluation

How much trust can we place in the results above?

In other words, how do we evaluate the efficacy of each approach for classifying sentiment?

Fortunately, the Trustpilot reviews contain star ratings, ranging from 1-star (lowest) to 5-star (highest)

To answer these questions, I treated the star ratings as expected sentiment and assigned as follows:

  • >= 4 (positive)
  • == 3 (neutral)
  • <= 2 (negative)

I viewed expected sentiment as the outcome variable and TextBlob and Vader sentiment assignments as the predictor variables.

Regressing expected sentiment on TextBlob and Vader sentiment assignments, and generating classification reports (below), is one way to evaluate the efficacy of each approach.

TextBlob Classification Report

Vader Classification Report

For the purpose of analyzing positive reviews, I prioritized Precision metrics over Recall; the subsequent analysis is based on the subset of data with a ‘positive’ Vader sentiment assignment

Positive Reviews Analysis

Approach:

  • Text pre-processing:
    • Tokenization
    • Stop words removal
    • Stemming and Lemmatization
  • Bag of Words (BoW) model creation:
    • Ended up with a prospective list of ~294,000 individual words or n-grams
  • Data reduction:
    • In collaboration with the client, reduced list to ~280 words or n-grams, prioritizing focus areas including:
      • Ease
      • Efficiency
      • Service & Support
  • Independence Testing:
    • Generated observed and expected counts for each provider/word (or n-gram) combination (ex. AKC/afford)
    • Restricted analysis to provider/word (or n-gram) combinations with observed AND expected counts greater than 5
    • Further restricted analysis to combinations with sufficient counts across all 10 providers
    • Calculate Chi-square test statistic for each combination
    • Calculate degrees of freedom and critical value
    • Restrict analysis to combinations where Chi-square test statistic is greater than critical value
    • Calculate odds ratio and 95% confidence interval for each combination

Note: The above approach yielded ~60 word/n-grams for the purposes of understanding differences in sentiment across providers.

“Ease” (Sample Reviews):

“I really love it because I can take my dog anywhere I want. It makes life much easier.”

“A very simple and easy experience.”

“Great coverage. Easy to file a claim. Quick pay back”

“Efficiency” (Sample Reviews):

“Handle my claim quickly Very happy with your insurance”

“Fast and efficient reimbursement! Outstanding and caring customer service!”

“Prompt responses to claims and courteous staff.”

“Service & Support” (Sample Reviews):

“Years of excellent service great Company!”

“Wonderful professional experience from this company. Excellent and caring.”

“The staff is very knowledgeable and helpful with my questions.”