In the world of data-driven marketing, more and more tasks require a bit of coding. You might need to add an extra parameter to your tracking code or pull raw data from Google Analytics. You may want to create a simple prediction—or automate a few repetitive tasks in your PPC campaigns.
Or maybe you simply want to speak a common language with your developers so that you can brief them better and understand they may say, “This will take two weeks.”
Regardless, knowing one or two data languages—even at a beginner level—is a great help for an online professional’s daily job and, consequently, huge advantage over your competition.
Which programming language should marketers learn?
For a newcomer, there are four programming languages worth learning:
*Technically, SQL is a “declarative language,” not a programming language, but it has the “functionality of a mature programming language.”
Of course, you don’t have to learn all four at once. Even learning one will solve many, many problems that you never could’ve imagined solving before. Besides, after learning your first programming language, it’s usually much easier to learn the rest—you’ll already understand the underlying computer logic.
But which language is good for what? Who should choose which one? It depends on several things:
- the tasks you work on;
- the tools you work with; and
- your goal with the given language.
In this article, I’ll answer all these questions and provide an overview of the four most popular languages for digital analytics professionals.
But first… Why do we have more than one programming language?
Every language will have its advantages and disadvantages, so you should choose wisely based on the questions you want them to help answer.
Let’s see the languages one by one!
Best at: data analysis; quick and simple data queries—even on multi-million-line datasets; joining data tables efficiently
Marketing goals: accessing in-depth user data from your company’s database; running advanced queries on Google Analytics data, etc.
Get started with: SQL For Data Analysis Tutorial Series
SQL is a relatively simple language. It stands for “Structured Query Language,” but I like to call it “Excel on steroids”—it highlights its essence. SQL is great for running queries on really big tables (even tables with more than 10 million rows). It can get a massive job done, sometimes in seconds, while Excel often keels over with just a few hundred thousand rows.
Handling million-line datasets efficiently is one of the greatest powers of SQL, and it’s the main reason that many companies store a significant amount of their data in this format. The trade-off is that SQL doesn’t have a user-friendly point-and-click interface; we have to access our data by writing code-based queries.
Here’s the difference between a SUM() function in Excel (top) and SQL (bottom):
For me, SQL is the best “entry language” to the world of coding because it’s simple and straightforward.
How SQL solves real-world marketing problems
Create more accurate, detailed reports
One of my former colleagues, Rob, is an SEM guru—with zero coding background. Years ago, he endured continual data discrepancies among Google Adwords, Google Analytics, and internal company reports—sometimes greater than 10%.
Rob didn’t know which report was the best guide for his next move. (Everyone who works with PPC tools has probably experienced the same problem at least once.) He also didn’t understand how internal reports were built, and the developers—as usual—had a more important project than helping him debug them.
One day, he got so annoyed that he decided to learn SQL by himself. He picked up the knowledge he needed in less than two days. (In my experience, it’s quite feasible for almost anyone to reach an intermediate level in SQL in that amount of time.)
After that, he could easily query the company database and find the bugs. He was also able to build more accurate, more detailed reports since he had the business knowledge and the coding skills.
Create refined segments with Google Analytics data
Digital analysts should also know that BigQuery, a Google product, lets you use SQL to manage Google Analytics data.
For instance, you can join different Google Analytics tables to create reports that aren’t possible in the Google Analytics point-and-click interface. Other use cases include diverse, data-heavy tasks such as querying the metadata from 1 billion taxi rides or back-end monitoring of analytics for real-time fraud detection.
The standard Google Analytics user interface lets you use primary and secondary dimensions to create micro-segments by, for example, looking at the number of sessions by landing page and source.
But, if you know SQL, you can segment your Google Analytics data further by adding a third and fourth dimension (e.g. location and device type). Plus, you can add advanced filters (like counting only the top 20% most-active users) and run advanced calculations (like using the median instead of mean), and many, many more things.
Best at: implementing tracking codes; every kind of web-development solution
Marketing goals: improving accuracy or granularity of tracking for better data quality
Here’s one you’ve almost certainly seen before:
Connect inventory with ad campaigns
One of my clients had an ecommerce company with more than 100,000 products. They constantly added new products, discontinued old products, ran out of stock, or filled up their storage house with best sellers.
The business was so complex that their ads couldn’t keep up— they should’ve started and stopped Google Ads campaigns every minute, but it was impossible to do that manually.
After that, the campaigns started and stopped automatically based on the company’s inventory data. It saved their team countless hours of work, reduced human errors, and saved ad spend—they no longer wasted money promoting out-of-stock or discontinued products.
Enable robust A/B testing
Marketers without jQuery skills rely on testing tools’ visual editors to design and publish A/B tests, often with bad results.
Either the lack of coding skills limits their ability to test what matters or over-ambitious changes break the site.
Best at: predictive analytics; machine learning; APIs
Marketing goals: running advanced analytical methods on datasets; making predictions to guide future planning
Get started with: Python for Data Science Tutorial Series
The big difference, though, is that Python is primarily for “back-end” and analytics tasks, not “front-end” tasks (e.g. website development).
From an analytics professional’s point of view, the greatest advantage of Python is the many analytics extensions written specifically for data-science tasks. If you want to run predictive analytics or a machine learning project, you will probably work in Python.
Additionally, many popular digital analytics and marketing tools offer access to APIs. (A quick, non-technical explanation of APIs is available here.)
How Python solves real-world marketing problems
A few recent projects come to mind:
- At many startups, we used Python to predict whether users would cancel their subscription in the near future—then reached out to them proactively.
- At a larger company, we used Python to estimate the expected increase in support tickets and planned our quarterly hiring on those numbers.
- At a very small company, we used Python to scrape huge walls of text automatically and analyze media mentions.
There’s another example, too, albeit one that’s a bit out there. In early 2018, I wrote code in Python to connect to a cryptocurrency service provider’s database using their API solution.
Still in Python, I queried the exchange rate of Bitcoin every minute, and, still in Python, I tried to fit a statistical model to predict the exchange rate change for the next 10 minutes. (Before you get excited: I tested over 10,000 models, and none gave an accurate-enough prediction.)
But you can run similar projects using your Google Analytics data, Google Ads data, or any internal company data—if you know Python. I’d recommend starting with a few weeks (1–2 hours per day) to learn and practice the syntax, and to get familiar with its marketing-oriented extensions.
Note: You may have heard about another popular language similar to Python called R. It’s used mainly by mathematicians and statisticians, and its syntax is a bit more difficult to learn compared to Python. Because of that and other reasons, I recommend Python over R for digital analysts and CRO professionals. However, some “hardcore” statistical packages are available only in R.
Best at: moving files, automating scripts, connecting other languages
Marketing goals: automate reporting
Get started with: Data Science at the Command Line
Bash is a “bonus” language—and it’s not really famous, either. But you should know that it’s the built-in language of every computer that runs on an Ubuntu/Linux operating system and, thus, the language of most data servers, too.
Bash is not the first language you should learn, but it’s not difficult. The basic view is the classic “command line” design. Many programmers like it: It looks cool (a question of taste, of course), and it offers clear access to communicate with the computer on a core level.
How Bash solves real-world marketing problems
I use Bash for three specific tasks (mostly in data-science projects):
- Moving, copying, cleaning, and re-structuring data files on a remote data server.
- Automating scripts (e.g. pulling user data, formatting it, and saving it to a server automatically at midnight).
- Connecting Python and SQL scripts and running them together.
For instance, in the early days of Prezi (my first workplace), we built the entire data infrastructure using only Bash, and it handled the data of 3 million users—for the above tasks and reporting—very well.
You can learn the basics of Bash in one or two days. However, it makes sense only if you’ve already learned SQL or Python (or both).
What’s the best way to learn a programming language?
To learn these languages, there are plenty of free and paid resources, online and offline. (I’ve linked a resource at the top of the section for each language.) Whether you prefer books or workshops or even interactive courses, any will guide you effectively through the theoretical basics.
But the most important part of the learning process is practice. Find a small project to apply your freshly gained coding skills to demonstrate the real-world problems you can solve and boost your motivation. Practice will also deepen your knowledge.
Here are a few pet-project ideas:
- Python: Build a bot that can play Blackjack.
- SQL + Bash: Scrape articles on news portals and try to collect similar articles from different portals.
These are just my ideas. By all means: Find something that interests you and that you would enjoy building—then build it!
Even if you don’t plan to become a practitioner, programming knowledge may be essential to help find the right candidate for your marketing department.
How can you find and hire professionals with these skills?
It’s a tough question.
A digital marketer or CRO professional who has a business mindset and also knows how to code is rare. Why? Because they’re two different skill sets. More and more companies, however, have realized the importance of coding in digital analytics, and the demand for these talents is higher than ever.
The easiest way to get the right person on board is to find someone internally—either a programmer who’s interested in business and marketing or a digital marketer who’s open to learning how to code. With the right training programs, it’s not too hard to transition a motivated talent’s career path.
How to interview candidates for programming positions in marketing departments
If you find a good candidate from outside your company (it’s not impossible), make sure that the interview committee has at least one technical person and one business person. It’s not uncommon for these applicants to go through 6–8 well-designed interview rounds, including a take-home assignment and whiteboard technical screenings.
When you look to hire someone, your main goal should be to understand if she can apply her knowledge in practice. Asking theoretical questions like, “Please explain the role of indentation in Python,” or, “How would you calculate standard deviation?” won’t help.
As an applicant, this was a “tell” that the committee had no idea why they wanted to hire me. (And, as a result, I turned down their offer at the end of the process.) The best questions are 100% practical and make the applicant think! For example, “You have these two data tables with X and Y user information. Who are our power users? Why? Write a query for it!”
To get started, pick the one that has the best potential to answer your most important marketing questions, then start learning! After the first few hours, you’ll see that it’s not as complicated as you may think—and how useful it can be in your everyday job as a marketer.
The post The Best Programming Languages for Digital Marketers appeared first on CXL.
Source: Conversion XL