# MATLAB for Neuroscientists

## 2nd Edition

### An Introduction to Scientific Computing in MATLAB

**Authors:**Pascal Wallisch Michael Lusignan Marc Benayoun Tanya Baker Adam Dickey Nicholas Hatsopoulos

**Hardcover ISBN:**9780123838360

**eBook ISBN:**9780123838377

**Imprint:**Academic Press

**Published Date:**1st November 2013

**Page Count:**570

## Description

*MATLAB for Neuroscientists* serves as the only complete study manual and teaching resource for MATLAB, the globally accepted standard for scientific computing, in the neurosciences and psychology. This unique introduction can be used to learn the entire empirical and experimental process (including stimulus generation, experimental control, data collection, data analysis, modeling, and more), and the 2nd Edition continues to ensure that a wide variety of computational problems can be addressed in a single programming environment.

This updated edition features additional material on the creation of visual stimuli, advanced psychophysics, analysis of LFP data, choice probabilities, synchrony, and advanced spectral analysis. Users at a variety of levels—advanced undergraduates, beginning graduate students, and researchers looking to modernize their skills—will learn to design and implement their own analytical tools, and gain the fluency required to meet the computational needs of neuroscience practitioners.

## Key Features

- The first complete volume on MATLAB focusing on neuroscience and psychology applications
- Problem-based approach with many examples from neuroscience and cognitive psychology using real data
- Illustrated in full color throughout
- Careful tutorial approach, by authors who are award-winning educators with strong teaching experience

## Readership

Undergraduate and graduate students in systems, cognitive, and behavioral neuroscience, cognitive psychology, and related fields, as well as researchers in these fields who use MATLAB

## Table of Contents

Preface to the Second Edition

Preface to the First Edition

About the Authors

How to Use this Book

Structural and Conceptual Considerations

Layout and Style

Companion Web Site

Part I: Fundamentals

Chapter 1. Introduction

Chapter 2. MATLAB Tutorial

2.1 Goal of this Chapter

2.2 Purpose and Philosophy of MATLAB

2.3 Graphics and Visualization

2.4 Function and Scripts

2.5 Data Analysis

2.6 A Word on Function Handles

2.7 The Function Browser

2.8 Summary

MATLAB Functions, Commands, and Operators Covered in This Chapter

Chapter 3. Mathematics and Statistics Tutorial

3.1 Introduction

3.2 Linear Algebra

3.3 Probability and Statistics

MATLAB Functions, Commands, and Operators Covered in This Chapter

Chapter 4. Programming Tutorial: Principles and Best Practices

4.1 Goals of this Chapter

4.2 Organizing Code

4.3 Organizing More Code: Bigger Projects

4.4 Taming Errors

MATLAB Functions, Commands, and Operators Covered in This Chapter

Chapter 5. Visualization and Documentation Tutorial

5.1 Goals of This Chapter

5.2 Visualization

5.3 Documentation

MATLAB Functions, Commands, and Operators Covered in This Chapter

Part II: Data Collection with MATLAB

Chapter 6. Collecting Reaction Times I: Visual Search and Pop Out

6.1 Goals of this Chapter

6.2 Background

6.3 Exercises

6.4 Project

MATLAB Functions, Commands, and Operators Covered in this Chapter

Chapter 7. Collecting Reaction Times II: Attention

7.1 Goals of this Chapter

7.2 Background

7.3 Exercises

7.4 Project

MATLAB Functions, Commands, and Operators Covered in this Chapter

Chapter 8. Psychophysics

8.1 Goals of this Chapter

8.2 Background

8.3 Exercises

8.4 Project

MATLAB Functions, Commands, and Operators Covered in this Chapter

Chapter 9. Psychophysics with GUIs

Abstract

9.1 Goals of This Chapter

9.2 Introduction and Background

9.3 GUI Basics

9.4 Using a GUI to Track an IP Address

9.5 Using a GUI for Psychophysics

9.6 Project

MATLAB Functions, Commands, and Operators Covered in This Chapter

Chapter 10. Signal Detection Theory

10.1 Goals of This Chapter

10.2 Background

10.3 Exercises

10.4 Project

MATLAB Functions, Commands, and Operators Covered in This Chapter

Part III: Data Analysis with MATLAB

Chapter 11. Frequency Analysis Part I: Fourier Decomposition

11.1 Goals of this Chapter

11.2 Background

11.3 Exercises

11.4 Project

MATLAB Functions, Commands, and Operators Covered in this Chapter

Chapter 12. Frequency Analysis Part II: Nonstationary Signals and Spectrograms

12.1 Goal of this Chapter

12.2 Background

12.3 Exercises

12.4 Project

