![]() ![]() Scraping your competitors’ product lines and categories helps you better understand the trends that define the market. Using a web scraping tool can help you automatically get updated information regarding your competitor’s pricing strategy and flash sales. Investigating competitors' product pricing, overseeing their product line and categories, or analyzing their social media strategy are just three of the most valuable tactics you can use to improve your business.įinding and comparing product prices is not a very challenging task, but it is time-consuming. In the following article, we will build a script that will help us gather all the information we need regarding our business competitors by taking advantage of their public Yelp profiles. We just have to find a way to automate the data gathering process. With social media gaining a lot of traction in the last couple of decades, businesses are trying to be more present in their customer’s life by creating an online presence. Nowadays, your competitors already have all the information you need in the open. This way, you can focus on delivering the most value to your customers. Actual competitor analysis is a tedious process that’s better left to the software. ![]() The name of this shiny app is a nod to Silicon Valley’s Not Hotdog application.Have you ever wondered how businesses keep track of the competition? Of course, double agents, private investigators, and binoculars may sound fun, but real life isn’t like the movies. However here is a screenshot of the script above developed into an interactive shiny application to search for any and the gist of the code if your interested in running a local version. In trying to create and publish a shiny application that wraps this code, I came up with errors given that OAuth2.0 grants access to users ? and not applications ?. The non-premium API access only includes up to 3 reviews and only a sample of the full text, leaving obvious gaps when trying to detect the keyword ‘mustard’ and contingent on enough reviews which details ? preparation. ![]() # loop through each restaurant's 3 reviews and extract the text and detect the presence of the string 'mustard' # create a function to structure the urls with the business idīiz_reviews$url % map_df(`[`, "status_code") = 200 The purrr version to check multiple restaurant text reviews for the string ‘mustard’. Get business reviews: After getting a specific McDonald's `id` restructure the url as an individual value and secondly creating a function to create a ame with urls for each business from the search endpoint. # Set your credentials as environment variables. Create an application on the () and agree to the Terms and aggreements This script highly references Jenny Bryan’s yelpr example! library(yelpr) # devtools::install_github("jennybc/ryelp") The process below explains the approaches I took to gather data from the web with the yelp API and the development of a shiny web application which detects string patterns in reviews for the keyword ‘mustard’ for a specific McDonald’s. I hypothesized that these deviations in food prep could be identified from reviews. After some Google research, I noticed others had documented the regional differences in the use of mustard and but no aggregated data set existed detailing which McDonald’s added mustard to their hamburgers. in Maryland and not in Upstate New York). As a kid I traveled to different McDonald’s across the east coast and noticed a difference in the classic hamburger preparation for adding mustard (i.e. McDonald’s is a nostalgic component of America ? and a pioneer of fast food operations and real estate ventures, as depicted in the 2016 film, The Founder, about Ray Kroc. Leveraging tidyverse packages httr, stringr & purrr – ![]()
0 Comments
Leave a Reply. |