Working with EMA datafiles in Matlab Jens Roeser & Adamantios - - PowerPoint PPT Presentation

working with ema datafiles in matlab
SMART_READER_LITE
LIVE PREVIEW

Working with EMA datafiles in Matlab Jens Roeser & Adamantios - - PowerPoint PPT Presentation

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels Working with EMA datafiles in Matlab Jens Roeser & Adamantios Gafos University of Potsdam gafos@uni-potsdam.de October


slide-1
SLIDE 1

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Working with EMA datafiles in Matlab

Jens Roeser & Adamantios Gafos

University of Potsdam gafos@uni-potsdam.de

October 19, 2014

1 / 30

slide-2
SLIDE 2

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Table of Contents

1

Basics

2

EMA data structure

3

Signal processing

4

Velocity signals

5

Relating spatial and velocity signals

6

Storing labels

2 / 30

slide-3
SLIDE 3

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

General outline for each section:

Short introduction Try out solutions to proposed mini problems in your MATLAB console and write them into the provided MATLAB script Btw, open the provided MATLAB script

3 / 30

slide-4
SLIDE 4

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

General outline for each section:

Short introduction Try out solutions to proposed mini problems in your MATLAB console and write them into the provided MATLAB script Btw, open the provided MATLAB script

3 / 30

slide-5
SLIDE 5

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

General outline for each section:

Short introduction Try out solutions to proposed mini problems in your MATLAB console and write them into the provided MATLAB script Btw, open the provided MATLAB script

3 / 30

slide-6
SLIDE 6

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

General outline for each section:

Short introduction Try out solutions to proposed mini problems in your MATLAB console and write them into the provided MATLAB script Btw, open the provided MATLAB script

3 / 30

slide-7
SLIDE 7

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

General outline for each section:

Short introduction Try out solutions to proposed mini problems in your MATLAB console and write them into the provided MATLAB script Btw, open the provided MATLAB script

3 / 30

slide-8
SLIDE 8

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

General outline for each section:

Short introduction Try out solutions to proposed mini problems in your MATLAB console and write them into the provided MATLAB script Btw, open the provided MATLAB script

3 / 30

slide-9
SLIDE 9

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Table of Contents

1

Basics

2

EMA data structure

3

Signal processing

4

Velocity signals

5

Relating spatial and velocity signals

6

Storing labels

4 / 30

slide-10
SLIDE 10

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

EMA data structure

Go through sections 0. to 2. of the provided MATLAB script Basic syntax of MATLAB (0.) Setup work space (1.) Load data structures (2.)

5 / 30

slide-11
SLIDE 11

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

EMA data structure

Go through sections 0. to 2. of the provided MATLAB script Basic syntax of MATLAB (0.) Setup work space (1.) Load data structures (2.)

5 / 30

slide-12
SLIDE 12

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

EMA data structure

Go through sections 0. to 2. of the provided MATLAB script Basic syntax of MATLAB (0.) Setup work space (1.) Load data structures (2.)

5 / 30

slide-13
SLIDE 13

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

EMA data structure

Go through sections 0. to 2. of the provided MATLAB script Basic syntax of MATLAB (0.) Setup work space (1.) Load data structures (2.)

5 / 30

slide-14
SLIDE 14

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

EMA data structure

Go through sections 0. to 2. of the provided MATLAB script Basic syntax of MATLAB (0.) Setup work space (1.) Load data structures (2.)

5 / 30

slide-15
SLIDE 15

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Table of Contents

1

Basics

2

EMA data structure

3

Signal processing

4

Velocity signals

5

Relating spatial and velocity signals

6

Storing labels

6 / 30

slide-16
SLIDE 16

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Introduction

EMA: spatial/ positional values recorded in electromagnetic articulography Acoustic information provided Files: data structure, i.e. structure arrays Structure arrays: collection of information of different types (e.g., strings, integers, floats) and lengths belonging to one

  • bject (here, stimulus)

Fields: Subsets of the data contained in the structure array (i.e., receiver trajectory and audio wave form)

7 / 30

slide-17
SLIDE 17

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Introduction

EMA: spatial/ positional values recorded in electromagnetic articulography Acoustic information provided Files: data structure, i.e. structure arrays Structure arrays: collection of information of different types (e.g., strings, integers, floats) and lengths belonging to one

  • bject (here, stimulus)

Fields: Subsets of the data contained in the structure array (i.e., receiver trajectory and audio wave form)

7 / 30

slide-18
SLIDE 18

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Introduction

