• Linear / nonlinear time series analysis
• Uni- / Bivariate (Synchronization)
• Continuous / discrete time series
• Exemplary application to medical data - EEG and neuronal recordings - Epilepsy (“window to the brain”)
6 lectures of 2 hours: Thu, May 12 – Tue, May 31, 2016
Thomas Kreuz (ISC-CNR) ([email protected]; http://www.fi.isc.cnr.it/users/thomas.kreuz/)
Time series analysis
Computa1onal Neuroscience Group Ins$tute for Complex Systems (ISC), Na$onal Research Council (CNR)
Sesto Fioren$no, Florence, Italy
Data Analysis Thomas Kreuz (PI)
Complex networks Alessandro Torcini (PI)
Mario Mulansky (Postdoc)
Nebojsa Bozanic (PhD student)
Stefano Luccioli (Researcher)
Simona Olmi (Researcher)
David Angulo (Postdoc)
Eero Raisanen (PhD student)
Irene Malves$o (PhD student)
Collaborators at UniFi (COSMOS): Roberto Livi, Duccio Fanelli, Clement Zankoc
Schedule: Thu May 12 Tue May 17 Thu May 19 16:30(+10) - 18:00 Tue May 24 Thu May 26 Tue May 31
Location: CNR, Building F, Room 1 (above the mensa)
Except Tue May 24 & Thu May 26: CNR, Building B, Room 173 (first floor, above the portineria)
Lecture slides will be on my homepage!
Organiza1on
• Introduction to Time Series Analysis • Univariate: Measures for individual time series - Linear time series analysis: Autocorrelation, Fourier spectrum - Non-linear time series analysis: Entropy, Dimension, Lyapunov exponent • Bivariate: Measures for two time series - Measures of synchronization for continuous data (e.g., EEG) cross correlation, coherence, mutual information, phase synchronization, non-linear interdependence - Measures of directionality: Granger causality, transfer entropy - Measures of synchronization for discrete data (e.g., spike trains): Victor-Purpura distance, van Rossum distance, event synchronization, ISI-distance, SPIKE-distance, SPIKE-Synchronization - Measures of directionality: SPIKE-Order • Multivariate: Measures of synchronization for multi-neuron data • Applications to electrophysiological signals (in particular single-unit data and EEG from epilepsy patients) Epilepsy – “window to the brain”
+ Excursions
This lecture series
• Lecture 1: Example (Epilepsy & spike train synchrony), Data acquisition, Dynamical systems
• Lecture 2: Linear measures, Introduction to non-linear dynamics
• Lecture 3: Non-linear measures
• Lecture 4: Measures of continuous synchronization
• Lecture 5: Measures of discrete synchronization (spike trains)
• Lecture 6: Measure comparison & Application to epileptic seizure prediction
(Preliminary) Schedule
• H. Kantz, T. Schreiber: Nonlinear Time Series Analysis Cambridge University Press, Cambridge, 2003
• H. Abarbanel: Analysis of Observed Chaotic Data Springer, 1997.
• A. Pikovsky, M. Rosenblum, J. Kurths: Synchronization. A Universal Concept in Nonlinear Sciences Cambridge University Press, Cambridge, 2001
• PhD thesis Thomas Kreuz (see homepage) http://webarchiv.fz-juelich.de/nic-series//volume21/nic-series-band21.pdf
• Acknowledgements: Lecture series Klaus Lehnertz, University of Bonn Florian Mormann, University of Bonn
[ Literature ]
• General Introduction
• Example: Epileptic seizure prediction
• Data acquisition
• Introduction to dynamical systems
Today’s lecture
• General Introduction
• Example: Epileptic seizure prediction
• Data acquisition
• Introduction to dynamical systems
Today’s lecture
Aim of 1me series analysis
Knowledge
detail
expand Future (Prediction)
Past (Analysis)
Examples: - Compact description of data Simplified Model - Interpretation Seasonal regularities - Hypothesis testing Global warming
- Forecasting Weather, stock market - Control Avoid outliers - Simulation Estimate probability of
catastrophic events
Data (especially 1me series)
• Meteorology
• Astronomy
• Seismology
• Economy
• …
• Medicine - Cardiology - … - Neurology (Epileptology)
Predic1on of extreme events
• Meteorology: Storms, Tornados, …
• Astronomy: Solar eruptions / sun flares
• Seismology: Earth quakes
• Economy: Stock market crashes, “Black Friday”
• …
• Medicine - Cardiology: Heart attack - … - Neurology: Epileptic seizure
• General Introduction
• Example: Epileptic seizure prediction
• Data acquisition
• Introduction to dynamical systems
Today’s lecture
[Lieberoth WorldPress]
• Electrocardiogram (ECG) - transthoracic measurement of the electrical activity of the heart
• Electromyography (EMG) - electrical activity produced by skeletal muscles
• Electrooculography (EOG) - measures the resting potential of the retina
• Electroretinography (ERG) - electrical responses of various cell types in the retina (including the photoreceptors) to stimuli
• Electronystagmography (ENG) - diagnostic test to record involuntary movements of the eye
• Electrogastrogram (EGG) - electrical signals that travel through the stomach muscles
• Electrocorticogram (ECoG) - electrical activity from the cerebral cortex (brain surface)
• Electroencephalogram (EEG) - voltage fluctuations due to ionic current flows within the neurons of the brain (surface / intracranial)
Medical 1me series
Neurophysiological measurement techniques Method Measurement device Principle What is actually measured? Temporal resolution Spatial resolution Pros Cons
Surface EEG (Scalp) Scalp electrodes Extracellular potential mostly EPSPs and IPSPs, smaller excellent, 1 ms poor (spatially smoothed non-invasive Distortionin amplitude but long-lasting average behavior) Artefactsspikes cancel out (very short, ~10 cm^2 surfacelowpass-filtered) ~r^4 (no depth)
ECoG (Brain surface) Subdural grid electrodes Extracellular potential Exception: Population spikes in excellent, 1 ms much better localization invasive (epilepsy)epileptic seiures (high synchrony)
Intracranial EEG Depth electrodes Extracellular potential same as above excellent, 1 ms even better localization very invasive (epilepsy)brain damage
MEG SQUID (at ~ 3 K) Magnetic fields Intracellular currents excellent, 1 ms < 1 cm, up to 1 mm non-invasive source localization superconductive loop + (complementary to EEG) better than EEG no contact still not very accurate2 Josephson junctions no distortion
MRI Receiver coil Disturbance of magnetic Structure (different tissue, almost none (anatomy) vastly improved non-invasive unspecificHydrogen dipoles via different amount of water) expensiveshort RF energy pulses No neuronal activity inconvenient
fMRI Receiver coil BOLD-effect Metabolism (Energy Production) very slow, delay 0.5 s vastly improved non-invasive unspecific(Blood Oxygenation Level) Indirect: neuronal activity no temporal sequencing (brain mapping possible) localization expensive
but very unspecific of information flow of cognition inconvenient
PET PET scanner (Sensor ring) Radioactive compound Metabolism (Energy Production) inferior to fMRI inferior to fMRI non-invasive unspecificaccumulates, positrions expensiveannihilate emitting 2 photons inconvenientin 180deg
Optical Imaging Microscope, photo detector Voltage-sensitive dyes unspecific improved very high, ~0.1 mm minimal damage only surfacesinput/output ?
multi-photon laser scanning Fluorescence photons (mostly intracellular calcium improved very high, ~0.1 mm 3D mostly surfacesmicroscopy after laser pulses changes) minimal damage
Single-unit recordings Brain slice preparations Slices alive for some hours Membrane potential excellent, < 1 ms maximum pharmacological compromisesin vitro specificity brain circuits
Patch-clamp direct junction through pipette Current waveforms can be active properties of ion channels excellent, < 1 ms excellent controlled compromisesapplied environment brain circuits
Extracellular recordingsvoltage-sensitive microelectrode Cell isolation multi-unit activity (theoretically up excellent, < 1 ms great, tetrode electrodes parallel very invasive (epilepsy)sharp-tip or wire tetrode Localization via Triangulation to 1000, in practice <20) (Triangulation) in vivo possible brain damage
Multisite recordings Multi-Electrode-Array (MEA) many recording sites but multi-unit activity (> 100) excellent, < 1 ms excellent parallel even more damagingSilicon chip small electrode volume in vivo possible
• Infections: Disease caused by the invasion of a micro-organism or virus
• Degeneration: progressive loss of structure or function of neurons, including death of neurons
• Autoimmune disorders: Immune system attacks and destroys healthy body tissue
• Stroke: Interruption of the blood supply to the brain
• Tumors: Abnormal growth of body tissue
• Trauma: Physiological wound caused by an external source à Brain lesions
Causes of brain disease
• Alzheimer’s (and other forms of dementia): Progressive cognition deterioration, ultimate cause unknown
• Attention deficit/hyperactivity disorder(ADHD): Structural and biochemical imbalance
• Tourette's syndrome: Tics (not only vocal), genetical factors, inherited • Huntington's disease: Degenerative neurological disorder that is
inherited, affects muscle coordination • Locked-in syndrome: Lesion on the brain stem (complete paralysis) • Encephalitis: Inflammation of the brain • Meningitis: Inflammation of the protective membranes covering the
brain and spinal cord • Multiple sclerosis: Chronic, inflammatory demyelinating disease,
meaning that the myelin sheath of neurons is damaged • Parkinson's: Death of dopamine-generating cells in the substantia
nigra, midbrain (cause unknown) • Epilepsy: Seizures, resulting from abnormal, hypersynchronous
neuronal activity in the brain
Brain diseases
� ~ 1 % of world population suffers from epilepsy � ~ 70 % can be treated with antiepileptic drugs � ~ 8 % might profit from epilepsy surgery � ~ 22 % cannot be treated sufficiently � Epilepsy Center Bonn, Germany: presurgical evaluations: 160 cases / year invasive evaluations: 60 - 70 cases / year
Epilepsy
Presurgical evaluation - exact localization of seizure generating area (epileptic focus) current gold standard: EEG recording of seizure origin - exact delineation from functionally relevant areas - Estimation of post-operative status (seizure control, neuropsychological deficits, ...)
Surgical intervention
- Tailored resection of epileptic focus
Epilepsy surgery
Implanted electrodes
[Department of Epileptology, University of Bonn, Germany]
Epilepsy (inter-‐ictal EEG)
[Department of Epileptology, University of Bonn, Germany]
L
R
Epilepsy (ictal EEG)
L
R
[Department of Epileptology, University of Bonn, Germany]
Movie 1: Absence
[Department of Epileptology, University of Bonn, Germany]
Movie 2: Generalized Seizure
[Department of Epileptology, University of Bonn, Germany]
Motivation / Open questions
• Does a pre-ictal state exist (ictus = seizure)?
• Do characterizing measures allow a reliable detection of this state?
Goals / perspectives
• Increasing the patient‘s quality of life • Therapy on demand (Medication, Prevention) • Understanding seizure generating processes
Epilep1c seizure predic1on
Microwire recordings in humans
– 64 microwires (40 µm diameter) able to
record single-neuron-activity and LFPs – Effective recording bandwidth: 1 Hz - 10 kHz
Clinical contacts
Setup:
[Department of Epileptology, University of Bonn, Germany]
Intracranial spike train data
[Kreuz et al., 2013]
Pre-ictal Post-ictal Ictal
L
R
Mo1va1on: Spike train synchrony Synchronization is a key feature for establishing the communication between different regions of the brain. Epilepsy results from abnormal, hypersynchronous neuronal activity in the brain. Accessible brain time series: iEEG (standard) and neuronal spike trains (recent) EEG-Observation: Drop of synchrony before epileptic seizure (so far not clinically sufficient) Open question: What happens on the neuronal level? Needed: Realtime measure of spike train synchrony
Movie 3: SPIKE-Distance
Movie 4: SPIKE-Distance Epileptic seizure
• General Introduction
• Example: Epileptic seizure prediction
• Data acquisition
• Introduction to dynamical systems
Today’s lecture
• Nominal data (=/≠) Categorical - Fixed set of categories (labels) - Examples: Religion, favorite color, blood type • Ordinal data (=/≠, </>) Qualitative - Rank ordering possible, but no distance defined - Example: Academic grades • Interval (=/≠, </>, +/-) Qualitative - Distance between attributes is defined - Examples: Temperature in °C, calendar year • Ratio (=/≠, </>, +/-, x/÷) Quantitative - Absolute zero exists - Examples: Temperature in K, height, weight, age
[Stanley Smith Stevens, 1946]
Levels of measurement
Levels of measurement II
[Trochim, 2006]
[Wharrad, 2004]
• Profiles (samples) / Images (pixels) / Volumes
(voxels)
• Continuous data (time series) – Discrete data (sequence of events)
• Univariate / bivariate / multivariate data
• …
Types of data
Measurement
System / Object Instrument
Environment
Signal
Beware: Interactions !
Data acquisi1on
Sensor
System / Object
Amplifier AD-Converter
Computer
Filter
Sampling
Sampling • Process of converting a signal (a function of continuous
time) into a numeric sequence (a function of discrete time).
• Time series
•
equally sampled:
• Example: sufficient sampling of sine wave (2 sampling values per cycle)
Sampling interval
Sampling frequency fs =1 Δt
T = {x(t1), x(t2 ), x(t3),..., x(tN )}
T = {x(t1), x(t1 +Δt), x(t1 + 2Δt),..., x(t1 + (N −1)Δt}
Δt
Aliasing
• Solution for band-limited signals: Sampling frequency should at least be twice the highest frequency ( ).
(Nyquist–Shannon sampling theorem)
Effect that causes different signals to become indistinguishable (or aliases of one another) when sampled. Mathematical reason: Folding at Nyquist frequency
[Wikimedia]
fS ≥ 2 f ≥ 2 fN
fN =12Δt
=fS2
Filtering
Filtering: Examples
• Anti-aliasing filter (lowpass) • Anti-hum filter (notch for 50/60 Hz powerline)
[Artifact: undesired alteration in data, introduced by a technology and/or processing step]
• Recording from extracellular microelectrode:
- Lowpass filter à Local field potential (LFP) - Highpass filter à Multi-unit activity
Analog-‐Digital-‐Conversion
• Defines data precision
• Example: 10 bit ADC - Voltage: 0-r (range)
- Unit value:
à Quantification error = q/2 • Important: Optimal adjustment of signal via amplifier
q = r210
• General Introduction
• Example: Epileptic seizure prediction
• Data acquisition
• Introduction to dynamical systems
Today’s lecture
Dynamical system
• System with force (greek ‘dynamo’: δυναµιο)
• State of system dependent on time
• Change of state dependent on current state
- deterministic: same circumstance à same evolution - stochastic: same circumstance à random evolution
probability distribution dependent on current state
Dynamical system
• Described by time-dependent states
• Evolution of state
- continuous (flow)
- discrete (map)
can be both be linear or non-linear
• Example: sufficient sampling of sine wave (2 sampling values per cycle)
Control parameter
x ∈ ℜn
x(t +Δt) = F(x(t),Δt,λ)
λ
Linear systems
• Weak causality identical causes have the same effect (strong idealization, not realistic in experimental situations) • Strong causality similar causes have similar effects (includes weak causality applicable to experimental situations, small deviations in initial conditions; external disturbances)
Non-‐linear systems
Violation of strong causality
Similar causes can have different effects
Sensitive dependence on initial conditions
(Deterministic chaos)
Linearity / Non-‐linearity
Non-linear systems - can have complicated solutions - Changes of parameters and initial conditions lead to non-
proportional effects
Non-linear systems are the rule, linear system is special case!
Linear systems - have simple solutions - Changes of parameters and initial
conditions lead to proportional effects
• General Introduction
• Example: Epileptic seizure prediction
• Data acquisition
• Introduction to dynamical systems
Today’s lecture
Linear measures Non-linear measures
- Introduction: State space reconstruction
- Lyapunov exponent
- Dimensions
- Entropies
- …
Next lecture(s)