Skip to content
Getting Started

Getting Started

What is CLS-Stats?

This online User Guide describes CLS-Stats, an add-in for Excel. It is a collection of statistical functions and procedures meant for scientific data analysis, particularly in the field of chemistry.

The main part of the add-in is a collection of Excel lambda functions that can be copied to any workbook and shared with others, who can use the functions even if they do not have the add-in installed. While the add-in has some features that make managing the lambda functions easier (such as updating to the latest version), it is actually not necessary to install the add-in to use the functions. The functions are shared in a public GitHub gist. Other add-ins, such as Microsoft’s Excel Labs, can be used to download and install the functions as named lambda functions.

Regardless of how you use them, this User Guide documents the use and the source code of the functions. Of course the VBA macros are only available to you if you install the CLS-Stats add-in, using the instructions below.

Installation Instructions

Installation essentially means downloading the add-in and telling Excel to add it; details are below. You can also watch the video below if you prefer. (Note: the video instructs you to “Trust access to VBA project object model”. That is no longer necessary since add-in macros no longer call Excel’s Solver.)

Windows PCs

  1. Download the file from Box: the filename is CLS_Stats.xlam.
  2. Important: create a folder in a memorable place and move the downloaded file there. You may need to find this folder several months from now so don’t just throw it anywhere.
  3. Open Excel. This should be a relatively recent version: Excel version 2208 or later (Win) or 16.65 or later (Mac).
  4. Display the Developer ribbon (if not already enabled)
    • right-click on the Home tab (ie for the Home Ribbon)
    • select “Customize the ribbon”
    • in the lists on the right, ensure that “Developer” is checked.
  5. In the Developer ribbon, click on “Macro Security”
    • the Trust Center appears. Click “Trusted Locations” and then add the folder containing the add-in as a trusted location.
  6. Now we install the add-in. Click the “Excel Add-ins” button on the Developer ribbon.
    • Click “Browse” and then find where you stored the add-in and select the file, then click OK.
    • A dialog box will pop up asking if you want to copy the file to the AddIns folder. Click NO. It isn’t the end of the world if you accidentally click “Yes” (it is the default option) but it means you will have two copies of the add-in and it sometimes causes problems.
  7. Go back to the Home ribbon. If the add-in is installed then you should see the CLS-Stats group of items on the ribbon (towards the right side).
    • as a further check: type Ctrl-Shift-H and a help window should appear
  8. Very final check: close and re-open Excel and make sure the CLS-Stats items are still on the Home ribbon.

Macs

  1. Download the file from Box: the filename is CLS_Stats.xlam.
  2. Important: create a folder in a memorable place and move the downloaded file there. You may need to find this folder several months from now so don’t just throw it anywhere.
  3. Open Excel. This should be a relatively recent version: Excel version 2208 or later (Win) or 16.65 or later (Mac).
  4. Display the Developer ribbon (if not already enabled)
    • Go to Excel →\to Settings (or type CMD-,)
    • select “Ribbon & Toolbar”
    • in the lists on the right, ensure that “Developer” is checked.
  5. Now we install the add-in. Click the “Excel Add-ins” button on the Developer ribbon.
    • Click “Browse” and then find where you stored the add-in and select the file, then click OK.
    • There is a chance that some windows will appear asking that you grant access to the file and you will need to do so. This is just macOS doing security things since it is a downloaded file.
  6. Go back to the Home ribbon. If the add-in is installed then you should see the CLS-Stats group of items on the ribbon (towards the right side).
    • as a further check: type Ctrl-Shift-H and a help window should appear
  7. Very final check: close and re-open Excel and make sure the CLS-Stats items are still on the Home ribbon.