Using R to Analyze Google Analytics Data
Website operators and digital marketing analysts frequently use Google Analytics and Piwik to monitor and analyze site traffic, but neither of these tools allow the user to add data from external sources. This course will show you how to combine Google Analytics with data from external sources including content management systems, Google Trends, Google Search Console and other sources to better understand what makes for successful pages and successful user experiences.
The class will cover the following:
- Installing and getting started with R
- Google Analytics, Google Trends and Google Search Console Terms and Conditions with respect to data use
- Retrieving and loading Google Analytics data with R
- Retrieving and loading Wordpress and Joomla content data with R
- Retrieving Google Trends and Google Search Console data with R
- Combining web analytics data
- Using R to prepare both static and interactive graphics of web analytics data
- Using R to prepare correlations and predictive models of web analytics behavior
- Setting up batch jobs to maintain historical data
Prerequisites
The course assumes previous use of a programming language such as Visual Basic, Excel Macro language, C/C++, Java, Perl, Python, SAS or PHP, though the course does not assume that the student is an active programmer. Knowledge of statistical concepts (mean, median, standard deviation) is helpful but not required.
- Details
- Written by Bruce Moore
- Hits: 2337
Introduction to R
The explosion of data collection on the Internet and in all business processes has resulted in a dramatic increase in demand for data analysis and data science professionals. This course is designed to help both programmers who need to learn data analysis tools and data science professionals who know SAS or other tools and need to learn R. Examples and homework assignments will use digital marketing, economic, police/fire, and geographic data t illustrate techniques for preparing, cleaning, visualizing and analyzing the various data types and formats using the R statistical programming language.
The class will cover the following:
- Installing and getting started with R
- Understanding the strengths and limitations of R
- Data exploration and data preparation
- Common R functions and scripts
- Reading and writing data with R
- Programming efficiently in R
- Curve Fitting, prediction and interpolation
- Geostatistics, geocoding and mapping
- Advanced graphics building and communicating your case in graphics
- Using Shiny for simple interactive visualizations
- Advanced tools and packages and developing predictive models with R
Prerequisites
The course assumes previous use of a programming language such as C/C++, Java, Perl, Python, SAS or PHP. The course also assumes knowledge of basic statistical concepts such as median, mean, standard deviation, and linear regression.
- Details
- Written by Bruce Moore
- Hits: 2116

Security Threats in 2017
As the 2016 election cycle shows, computer security cannot be taken lightly. The Russian hack of the Democratic National Committee was exacerbated by the fact that it was initially handled only by an entry-level employee who made some poor decisions. The Russian social engineering hack of John Podesta’s email may have been made easier by a possible failure to turn on two-factor authentication on his Google account. It will only get worse.
Malwarebytes released a forecast of problems in the coming year that should be required reading for all computer users; computer security people already know this stuff; I’m talking about my wife, my siblings and my extended family members whose home network problems I fix when I visit. Read the article and then start doing the following if you have not already done so:
- Turn on two-factor authentication for Google.
- Turn on two-factor authentication for Facebook.
- Turn on two-factor authentication for Yahoo/Flickr.
- Turn on two-factor authentication for everything else
- Encrypt your iPhone or Android phone to protect it if is lost or stolen.
- Enable a remote reformat capability for your cell phone.
- Tell all businesses that you deal with to convert to HTTPS if they have not. Give them a reason to get secure–your continued business
- Do not re-use passwords, which will require getting a password manager. Use a hard password on your password manager. Password managers are a likely new target for attacks, so I have chosen one (Keepass) that is somewhat less convenient, but which would first require the attacker to gain access to my computer.
- Stop using Internet Explorer (and any service that requires it) and switch to Firefox, Chrome or Vivaldi as a browser. Firefox is best from a privacy standpoint, but Chrome and Vivaldi are faster and OK for privacy if you turn off some default settings. I am starting to use Vivaldi a lot and like it. Opera was purchased by a Chinese firm, and is no longer a browser that I use regularly, as I just do not trust Chinese companies for anything after the Startcom certificate mess.
- Decommission all Windows XP computers, if you have not already. Remove the hard drive and destroy it or wipe it before disposing of it.
- Change the default passwords on your router, Roku, Apple TV, smart TV, DVD player, baby cams, kitty cams, garage door opener (yes, some have WiFi) and other devices. Use something unique to each device and hard. For these it is OK to tape the password on the device; if someone breaks into your house and gets the password to your kitty cam, you have bigger problems. Hacked baby cams and other devices were used on a recent denial of service attack.
- Update the firmware on all of the above devices. Pay attention to the manufacturer’s firmware update practices when purchasing new devices, and do not buy from firms that never release security updates. You can continue to use some manufacturer-abandoned routers with DD-WRT.
- Consider encrypting USB flash drives. Veracrypt works on all platforms if you have to go from Windows to OS X, to Linux.
- Encrypt your laptop hard drive.
- Make sure that your phone has security patches. This is easy on iPhones, but not on Android devices (except those purchased directly from Google like the Nexus series). If your device cannot be made current on security patches, get a new one.
- Switch to Signal, What’s App, or perhaps the somewhat less secure Hangouts for all of your messaging. I really like Signal.
- Do disk-level backups to a USB drive and keep one off-site in a safe-deposit box. This is to protect family photos. I use Clonezilla. When I was a systems programmer and database administrator, we used to say “tape is cheap.” Today, USB disks are cheap. You only need a backup when you need a backup, and when you need one, you would pay a lot to have one.
- Use a cloud backup service like Backblaze or Carbonite. The cloud is cheap today. Macafee, Symantec and others offer cloud backup as well.
- Keep your antivirus updated. Windows 10 has a decent built-in anti-virus and firewall, but if you are on another platform, you should have something and there are solutions for Windows 10 that are arguably better than the free one.
- Give your extended family members a disk drive with family photos for Christmas or the gift-giving opportunity of your choice. This is part of my disaster revovery plan as well as family history communication.
- Stop taking fun quizzes on Facebook. Most, if not all, are just a way to collect your personal information for impersonation, identity theft or more benignly to fill you Facebook feed and mailbox with annoying targeted marketing.
- Details
- Written by Bruce Moore
- Hits: 3778
Prezi Makes it Easy to Show Context in Presentations
One problem with PowerPoint presentations is that it is sometimes hard give the audience context or hints on where you are in an outline for a speech. You can do a running outline in PowerPoint, but it is laborious, and small presentation changes can require a painful rework of outline slides. Apple’s Keynote and LibreOffice’s Impress have similar problems. LaTeX and Beamer make this easy, but the PDF file format limits the use of video, transitions and other useful capabilities on some platforms.
Prezi is a relatively new web-based presentation tool that provides an easy way to give your audience powerful visual cues on how your speech fits together. Figure 1 shows a Prezi presentation on audio/visual tools that members of a Toastmasters club should consider mastering.
Human Factors and Prezi Presentation Design
As the speaker moves along the path through a Prezi presentation, the audience sees the whole presentation, and where a particular topic fits. With Prezi, it is important to use good design–remember that the eye for western readers moves left to right, top to bottom and clockwise from a logical perspective. Early in my career, I wrote a set of network configuration instructions that were tested in a human factors lab. The diagram and procedure started in the upper right and each successive step moved counter-clockwise; the test subjects were unable to complete the configuration. I reorganized the procedure to start in the upper left with each step moving clockwise; the test subjects finished the configuration smoothly and quickly.
If you show a path that does not necessarily fit this progression, make sure that it is at least clear. Note that the presentation in Figure 1 starts at the upper left, moves down, then moves to the right before finally moving upward. Although the overall movement is counter-clockwise, the initial point and subsequent moves are logical and it does not jump around. Note that some of this is language and culture sensitive; know your audience.
- Details
- Written by Bruce Moore
- Hits: 3024

