{ "cells": [ { "cell_type": "markdown", "id": "247bbf84", "metadata": {}, "source": [ "# Split-apply-combine operations for tabular data" ] }, { "cell_type": "code", "execution_count": 1, "id": "44584190", "metadata": {}, "outputs": [], "source": [ "import pandas as pd" ] }, { "cell_type": "code", "execution_count": 2, "id": "ba193f3f", "metadata": {}, "outputs": [ { "data": { "text/html": [ "
\n", " | subject_id | \n", "condition_id | \n", "response_time | \n", "response | \n", "
---|---|---|---|---|
0 | \n", "312 | \n", "A1 | \n", "0.12 | \n", "LEFT | \n", "
1 | \n", "312 | \n", "A2 | \n", "0.37 | \n", "LEFT | \n", "
2 | \n", "312 | \n", "C2 | \n", "0.68 | \n", "LEFT | \n", "
3 | \n", "313 | \n", "A1 | \n", "0.07 | \n", "RIGHT | \n", "
4 | \n", "313 | \n", "B1 | \n", "0.08 | \n", "RIGHT | \n", "
5 | \n", "314 | \n", "A2 | \n", "0.29 | \n", "LEFT | \n", "
6 | \n", "314 | \n", "B1 | \n", "0.14 | \n", "RIGHT | \n", "
7 | \n", "314 | \n", "C2 | \n", "0.73 | \n", "RIGHT | \n", "
8 | \n", "711 | \n", "A1 | \n", "4.01 | \n", "RIGHT | \n", "
9 | \n", "712 | \n", "A2 | \n", "3.29 | \n", "LEFT | \n", "
10 | \n", "713 | \n", "B1 | \n", "5.74 | \n", "LEFT | \n", "
11 | \n", "714 | \n", "B2 | \n", "3.32 | \n", "RIGHT | \n", "