MATLAB Functions, Commands, and Operators Covered in this Chapter

Chapter 13. Wavelets

13.1 Goals of This Chapter

13.2 Background

13.3 Exercises

13.4 Project

MATLAB Functions, Commands, and Operators Covered in This Chapter

Chapter 14. Introduction to Phase Plane Analysis

14.1 Goal of this Chapter

14.2 Background

14.3 Exercises

14.4 Project

MATLAB Functions, Commands, and Operators Covered in this Chapter

Chapter 15. Exploring the Fitzhugh-Nagumo Model

15.1 Goal of this Chapter

15.2 Background

15.3 Exercises

15.4 Project

MATLAB Functions, Commands, and Operators Covered in this Chapter

Chapter 16. Convolution

16.1 Goals of this Chapter

16.2 Background

16.3 Exercises

16.4 Project

MATLAB Functions, Commands, and Operators Covered in this Chapter

Chapter 17. Neural Data Analysis I: Encoding

17.1 Goals of this Chapter

17.2 Background

17.3 Exercises

17.4 Project

MATLAB Functions, Commands, and Operators Covered in this Chapter

Chapter 18. Neural Data Analysis II: Binned Spike Data

18.1 Goals of this Chapter

18.2 Background

18.3 Exercises

18.4 Project

MATLAB Functions, Commands, and Operators Covered in this Chapter

Chapter 19. Principal Components Analysis

19.1 Goals of this Chapter

19.2 Background

19.3 Exercises

19.4 Project

MATLAB Functions, Commands, and Operators Covered in this Chapter

Chapter 20. Information Theory

20.1 Goals of this Chapter

20.2 Background

20.3 Exercises

20.4 Project

MATLAB Functions, Commands, and Operators Covered in This Chapter

Chapter 21. Neural Decoding I: Discrete Variables

21.1 Goals of this Chapter

21.2 Background

21.3 Exercises

21.4 Project

MATLAB Functions, Commands, and Operators Covered in this Chapter

Chapter 22. Neural Decoding II: Continuous Variables

22.1 Goals of This Chapter

22.2 Background

22.3 Exercises

22.4 Project

MATLAB Functions, Commands, and Operators Covered in This Chapter

Chapter 23. Local Field Potentials

23.1 Goals of This Chapter

23.2 Background

23.3 Exercises

23.4 Project

MATLAB Functions, Commands, and Operators Covered in this Chapter

Chapter 24. Functional Magnetic Resonance Imaging

24.1 Goals of This Chapter

24.2 Background

24.3 Exercises

24.4 Project

MATLAB Functions, Commands, and Operators Covered in This Chapter

Part IV: Data Modeling with MATLAB

Chapter 25. Voltage-Gated Ion Channels

25.1 Goal of This Chapter

25.2 Background

25.3 Exercises

25.4 Project

Matlab Functions, Commands, and Operators Covered in This Chapter

Chapter 26. Synaptic Transmission

26.1 Goals of This Chapter

26.2 Background

26.3 Exercises

26.4 Project

MATLAB Functions, Commands, and Operators Covered in This Chapter

Chapter 27. Modeling a Single Neuron

27.1 Goal of This Chapter

27.2 Background

27.3 Exercises

27.4 Project

MATLAB Functions, Commands, and Operators Covered in This Chapter

Chapter 28. Models of the Retina

28.1 Goal of This Chapter

28.2 Background

28.3 Exercises

28.4 Project

MATLAB Functions, Commands, and Operators Covered in This Chapter

Chapter 29. Simplified Model of Spiking Neurons

29.1 Goal of This Chapter

29.2 Background

29.3 Exercises

29.4 Project

MATLAB Functions, Commands, and Operators Covered in This Chapter

Chapter 30. Fitzhugh-Nagumo Model: Traveling Waves

30.1 Goals of This Chapter

30.2 Background

30.3 Exercises

30.4 Project

MATLAB Functions, Commands, and Operators Covered in This Chapter

Chapter 31. Decision Theory

31.1 Goals of this Chapter

31.2 Background

31.3 Simple Accumulation of Evidence

31.4 Free Response Tasks

31.5 Multiple Iterators: The Race Model

31.6 Cortical Models

31.7 Project

MATLAB Functions, Commands, and Operators Covered in this Chapter

Chapter 32. Markov Models

32.1 Goal of this Chapter

32.2 Introduction

32.3 Finding the Most Probable Path: The Viterbi Algorithm

32.4 Hidden Markov Models

32.5 Training an HMM: The Baum-Welch Algorithm

32.6 A Simple Example

32.7 Project

MATLAB Functions, Commands, and Operators Covered in This Chapter

Chapter 33. Modeling Spike Trains as a Poisson Process