EMA: spatial/ positional values recorded in electromagnetic articulography Acoustic information provided Files: data structure, i.e. structure arrays Structure arrays: collection of information of different types (e.g., strings, integers, floats) and lengths belonging to one

  • bject (here, stimulus)

Fields: Subsets of the data contained in the structure array (i.e., receiver trajectory and audio wave form)

7 / 30

slide-19
SLIDE 19

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Introduction

EMA: spatial/ positional values recorded in electromagnetic articulography Acoustic information provided Files: data structure, i.e. structure arrays Structure arrays: collection of information of different types (e.g., strings, integers, floats) and lengths belonging to one

  • bject (here, stimulus)

Fields: Subsets of the data contained in the structure array (i.e., receiver trajectory and audio wave form)

7 / 30

slide-20
SLIDE 20

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Introduction

EMA: spatial/ positional values recorded in electromagnetic articulography Acoustic information provided Files: data structure, i.e. structure arrays Structure arrays: collection of information of different types (e.g., strings, integers, floats) and lengths belonging to one

  • bject (here, stimulus)

Fields: Subsets of the data contained in the structure array (i.e., receiver trajectory and audio wave form)

7 / 30

slide-21
SLIDE 21

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Introduction

EMA: spatial/ positional values recorded in electromagnetic articulography Acoustic information provided Files: data structure, i.e. structure arrays Structure arrays: collection of information of different types (e.g., strings, integers, floats) and lengths belonging to one

  • bject (here, stimulus)

Fields: Subsets of the data contained in the structure array (i.e., receiver trajectory and audio wave form)

7 / 30

slide-22
SLIDE 22

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

EMA data structure

Structure arrays contain different fields E.g. ‘data’ contains a 1×7 structure array fieldnames: SIGNAL, SRATE, NAME NAME: audio and 6 receiver trajectories SIGNAL and SRATE correspond to the different receivers in NAME

8 / 30

slide-23
SLIDE 23

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

EMA data structure

Structure arrays contain different fields E.g. ‘data’ contains a 1×7 structure array fieldnames: SIGNAL, SRATE, NAME NAME: audio and 6 receiver trajectories SIGNAL and SRATE correspond to the different receivers in NAME

8 / 30

slide-24
SLIDE 24

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

EMA data structure

Structure arrays contain different fields E.g. ‘data’ contains a 1×7 structure array fieldnames: SIGNAL, SRATE, NAME NAME: audio and 6 receiver trajectories SIGNAL and SRATE correspond to the different receivers in NAME

8 / 30

slide-25
SLIDE 25

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

EMA data structure

Structure arrays contain different fields E.g. ‘data’ contains a 1×7 structure array fieldnames: SIGNAL, SRATE, NAME NAME: audio and 6 receiver trajectories SIGNAL and SRATE correspond to the different receivers in NAME

8 / 30

slide-26
SLIDE 26

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

EMA data structure

Structure arrays contain different fields E.g. ‘data’ contains a 1×7 structure array fieldnames: SIGNAL, SRATE, NAME NAME: audio and 6 receiver trajectories SIGNAL and SRATE correspond to the different receivers in NAME

8 / 30

slide-27
SLIDE 27

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

EMA data structure

Structure arrays contain different fields E.g. ‘data’ contains a 1×7 structure array fieldnames: SIGNAL, SRATE, NAME NAME: audio and 6 receiver trajectories SIGNAL and SRATE correspond to the different receivers in NAME

8 / 30

slide-28
SLIDE 28

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Exercise 1

The field SRATE contains information about the sampling rate used during the data recording. As seen before for the file names and signal names, check which sampling rate was used for the field audio and for the individual trajectories (i.e., instead of asking for the NAME field, ask for the SRATE field). The order of the values for sampling rate corresponds to the names listed in ‘trajectories’. Note: For now and later, provide the answers in your MATLAB script.

9 / 30

slide-29
SLIDE 29

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Table of Contents

1

Basics

2

EMA data structure

3

Signal processing

4

Velocity signals

5

Relating spatial and velocity signals

6

Storing labels

10 / 30

slide-30
SLIDE 30

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Signal processing

SIGNAL: a sequence of values that are called samples spanning a time slice as determined by SRATE 2D data: contain positional signal for x- and y-dimension of tongue kinematics Samples are taken at regular time intervals as expressed in the sampling rate (in Hz). For a sampling rate of 400 Hz, 400 samples are taken per second or one sample all 0.0025 sec (i.e.,1/400) Proceed with 3. Signal processing in the MATLAB script Afterwards, check Exercise 2 in the slides

