
Scripts are incredibly useful when it comes to getting the most out of Google Ads. These pieces of code are integral when it comes to looking beyond the manual features of Google Ads. They can give you an array of amazing insight and a wealth of information. Ultimately, it can be employed for impressive automated bidding.
In this article, we will demonstrate the value of an n-gram script.
N-grams models are used widely in communication theory, probability and computational linguistics. Google use them to correct your spelling mistakes and they are key to natural languge processing. Simply put, they are a way of understanding the relationship between words in a sequence.
An n-gram is a phrase made of n-words: a 1-gram is a single word, a 2-gram is a phrase made of two words, and so on. For examle, “I Love Google Ads” contains three 2-grams (“I Love,” “Love Google,” “Google Ads”) and two 3-grams (“I Love Google” and “Love Google Ads”)
N-gram models are very relevant to the Google Ads platform. They can be used by biddable media specialists to better understand the performance of phrases within a PPC account.
N-grams are useful because they allow you to identify certain words or phrases that are performing poorly, or conversely, keyword combinations that have yielded great results.
So, let’s say searches containing “free” perform poorly in general, but “free delivery” generates conversions.
The N-gram script adds up the clicks, impressions, cost, converted clicks and conversion value of each query containing the n-grams. It then calculates the click-through rate, cost per click, conversion rate, CPA and value/cost — so you can see their impact.
The script can be applied account-wide or localised to specific campaigns and ad groups. This can be extremely useful with regards to mining search terms for shopping campaigns or for new keywords in your search campaigns. It can also help with identifying negative keywords to help boost the return on ad spend (ROAS) of that specific campaign.
Below is a link to the n-gram script with some simple instructions on how to use it:
At the top of the script, there are some options you will need to change depending on your preferences and account setup:
If you find the script keeps timing out, it may be that your account is too big. Try running the script multiple times using campaignNameContains & campaignNameDoesNotContain to look at different campaigns each time. Set clearSpreadsheet to false so you don’t overwrite the data from previous runs. (If you want the account-level data, you can copy all of the n-grams from campaign level into a new worksheet and then use a SUMIF function to find the totals.)
To use the script visit https://www.brainlabsdigital.com/search-query-n-gram-performance/
Brainlabs are industry leaders when it comes to PPC wisedom!
As well as being geniuses in the field, they are also super generous and share their vast array of other useful scripts with fellow PPC pundits.
Got questions about the n-gram script and using it, then contact Wes on westley@loomdigital.co.uk.
If you are looking to take your PPC and biddable media to the next level, and ensure you are getting the best ROI then contact Loom.
Digital marketing expertise delivered direct to your inbox.