Participant Codes and Tracking

Overview

PEBL allows you to track participants using unique participant codes. This guide explains the different ways to assign and track participant IDs in your studies.


Automatic Participant Numbering (Recommended for Most Studies)

What it does: PEBL automatically assigns sequential participant numbers (1, 2, 3, etc.) as participants complete your study.

When to use:

  • Online studies with anonymous participants
  • Mass data collection (Prolific, MTurk, etc.)
  • When you don't need to pre-assign specific IDs
  • Studies where the exact participant ID doesn't matter

How it works:

  1. Enable "Automatic Participant Numbering" toggle in your study settings
  2. Share your study URL (no participant code needed)
  3. Each participant gets the next available number automatically
  4. Data files are saved with their assigned number
Advantages:
  • Simple - just one URL to share
  • No risk of duplicate IDs
  • Works great with QR codes
  • Ideal for anonymous online studies

Example:

Study URL: http://peblhub.online/runtime/pebl-launcher.html?test=stroop&token=STUDY<em>ABC123

First participant gets ID: 1 Second participant gets ID: 2

Third participant gets ID: 3

Manual Participant Codes (For Specific IDs)

What it does: You provide a specific participant code that gets included in the URL.

When to use:

  • Laboratory studies with pre-assigned IDs
  • Studies requiring specific participant identifiers
  • Longitudinal studies (same participant, multiple sessions)
  • When you need to match data with other systems

How to set it up:

  1. In your study's Manage Study page, find the "Participant Code" input field
  2. Enter the specific participant ID (e.g., "SUBJ001", "P42", "smithjohn")
  3. The URL updates to include &participant=SUBJ001
  4. Copy the updated URL or QR code for that specific participant
  5. Data files are saved with this exact participant code
