M2C2 logo

M2C2 DataKit Notebook Overview

1. Purpose

Enable researchers to plug in data from varied sources (e.g., Qualtrics, MetricWire, MongoDB, CSV bundles) and apply a consistent pipeline for:


2. Inspired by

LASSIE workflow graphic
StepMethodPurpose
Lload()Load raw data from a supported source (e.g., MongoDB, UAS, MetricWire).
Aassure()Validate that required columns exist before processing.
Sscore()Apply scoring logic based on predefined or custom rules.
Ssummarize()Aggregate scored data by participant, session, or custom groups.
Iinspect()Visualize distributions or pairwise plots for quality checks.
Eexport()Save scored and summarized data to tidy files and optionally metadata.

3. Before you begin: Installations and Helpful Guides

Please note that this guide is set up for using Python with Visual Studio Code. You are welcome to use other tools; however, the M2C2 team cannot provide guidance for all available tools.

1. Installs

Python: https://www.python.org/

Python download page

Visual Studio Code: https://code.visualstudio.com/download

Python and Jupyter extensions for VS Code

2. Helpful Setup Guides

Python download page:

Getting started with Python in Visual Studio Code:

Jupyter notebooks in Visual Studio Code:


4. Getting Started

Once Python and Visual Studio Code are installed, you can begin running the notebook.

1. Move all files to a single folder location

2. Open the notebook in Visual Studio Code.

3. Select a Kernel


5. Running the Notebook

Run the Code Blocks

Best Practices

Editing your file path

To easily copy your file path, follow the steps outlined below:

Important information for the file path:

A Special Note on MetricWire

You must edit your file path so that it points to the folder where your MetricWire exported data are located. It is best practice to move the data to the same folder as the notebook. Note that the data folder must be unzipped.

Example unzipped MetricWire folder
MetricWire downloaded folder structure

7. Accessing your Data

Your export will be located in the same folder as the Jupyter notebook named ‘tidy_m2c2_export’.


8. FAQs

I am getting error messages and cannot move forward - what should I do?

Windows pathing uses backslashes (e.g., C:\Users\Name\data). Because Python interprets backslashes as special characters, this often breaks. You have three options:

  1. Swap backslashes to forward slashes: "C:/Users/Name/data/my_dataset.csv"
  2. Use double backslashes: "C:\\Users\\Name\\data\\my_dataset.csv"
  3. Put an r in front of the string (raw string): r"C:\Users\Name\data\my_dataset.csv"

If you have other questions, please complete the Question & Issue Form to submit an inquiry. You can also contact us at m2c2@psu.edu.