11 / 30

slide-31
SLIDE 31

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Signal processing

SIGNAL: a sequence of values that are called samples spanning a time slice as determined by SRATE 2D data: contain positional signal for x- and y-dimension of tongue kinematics Samples are taken at regular time intervals as expressed in the sampling rate (in Hz). For a sampling rate of 400 Hz, 400 samples are taken per second or one sample all 0.0025 sec (i.e.,1/400) Proceed with 3. Signal processing in the MATLAB script Afterwards, check Exercise 2 in the slides

11 / 30

slide-32
SLIDE 32

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Signal processing

SIGNAL: a sequence of values that are called samples spanning a time slice as determined by SRATE 2D data: contain positional signal for x- and y-dimension of tongue kinematics Samples are taken at regular time intervals as expressed in the sampling rate (in Hz). For a sampling rate of 400 Hz, 400 samples are taken per second or one sample all 0.0025 sec (i.e.,1/400) Proceed with 3. Signal processing in the MATLAB script Afterwards, check Exercise 2 in the slides

11 / 30

slide-33
SLIDE 33

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Signal processing

SIGNAL: a sequence of values that are called samples spanning a time slice as determined by SRATE 2D data: contain positional signal for x- and y-dimension of tongue kinematics Samples are taken at regular time intervals as expressed in the sampling rate (in Hz). For a sampling rate of 400 Hz, 400 samples are taken per second or one sample all 0.0025 sec (i.e.,1/400) Proceed with 3. Signal processing in the MATLAB script Afterwards, check Exercise 2 in the slides

11 / 30

slide-34
SLIDE 34

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Signal processing

SIGNAL: a sequence of values that are called samples spanning a time slice as determined by SRATE 2D data: contain positional signal for x- and y-dimension of tongue kinematics Samples are taken at regular time intervals as expressed in the sampling rate (in Hz). For a sampling rate of 400 Hz, 400 samples are taken per second or one sample all 0.0025 sec (i.e.,1/400) Proceed with 3. Signal processing in the MATLAB script Afterwards, check Exercise 2 in the slides

11 / 30

slide-35
SLIDE 35

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Signal processing

SIGNAL: a sequence of values that are called samples spanning a time slice as determined by SRATE 2D data: contain positional signal for x- and y-dimension of tongue kinematics Samples are taken at regular time intervals as expressed in the sampling rate (in Hz). For a sampling rate of 400 Hz, 400 samples are taken per second or one sample all 0.0025 sec (i.e.,1/400) Proceed with 3. Signal processing in the MATLAB script Afterwards, check Exercise 2 in the slides

11 / 30

slide-36
SLIDE 36

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Signal processing

SIGNAL: a sequence of values that are called samples spanning a time slice as determined by SRATE 2D data: contain positional signal for x- and y-dimension of tongue kinematics Samples are taken at regular time intervals as expressed in the sampling rate (in Hz). For a sampling rate of 400 Hz, 400 samples are taken per second or one sample all 0.0025 sec (i.e.,1/400) Proceed with 3. Signal processing in the MATLAB script Afterwards, check Exercise 2 in the slides

11 / 30

slide-37
SLIDE 37

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Exercise 2

Repeat for the tongue tip trajectory (i.e., TTPOS) what you just learned for TBPOS. Use strmatch for TTPOS instead of TBPOS and index ‘data’. Then, find the positional values x and y of the 266th sample in the TTPOS trajectory.

12 / 30

slide-38
SLIDE 38

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Signal processing

The duration of a signal can be retrieved from the amount of samples and the sampling rate. The following correspondence between time and samples is given: f = 1/T (1) t = n/f (2) n = t∗f (3)

13 / 30

slide-39
SLIDE 39

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Signal processing

The duration of a signal can be retrieved from the amount of samples and the sampling rate. The following correspondence between time and samples is given: f = 1/T (1) t = n/f (2) n = t∗f (3)

13 / 30

slide-40
SLIDE 40

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Signal processing

The duration of a signal can be retrieved from the amount of samples and the sampling rate. The following correspondence between time and samples is given: f = 1/T (1) t = n/f (2) n = t∗f (3)

13 / 30

slide-41
SLIDE 41

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Signal processing

The duration of a signal can be retrieved from the amount of samples and the sampling rate. The following correspondence between time and samples is given: f = 1/T (1) t = n/f (2) n = t∗f (3)

13 / 30

slide-42
SLIDE 42

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Signal processing

The duration of a signal can be retrieved from the amount of samples and the sampling rate. The following correspondence between time and samples is given: f = 1/T (1) t = n/f (2) n = t∗f (3)