SSL for Small Business Owners
Google has begun penalizing unencrypted web sites in search results. Although a 1% penalty may not sound like a lot, it can mean the difference between being the last link on page 1, and the first link on page 2 of search results, and that difference can cost small business owners a lot of lost business. This started in 2014, and in the Chrome browser beginning on January 10, 2017, Google is adding visual penalties for data entry on unencrypted sites.
Most large website operators are somewhere on the road to implementing encryption using Secure Sockets Layer (SSL)–also known as HTTPS–on their web sites, but many small web site operators see no need to go through the effort of converting to SSL. There are fundementally four reasons to make the switch:
- HTTPS can help end users to identify a spoofing attack.
- HTTPS can help prevent man-in-the middle attacks.
- HTTPS web sites will be favored in Google page ranks. This started in 2014
- Unencrypted sites will start to get visual penalties in Chrome beginning on January 10, 2017, and eventually in search results.
While purchasing the SSL certificates needed to implement website encryption used to be quite expensive, a number of changes in the last year have made it possible to install free domain verification (DV) certificates that are sufficient for most small business. In most cases you can get most of this done with a call to your hosting firm and a call to your site designer.
What to Say to Your Hosting Firm
When you call techical support at your hosting firm, you should ask them to configure “AutoSSL” and a free domain verification certificate. If they do not have AutoSSL available, ask them when they plan to enable it. If they don’t have it and don’t have plans, find another hosting firm. In most cases, they will configure AutoSSL to use certificates from Comodo and sometimes from Let’s Encrypt. Either one is fine.
Your hosting firm may try to upsell you to get an organizational verification (OV) or enhanced verification (EV) certificate. From an encryption standpoing, DV, OV and EV certificates are essentially the same. OV and EV certificates display the name of the business in the URL bar of some browsers–compare the Bank of America web site to this website. That is what the cost of an EV certificate buys you at a significant price. An OV certificate is in between, and only shows the ownership information if someone clicks on the certficate information. Only geeky people like me do that. Software development firms frequently get OV certificates as part of a package with code signing certificates, which require the expense of an organizational verification; these firms have to go through the OV process, and essentially get the OV web certificates as a biproduct of getting code-signing certificates. Most businesses only need a free DV certificate.
You may need to pay for a private IP address, which usually costs about $50/year. This has the added advantage that if another web site on your server (same IP address) gets compromized and starts sending spam email, your email domain will not be blacklisted just because you have the same IP address. The requirement for a private IP address is a techical restriction that will go away later this year but which hosting firms may not change as it gives them more money.
What to Say to Your Site Designer
Tell your site designer to configure your site to force traffic to use SSL. If your site runs Joomla, this is literally just checking a box. If your site runs Wordpress, you will need to manually update your .htaccess
file. This will take most site designers about 10 minutes, unless there is something unusual about your site, or it is on a hosting firm that runs something other than CPanel with Wordpress or Joomla. If your site designer cannot do this, you should negotiate lower hourly rates or find a new designer.
Do It Yourself
If you are fairly technical, you can do this yourself by following the instructions in Why and How to Set Up SSL/HTTPS on Your Web Site.
- Details
- Written by Bruce Moore
- Hits: 2282