33.1 Goals of this Chapter

33.2 Background

33.3 The Bernoulli Process: Events in Discrete Time

33.4 The Poisson Process: Events in Continuous Time

33.5 Picking Random Variables Without the Statistics Toolbox

33.6 Non-Homogeneous Poisson Processes: Time-Varying Rates of Activity

33.7 Project

MATLAB Functions, Commands, and Operators Covered in This Chapter

Chapter 34. Exploring the Wilson-Cowan Equations

34.1 Goal of This Chapter

34.2 Background

34.3 The Model

34.4 Exercises

34.5 Projects

MATLAB Functions, Commands, and Operators Covered in This Chapter

Chapter 35. Neural Networks as Forest Fires: Stochastic Neurodynamics

35.1 Goals of This Chapter

35.2 Background

35.3 Exercises

35.4 Projects

MATLAB Functions, Commands, and Operators Covered in This Chapter

Chapter 36. Neural Networks Part I: Unsupervised Learning

36.1 Goals of This Chapter

36.2 Background

36.3 Exercises

36.4 Project

MATLAB Functions, Commands, and Operators Covered in This Chapter

Chapter 37. Neural Networks Part II: Supervised Learning

37.1 Goals of This Chapter

37.2 Background

37.3 Exercises

37.4 Project

MATLAB Functions, Commands, and Operators covered in This Chapter

Appendix A. Creating Publication-Quality Figures

A.1 Introduction

A.2 Figure Makeovers

A.3 Saving Figures in the Desired Format

A.4 How to Make Animated GIFs

MATLAB Functions, Commands, and Operators Covered in This Appendix

Appendix B. Relevant Toolboxes

B.1 The Concept of Toolboxes

B.2 Neural Network Toolbox

B.3 Parallel Computing Toolbox

B.4 Statistics Toolbox

B.5 MATLAB Compiler

B.6 Database Toolbox

B.7 Signal Processing Toolbox

B.8 Data Acquisition Toolbox

B.9 Image Processing Toolbox

B.10 Psychophysics Toolbox and MGL

B.11 Chronux

B.12 Mathworks File Exchange

References

Index

## Details

- No. of pages:
- 570

- Language:
- English

- Copyright:
- © Academic Press 2014

- Published:
- 1st November 2013

- Imprint:
- Academic Press

- eBook ISBN:
- 9780123838377

- Hardcover ISBN:
- 9780123838360

## About the Author

### Pascal Wallisch

Pascal Wallisch received his PhD from the University of Chicago, did postdoctoral work at the Center for Neural Science at New York University, and currently serves as a clinical assistant professor of Psychology at New York University. His research interests are at the intersection of Psychology and Neuroscience, specifically Cognitive and Computational Neuroscience. His current work focuses on motion perception, autism and the appraisal of film.

### Affiliations and Expertise

New York University, NY, USA

### Michael Lusignan

### Affiliations and Expertise

The University of Chicago, IL, USA

### Marc Benayoun

### Affiliations and Expertise

The University of Chicago, IL, USA

### Tanya Baker

### Affiliations and Expertise

The Salk Institute for Biological Studies, La Jolla, CA, USA

### Adam Dickey

### Affiliations and Expertise

The University of Chicago, IL, USA

### Nicholas Hatsopoulos

### Affiliations and Expertise

The University of Chicago, IL, USA

## Reviews

"...a handy resource for instructors of neuroscience, particularly those interested in more intense data analysis and/or neural modeling."

*“The book is clear, cogent, and systematic. It provides much more than the essential nuts-and-bolts—it also leads the reader to learn to think about the empirical enterprise writ large…This book should be given a privileged spot on the bookshelf of every teacher, student, and researcher in the behavioral and cognitive sciences.” —Stephen M. Kosslyn,* John Lindsley Professor of Psychology, Dean of Social Science, Harvard University, Cambridge, MA, USA

*“This is an excellent book that should be on the desk of any neuroscientist or psychologist who wants to analyze and understand his or her own data by using MATLAB…Several books with MATLAB toolboxes exist; I find this one special both for its clarity and its focus on problems related to neuroscience and cognitive psychology.” —Nikos Logothetis,* Director, Max Planck Institute for Biological Cybernetics, Tübingen, Germany

*“MATLAB for Neuroscientists provides a unique and relatively comprehensive introduction to the MATLAB programming language in the context of brain sciences…The book would work well as a supplementary source for an introductory course in computational analysis and modeling in visual neuroscience, for graduate students or advanced undergraduates.” —Eero P. Simoncelli,* Investigator, Howard Hughes Medical Institute; Professor, Neural Science, Mathematics, and Psychology, New York University, New York, USA