13 / 30

slide-43
SLIDE 43

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Signal processing

The duration of the signal in msec: dur = 1000∗(length(data(2).SIGNAL)-1)/data(2).SRATE Sampling info starts from the first sample but time starts from 0.

14 / 30

slide-44
SLIDE 44

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Signal processing

The duration of the signal in msec: dur = 1000∗(length(data(2).SIGNAL)-1)/data(2).SRATE Sampling info starts from the first sample but time starts from 0.

14 / 30

slide-45
SLIDE 45

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Signal processing

The duration of the signal in msec: dur = 1000∗(length(data(2).SIGNAL)-1)/data(2).SRATE Sampling info starts from the first sample but time starts from 0.

14 / 30

slide-46
SLIDE 46

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Signal processing

The duration of the signal in msec: dur = 1000∗(length(data(2).SIGNAL)-1)/data(2).SRATE Sampling info starts from the first sample but time starts from 0.

14 / 30

slide-47
SLIDE 47

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Exercise 3

To work with different signals it is often useful to see how a (slice of a) signal looks like: Plot the y-signal of TBPOS: plot(data(2).SIGNAL(:,2)) Create the same plot using the vector matrix of the TBPOS assigned before (e.g., signal tbp). Plot the signal for the x-dimension of TTPOS by changing the relevant indices in the plot command. Remember, data.NAME gives the trajectory names for the index of TTPOS. The order

  • f the trajectory names corresponds to the relevant index.

Proceed with 4. Work on audio signals in the MATLAB script

15 / 30

slide-48
SLIDE 48

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Exercise 3

To work with different signals it is often useful to see how a (slice of a) signal looks like: Plot the y-signal of TBPOS: plot(data(2).SIGNAL(:,2)) Create the same plot using the vector matrix of the TBPOS assigned before (e.g., signal tbp). Plot the signal for the x-dimension of TTPOS by changing the relevant indices in the plot command. Remember, data.NAME gives the trajectory names for the index of TTPOS. The order

  • f the trajectory names corresponds to the relevant index.

Proceed with 4. Work on audio signals in the MATLAB script

15 / 30

slide-49
SLIDE 49

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Exercise 3

To work with different signals it is often useful to see how a (slice of a) signal looks like: Plot the y-signal of TBPOS: plot(data(2).SIGNAL(:,2)) Create the same plot using the vector matrix of the TBPOS assigned before (e.g., signal tbp). Plot the signal for the x-dimension of TTPOS by changing the relevant indices in the plot command. Remember, data.NAME gives the trajectory names for the index of TTPOS. The order

  • f the trajectory names corresponds to the relevant index.

Proceed with 4. Work on audio signals in the MATLAB script

15 / 30

slide-50
SLIDE 50

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Exercise 3

To work with different signals it is often useful to see how a (slice of a) signal looks like: Plot the y-signal of TBPOS: plot(data(2).SIGNAL(:,2)) Create the same plot using the vector matrix of the TBPOS assigned before (e.g., signal tbp). Plot the signal for the x-dimension of TTPOS by changing the relevant indices in the plot command. Remember, data.NAME gives the trajectory names for the index of TTPOS. The order

  • f the trajectory names corresponds to the relevant index.

Proceed with 4. Work on audio signals in the MATLAB script

15 / 30

slide-51
SLIDE 51

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Exercise 3

To work with different signals it is often useful to see how a (slice of a) signal looks like: Plot the y-signal of TBPOS: plot(data(2).SIGNAL(:,2)) Create the same plot using the vector matrix of the TBPOS assigned before (e.g., signal tbp). Plot the signal for the x-dimension of TTPOS by changing the relevant indices in the plot command. Remember, data.NAME gives the trajectory names for the index of TTPOS. The order

  • f the trajectory names corresponds to the relevant index.

Proceed with 4. Work on audio signals in the MATLAB script

15 / 30

slide-52
SLIDE 52

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Exercise 3

To work with different signals it is often useful to see how a (slice of a) signal looks like: Plot the y-signal of TBPOS: plot(data(2).SIGNAL(:,2)) Create the same plot using the vector matrix of the TBPOS assigned before (e.g., signal tbp). Plot the signal for the x-dimension of TTPOS by changing the relevant indices in the plot command. Remember, data.NAME gives the trajectory names for the index of TTPOS. The order

  • f the trajectory names corresponds to the relevant index.

Proceed with 4. Work on audio signals in the MATLAB script

15 / 30