Important notes:
  • Each participant needs a unique URL with their code
  • You're responsible for ensuring codes are unique
  • Codes can contain letters, numbers, hyphens, and underscores
  • Avoid special characters or spaces
  • Codes that get re-used may cause problems within the PEBL test if used multiple times by the same participant (asking for them to enter a new code or

Example:

Base URL: https://peblhub.online/runtime/pebl-launcher.html?test=stroop&token=STUDY<em>ABC123

For participant SUBJ001: ...&participant=SUBJ001

For participant SUBJ002: ...&participant=SUBJ002

Workflow:

  1. Create a spreadsheet with your participant IDs
  2. For each participant:
  • Enter their ID in the Participant Code field
    • Generate and copy the URL or QR code
    • Send it to that specific participant
3. Clear the field and repeat for the next participant

Self-Generated Codes (For Anonymous Credit Systems)

What it does: Participants create and enter their own anonymous code at the start of the study, which is used to track their data while maintaining anonymity.

When to use:

  • Studies requiring anonymous data collection
  • Course credit systems where participants need a code to claim credit
  • When participants must be able to prove they completed the study without linking identity to data
  • IRB requirements for complete anonymity

How it works:

  1. Participant visits a special entry page: enter-code.php?chain=CHAINXXX&token=STUDYXXX
  2. They create their own unique code (e.g., "smithj42")
  3. Code is validated (3-20 characters, letters/numbers/hyphens/underscores only)
  4. They're automatically redirected to the chain with their code
  5. Data is saved with that code
  6. Later, they submit the same code to a separate credit form (which doesn't link to the actual data)
Code requirements:
  • 3-20 characters
  • Letters, numbers, hyphens, underscores only
  • No spaces or special characters
  • Cannot be generic words like "test" or "demo"
  • No consecutive hyphens or underscores

Example URL for participants:

https://peblhub.online/public/enter-code.php?chain=CHAIN</em>01E1A4&token=STUDY<em>ABC123

Advantages:

  • Complete anonymity - no way to link participant identity to data
  • Participants control their own code
  • Simple for credit systems (they remember their code to claim credit)
  • No pre-registration or manual work needed
  • Works well for course-based studies

Important considerations:

  • Collision risk: Two participants might choose the same code
    • Encourage unique codes (name + initials + number)
    • Teach participants to use: lastnameinitialsnumber format
    • Example: "smithjd42" instead of just "test" or "123"
  • No collision detection: The system doesn't prevent duplicate codes
  • Participant responsibility: They must remember their code to claim credit

Best practices to minimize collisions:

  • Provide clear examples: "lastnameinitialsnumber" (e.g., "jonesab7")
  • Suggest they include multiple identifiers
  • Consider requiring minimum length (e.g., 8 characters)
  • Instruct participants to avoid simple codes like "test", "12345", etc.

Setting up for researchers:

  1. In Manage Study, look for the chain you want to use
  2. Instead of sharing the regular chain URL, share the enter-code URL:
   https://peblhub.online/public/enter-code.php?chain=YOUR</em>CHAIN<em>ID&token=YOUR</em>TOKEN

``

  1. Participants will be prompted to enter their code before starting
  2. Set up a separate form (Google Forms, Qualtrics, etc.) where they submit the same code for credit
  3. You can verify completion by checking if data files exist with that code
<strong>For credit verification:</strong>
  • Create a simple form asking: "What was your participant code?"
  • Check your data directory for files containing that code
  • If files exist with that code, grant credit
  • This maintains anonymity (form and data are separate)

<h2>Platform Integration Variables (Prolific, MTurk, etc.)</h2>

<strong>What it does:</strong> Uses variables from recruitment platforms to automatically capture participant IDs from those platforms.

<strong>Supported platforms:</strong>

  • <strong>Prolific:</strong> {{%PROLIFIC<em>PID%}}
  • <strong>MTurk:</strong> {{assignmentId}}
  • <strong>SONA:</strong> Custom participant variable
  • <strong>Qualtrics:</strong> Custom embedded data

<strong>How to use with Prolific:</strong>

  1. Copy your study URL
  2. In Prolific, add your study URL
  3. Prolific automatically replaces {{%PROLIFIC</em>PID%}} with each participant's actual Prolific ID
  4. PEBL receives and saves data with the Prolific ID
<strong>Example:</strong>

Your URL: https://peblhub.online/runtime/pebl-launcher.html?test=stroop&token=STUDYABC123&participant={{%PROLIFICPID%}} Prolific transforms it to: ...&participant=5f8a3b2c1d9e4f6g7h8i


<strong>Advantages:</strong>

  • Automatic - no manual work needed
  • Guaranteed unique IDs from the platform
  • Easy to match data with platform payments
  • Works for hundreds or thousands of participants

<strong>Important:</strong> Use the platform's exact variable format - don't modify it!


<h2>Test Chains with Automatic Numbering</h2>

<strong>What it does:</strong> For test chains (multiple tests in sequence), you can enable automatic numbering so each participant gets a unique number across all tests in the chain.

<strong>How to enable:</strong>

  1. Go to Manage Study
  2. Find your test chain
  3. Toggle "Automatic Participant Numbering" ON for that chain
  4. Share the chain URL
<strong>How it works:</strong>
  • First participant to start the chain gets ID: 1
  • Their ID stays "1" for ALL tests in that chain
  • Second participant gets ID: 2 across all chain tests
  • And so on...

<strong>Without automatic numbering:</strong>

  • You must include &participant={PARTICIPANT<em>ID} in the chain URL
  • Replace {PARTICIPANT</em>ID} with each participant's actual ID

<h2>Short URLs for Participant Codes</h2>

<strong>What it does:</strong> Creates short, memorable URLs that include participant codes.

<strong>When to use:</strong>

  • Emailing participants with specific IDs
  • Printing URLs for laboratory sessions
  • Making URLs easier to type or remember

<strong>How to use:</strong>

  1. Enter a participant code in the Participant Code field
  2. Click "🔗 Short URL" button
  3. A shortened URL is generated (e.g., https://peblhub.online/s/Ct4Xpa4)
  4. Copy and share this short URL
  5. It redirects to the full URL with that participant code
<strong>Important:</strong>
  • If you change the participant code, the old short URL becomes outdated
  • Generate a new short URL after changing the participant code
  • Short URLs are permanent - they don't expire

<h2>Data File Naming</h2>

Participant codes appear in your data filenames:

<strong>Individual tests:</strong>

stroop-SUBJ001-2024-10-30-14-30-45.csv stroop-42-2024-10-30-14-35-22.csv


<strong>Test chains:</strong>

stroop-SUBJ001-2024-10-30-14-30-45.csv nback-SUBJ001-2024-10-30-14-32-10.csv (same participant ID across all tests in the chain) ``


Best Practices

For Anonymous Online Studies:

✅ Use Automatic Participant Numbering ✅ Share one URL for everyone ✅ Let PEBL handle the numbering

For Laboratory Studies:

✅ Use Manual Participant Codes ✅ Create a list of codes in advance ✅ Generate individual URLs/QR codes for each session

For Platform Studies (Prolific/MTurk):

✅ Use platform variables in your URL ✅ Let the platform handle participant IDs ✅ No manual work needed

For Longitudinal Studies:

✅ Use the same participant code for all sessions ✅ Add a session identifier if needed (e.g., "SUBJ001T1", "SUBJ001T2") ✅ Keep a master list of participant codes


Troubleshooting

Problem: Two participants got the same ID

  • Cause: Automatic numbering was off, and they used the same URL without participant codes
  • Solution: Enable Automatic Participant Numbering, or use Manual Participant Codes with unique IDs

Problem: Can't find participant's data

  • Check: What participant code was used in their URL?
  • Check: Look for data files with that code in the filename
  • Check: Verify the study token matches

Problem: Participant code has weird characters

  • Cause: Special characters or spaces in the participant code field
  • Solution: Use only letters, numbers, hyphens, and underscores

Problem: Platform variable didn't work

  • Cause: Variable format was wrong or not supported by the platform
  • Solution: Check the platform's documentation for the exact variable format

Summary Table

MethodBest ForSetup DifficultyUnique IDs?
Automatic NumberingOnline studies, anonymousEasy ⭐Yes
Self-Generated CodesCourse credit, anonymityEasy ⭐Participant ensures
Manual CodesLab studies, specific IDsMedium ⭐⭐You ensure
Platform VariablesProlific, MTurk, SONAEasy ⭐Yes
Short URLsEasy sharing, emailMedium ⭐⭐Depends on method

Need Help?

If you have questions about participant codes or need help setting up your study, contact your PEBL administrator or consult the platform documentation.