slide-53
SLIDE 53

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Exercise 4

MATLAB might give you a warning when you extract the audio signal. This can be circumvented by normalizing the amplitude of the signal to 1 as shown in the code below. The normalized audio signal is assigned to audio signal. Normalize the audio signal before saving it to a .wav file. Apply the function audiowrite to audio signal. No warning should appear in the console if previously seen. audio signal = data(1).SIGNAL/max(abs(data(1).SIGNAL));

16 / 30

slide-54
SLIDE 54

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Exercise 4

MATLAB might give you a warning when you extract the audio signal. This can be circumvented by normalizing the amplitude of the signal to 1 as shown in the code below. The normalized audio signal is assigned to audio signal. Normalize the audio signal before saving it to a .wav file. Apply the function audiowrite to audio signal. No warning should appear in the console if previously seen. audio signal = data(1).SIGNAL/max(abs(data(1).SIGNAL));

16 / 30

slide-55
SLIDE 55

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Signal processing

All signals in the structure array are synchronous. The nth sample has positional representations in all receiver trajectories. Try, data(t).SIGNAL(552,:) and replace t for different receivers. Display spatial values of vertical movements for the 432nd to 440th sample of JAWPOS (i.e., jaw posture) and LLPOS (i.e., lower lip posture) Proceed with 5. Local extrema in the MATLAB script

17 / 30

slide-56
SLIDE 56

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Signal processing

All signals in the structure array are synchronous. The nth sample has positional representations in all receiver trajectories. Try, data(t).SIGNAL(552,:) and replace t for different receivers. Display spatial values of vertical movements for the 432nd to 440th sample of JAWPOS (i.e., jaw posture) and LLPOS (i.e., lower lip posture) Proceed with 5. Local extrema in the MATLAB script

17 / 30

slide-57
SLIDE 57

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Signal processing

All signals in the structure array are synchronous. The nth sample has positional representations in all receiver trajectories. Try, data(t).SIGNAL(552,:) and replace t for different receivers. Display spatial values of vertical movements for the 432nd to 440th sample of JAWPOS (i.e., jaw posture) and LLPOS (i.e., lower lip posture) Proceed with 5. Local extrema in the MATLAB script

17 / 30

slide-58
SLIDE 58

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Signal processing

All signals in the structure array are synchronous. The nth sample has positional representations in all receiver trajectories. Try, data(t).SIGNAL(552,:) and replace t for different receivers. Display spatial values of vertical movements for the 432nd to 440th sample of JAWPOS (i.e., jaw posture) and LLPOS (i.e., lower lip posture) Proceed with 5. Local extrema in the MATLAB script

17 / 30

slide-59
SLIDE 59

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Signal processing

All signals in the structure array are synchronous. The nth sample has positional representations in all receiver trajectories. Try, data(t).SIGNAL(552,:) and replace t for different receivers. Display spatial values of vertical movements for the 432nd to 440th sample of JAWPOS (i.e., jaw posture) and LLPOS (i.e., lower lip posture) Proceed with 5. Local extrema in the MATLAB script

17 / 30

slide-60
SLIDE 60

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Signal processing

All signals in the structure array are synchronous. The nth sample has positional representations in all receiver trajectories. Try, data(t).SIGNAL(552,:) and replace t for different receivers. Display spatial values of vertical movements for the 432nd to 440th sample of JAWPOS (i.e., jaw posture) and LLPOS (i.e., lower lip posture) Proceed with 5. Local extrema in the MATLAB script

17 / 30

slide-61
SLIDE 61

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Table of Contents

1

Basics

2

EMA data structure

3

Signal processing

4

Velocity signals

5

Relating spatial and velocity signals

6

Storing labels

18 / 30

slide-62
SLIDE 62

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Velocity signals

Velocity corresponds to the acceleration of a gesture. The maximum in velocity can be found at the onset of a gestural movement and when the offset of a gesture. The minimum in velocity is the maximum constriction of a gesture.

19 / 30

slide-63
SLIDE 63

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Velocity signals

Velocity corresponds to the acceleration of a gesture. The maximum in velocity can be found at the onset of a gestural movement and when the offset of a gesture. The minimum in velocity is the maximum constriction of a gesture.

19 / 30

slide-64
SLIDE 64

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Velocity signals

Velocity corresponds to the acceleration of a gesture. The maximum in velocity can be found at the onset of a gestural movement and when the offset of a gesture. The minimum in velocity is the maximum constriction of a gesture.

19 / 30

slide-65
SLIDE 65

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Velocity signals

Velocity corresponds to the acceleration of a gesture. The maximum in velocity can be found at the onset of a gestural movement and when the offset of a gesture. The minimum in velocity is the maximum constriction of a gesture.

19 / 30

slide-66
SLIDE 66

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Velocity signals

6 8 10 12 14 16 tongue mid y−position (mm) target release 1100 1200 1300 5 10 15 tangential velocity (cm/sec) time (ms) peak peak C max

Figure: The positional signal in the vertical dimension (upper panel) and the magnitude of the tangential velocity of the tongue mid receiver (lower panel) plotted as a function of time.

20 / 30

slide-67
SLIDE 67

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Velocity signals

See 5. Velocity signals in the MATLAB script The velocity depends on the signal of a receiver (here, TBPOS is used. s = data(2).SIGNAL; Central difference approximation calculates the derivative of the dimensional velocities on the basis of samples: vel = [diff(s(1:2,:)) ; s(3:end,:)

  • s(1:end-2,:)

; diff(s(end-1:end,:))] ./ 2;

21 / 30

slide-68
SLIDE 68

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Velocity signals

See 5. Velocity signals in the MATLAB script The velocity depends on the signal of a receiver (here, TBPOS is used. s = data(2).SIGNAL; Central difference approximation calculates the derivative of the dimensional velocities on the basis of samples: vel = [diff(s(1:2,:)) ; s(3:end,:)

  • s(1:end-2,:)

; diff(s(end-1:end,:))] ./ 2;

21 / 30

slide-69
SLIDE 69

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Velocity signals

See 5. Velocity signals in the MATLAB script The velocity depends on the signal of a receiver (here, TBPOS is used. s = data(2).SIGNAL; Central difference approximation calculates the derivative of the dimensional velocities on the basis of samples: vel = [diff(s(1:2,:)) ; s(3:end,:)

  • s(1:end-2,:)

; diff(s(end-1:end,:))] ./ 2;

21 / 30

slide-70
SLIDE 70

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Velocity signals

See 5. Velocity signals in the MATLAB script The velocity depends on the signal of a receiver (here, TBPOS is used. s = data(2).SIGNAL; Central difference approximation calculates the derivative of the dimensional velocities on the basis of samples: vel = [diff(s(1:2,:)) ; s(3:end,:)

  • s(1:end-2,:)

; diff(s(end-1:end,:))] ./ 2;

21 / 30

slide-71
SLIDE 71

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Velocity signals

See 5. Velocity signals in the MATLAB script The velocity depends on the signal of a receiver (here, TBPOS is used. s = data(2).SIGNAL; Central difference approximation calculates the derivative of the dimensional velocities on the basis of samples: vel = [diff(s(1:2,:)) ; s(3:end,:)

  • s(1:end-2,:)

; diff(s(end-1:end,:))] ./ 2;

21 / 30

slide-72
SLIDE 72

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Velocity signals

See 5. Velocity signals in the MATLAB script The velocity depends on the signal of a receiver (here, TBPOS is used. s = data(2).SIGNAL; Central difference approximation calculates the derivative of the dimensional velocities on the basis of samples: vel = [diff(s(1:2,:)) ; s(3:end,:)

  • s(1:end-2,:)

; diff(s(end-1:end,:))] ./ 2;

21 / 30

slide-73
SLIDE 73

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Velocity signals

Individual dimension velocities in cm/sec are calculated from vel by indexing x and y dimension. Multiply sampling rate and signal of the respective dimension (samples to sec) and from mm to cm and append results to new field in data structure data(2).VEL y = data(2).SRATE∗vel(:,2)./10; % for the vertical velocity in y dimension data(2).VEL y = data(2).SRATE∗vel(:,1)./10; % for the horizontal velocity in x dimension

22 / 30

slide-74
SLIDE 74

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Velocity signals

Individual dimension velocities in cm/sec are calculated from vel by indexing x and y dimension. Multiply sampling rate and signal of the respective dimension (samples to sec) and from mm to cm and append results to new field in data structure data(2).VEL y = data(2).SRATE∗vel(:,2)./10; % for the vertical velocity in y dimension data(2).VEL y = data(2).SRATE∗vel(:,1)./10; % for the horizontal velocity in x dimension

22 / 30

slide-75
SLIDE 75

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Velocity signals

Individual dimension velocities in cm/sec are calculated from vel by indexing x and y dimension. Multiply sampling rate and signal of the respective dimension (samples to sec) and from mm to cm and append results to new field in data structure data(2).VEL y = data(2).SRATE∗vel(:,2)./10; % for the vertical velocity in y dimension data(2).VEL y = data(2).SRATE∗vel(:,1)./10; % for the horizontal velocity in x dimension

22 / 30

slide-76
SLIDE 76

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Velocity signals

Individual dimension velocities in cm/sec are calculated from vel by indexing x and y dimension. Multiply sampling rate and signal of the respective dimension (samples to sec) and from mm to cm and append results to new field in data structure data(2).VEL y = data(2).SRATE∗vel(:,2)./10; % for the vertical velocity in y dimension data(2).VEL y = data(2).SRATE∗vel(:,1)./10; % for the horizontal velocity in x dimension

22 / 30

slide-77
SLIDE 77

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Velocity signals

Individual dimension velocities in cm/sec are calculated from vel by indexing x and y dimension. Multiply sampling rate and signal of the respective dimension (samples to sec) and from mm to cm and append results to new field in data structure data(2).VEL y = data(2).SRATE∗vel(:,2)./10; % for the vertical velocity in y dimension data(2).VEL y = data(2).SRATE∗vel(:,1)./10; % for the horizontal velocity in x dimension

22 / 30

slide-78
SLIDE 78

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Velocity signals

Tangential velocity vt is defined as the square root of the sum

  • f the squared dimensional velocities:

vt =

  • v2

x + v2 y

(4) v t = sqrt(sum(vel. ˆ 2,2)); data(2).VEL tang = data(2).SRATE∗v t./10; Check data(2)

23 / 30

slide-79
SLIDE 79

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Velocity signals

Tangential velocity vt is defined as the square root of the sum

  • f the squared dimensional velocities:

vt =

  • v2

x + v2 y

(4) v t = sqrt(sum(vel. ˆ 2,2)); data(2).VEL tang = data(2).SRATE∗v t./10; Check data(2)

23 / 30

slide-80
SLIDE 80

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Velocity signals

Tangential velocity vt is defined as the square root of the sum

  • f the squared dimensional velocities:

vt =

  • v2

x + v2 y

(4) v t = sqrt(sum(vel. ˆ 2,2)); data(2).VEL tang = data(2).SRATE∗v t./10; Check data(2)

23 / 30

slide-81
SLIDE 81

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Velocity signals

Tangential velocity vt is defined as the square root of the sum

  • f the squared dimensional velocities:

vt =

  • v2

x + v2 y

(4) v t = sqrt(sum(vel. ˆ 2,2)); data(2).VEL tang = data(2).SRATE∗v t./10; Check data(2)

23 / 30

slide-82
SLIDE 82

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Velocity signals

Tangential velocity vt is defined as the square root of the sum

  • f the squared dimensional velocities:

vt =

  • v2

x + v2 y

(4) v t = sqrt(sum(vel. ˆ 2,2)); data(2).VEL tang = data(2).SRATE∗v t./10; Check data(2)

23 / 30

slide-83
SLIDE 83

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Velocity signals

Tangential velocity vt is defined as the square root of the sum

  • f the squared dimensional velocities:

vt =

  • v2

x + v2 y

(4) v t = sqrt(sum(vel. ˆ 2,2)); data(2).VEL tang = data(2).SRATE∗v t./10; Check data(2)

23 / 30

slide-84
SLIDE 84

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Exercise 5

Plot the tangential velocity of TBPOS in the region (rng) that has been used for the local maximum (e.g., 250 to 270). Also, determine the corresponding local minimum of the tangential velocity given a time stamp at 650 ms. This minimum corresponds to what labeling software of articulatory kinematics considers to be a maximum constriction. You basically will have to change the field SIGNAL to VEL tang in the exercise 5. Local extrema. Then, calculate the minimum by applying the function min instead

  • f max (use the help function for min). You might see that the

given range does not include a local minimum. In this case, increase the range and re-plot. If you follow the detection of the local maximum, this exercise can be solved easily. What is the time stamp of the maximum constriction?

24 / 30

slide-85
SLIDE 85

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Table of Contents

1

Basics

2

EMA data structure

3

Signal processing

4

Velocity signals

5

Relating spatial and velocity signals

6

Storing labels

25 / 30

slide-86
SLIDE 86

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Relating spatial and velocity signals

Different receivers have corresponding spatial signals at the each sample index. Gestural movements can be expressed spatially and in terms

  • f dimensional or tangential velocity.

Use the subplot function to illustrate the correspondence between spatial and velocity signals. See 7. Relating spatial and velocity signals in the MATLAB script. How is the spatial signal related to the velocity signals?

26 / 30

slide-87
SLIDE 87

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Relating spatial and velocity signals

Different receivers have corresponding spatial signals at the each sample index. Gestural movements can be expressed spatially and in terms

  • f dimensional or tangential velocity.

Use the subplot function to illustrate the correspondence between spatial and velocity signals. See 7. Relating spatial and velocity signals in the MATLAB script. How is the spatial signal related to the velocity signals?

26 / 30

slide-88
SLIDE 88

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Relating spatial and velocity signals

Different receivers have corresponding spatial signals at the each sample index. Gestural movements can be expressed spatially and in terms

  • f dimensional or tangential velocity.

Use the subplot function to illustrate the correspondence between spatial and velocity signals. See 7. Relating spatial and velocity signals in the MATLAB script. How is the spatial signal related to the velocity signals?

26 / 30

slide-89
SLIDE 89

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Relating spatial and velocity signals

Different receivers have corresponding spatial signals at the each sample index. Gestural movements can be expressed spatially and in terms

  • f dimensional or tangential velocity.

Use the subplot function to illustrate the correspondence between spatial and velocity signals. See 7. Relating spatial and velocity signals in the MATLAB script. How is the spatial signal related to the velocity signals?

26 / 30

slide-90
SLIDE 90

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Relating spatial and velocity signals

Different receivers have corresponding spatial signals at the each sample index. Gestural movements can be expressed spatially and in terms

  • f dimensional or tangential velocity.

Use the subplot function to illustrate the correspondence between spatial and velocity signals. See 7. Relating spatial and velocity signals in the MATLAB script. How is the spatial signal related to the velocity signals?

26 / 30

slide-91
SLIDE 91

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Exercise 6

Create similar plots for TMPOS. Observe the sensitivity to local extrema under the variation of the sample range. Vary the sample range between e.g. 200 to 700, 300 to 500, 400 to 450). You will have to specify s and calculate vel for s of

  • TMPOS. Create a new vector rng that contains the sample

range values. When done, continue with the MATLAB script 8. Plotting II.

27 / 30

slide-92
SLIDE 92

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Exercise 6

Create similar plots for TMPOS. Observe the sensitivity to local extrema under the variation of the sample range. Vary the sample range between e.g. 200 to 700, 300 to 500, 400 to 450). You will have to specify s and calculate vel for s of

  • TMPOS. Create a new vector rng that contains the sample

range values. When done, continue with the MATLAB script 8. Plotting II.

27 / 30

slide-93
SLIDE 93

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Exercise 6

Create similar plots for TMPOS. Observe the sensitivity to local extrema under the variation of the sample range. Vary the sample range between e.g. 200 to 700, 300 to 500, 400 to 450). You will have to specify s and calculate vel for s of

  • TMPOS. Create a new vector rng that contains the sample

range values. When done, continue with the MATLAB script 8. Plotting II.

27 / 30

slide-94
SLIDE 94

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Table of Contents

1

Basics

2

EMA data structure

3

Signal processing

4

Velocity signals

5

Relating spatial and velocity signals

6

Storing labels

28 / 30

slide-95
SLIDE 95

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Storing labels

Extracted information can be saved in a new structure array, e.g. labels The first entry gets the index 1, labels(1) Use the dot operator to add fields, e.g. labels(1).file Continue with the MATLAB script 9. Storing labels

29 / 30

slide-96
SLIDE 96

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Storing labels

Extracted information can be saved in a new structure array, e.g. labels The first entry gets the index 1, labels(1) Use the dot operator to add fields, e.g. labels(1).file Continue with the MATLAB script 9. Storing labels

29 / 30

slide-97
SLIDE 97

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Storing labels

Extracted information can be saved in a new structure array, e.g. labels The first entry gets the index 1, labels(1) Use the dot operator to add fields, e.g. labels(1).file Continue with the MATLAB script 9. Storing labels

29 / 30

slide-98
SLIDE 98

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Storing labels

Extracted information can be saved in a new structure array, e.g. labels The first entry gets the index 1, labels(1) Use the dot operator to add fields, e.g. labels(1).file Continue with the MATLAB script 9. Storing labels

29 / 30

slide-99
SLIDE 99

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

Storing labels

Extracted information can be saved in a new structure array, e.g. labels The first entry gets the index 1, labels(1) Use the dot operator to add fields, e.g. labels(1).file Continue with the MATLAB script 9. Storing labels

29 / 30

slide-100
SLIDE 100

Basics EMA data structure Signal processing Velocity signals Relating spatial and velocity signals Storing labels

That’s all ;)

30 / 30