Glossary Item Box

NSHelp: Condition Properties GeneralCondition StimuliCondition Consistency CheckingCondition Visual Feedback SettingsCondition Knowledge of Results SettingsCondition Sound SettingsCondition Gripper Settings

See Also NeuroScript MovAlyzeR Help Send comments on this topic.

Condition Word Extraction

Word Extraction

This topic is ONLY applicable to ScriptAlyzeR & MovAlyzeR. These programs will be referred to as MovAlyzeR on this page.

To analyze each word of a sentence in a separate condition, the sentence can be recorded but not processed. During processing, specific words extracted are stored in a separate subcondition and processed, but not recorded.

A usual experimental setup for the word extraction experiments is as follows:

o Suppose an experiment consists of recording a long handwriting sample and then extracting individual words from that sample for further processing.

o First, create a condition that is Record only (Check the Recorded option and uncheck Processed if Recorded in Condition Properties > Word Extraction).

o Then create a number of Process only conditions (Uncheck the Recorded option and check Processed if Recorded) and select the Record only condition (from the Extracted from condition) from which words need to be extracted. The trials of the Process only conditions will be the words (enter desired word number in the Word field) extracted from the trial(s) of the Record only condition.

o Run the experiment and record the trials for the Record only condition. When you process those trials, the word extraction algorithm runs and the tree list is automatically populated with the extracted words as set by the Process only conditions.

Note: When individual words are extracted from a trial which has discontinuities, then discontinuities of the extracted words are stored in their own .DIS discontinuity files that are created as part of the word extraction algorithm. 

image060.jpg

o Trials will be recorded: This option is checked for the condition which is used to record the whole sentence or a collection of strokes.

OR

o Trials will be Processed: This option is checked for the subconditions in which the individual words need to be stored.

o Extracted from condition, word: For the second option, you need to specify the parent condition from which the words are to be derived and the word # which is to be extracted.

NOTE: In a normal condition, where there is no word extraction to be done, check BOTH options. This is also the default setting.

NOTE: After recording the trials for such an experiment, the recording-only conditions are displayed in blue color. The subconditions (Processing - only) are not displayed at this point as the processing of trials has not been done yet.

To create the trials of the extracted words of the processing-only conditions, you need to Reprocess All Trials. This can be done by right clicking on Subject OR Group OR Experiment > Reprocess trials.

 

The Word Extraction Algorithm

The following sequence of tests is employed in determining if a new word has been found. The relevant parameters marked in blue can be set at Experiment Properties > Advanced > Word Extraction

Test 1: Horizontal size of penups between words > Min. leftward penlift movement between words

Test 2: Horizontal distance of pendown between words > Min. leftward distance between words

Not a new word if Width of word < Min. word width

Test 3: Large downward vertical movement to new line > Min. downward distance between word beginnings

Test 4: Large backward horizontal movement to new line > Min. word width

Test 5: Large penup time within a word > Min. duration of penlifts between words

Test 6: Initial penup segment is a new word : If there is an initial PenUp part in the data, that is a new word.

Not a new word if Penup time between words < Max. duration of penlifts within a word

 

How to set suitable Word Extraction parameters

Accuracy of the word extraction algorithm depends entirely on the values of the parameters set in Experiment Properties > Advanced > Word Extraction

To arrive at suitable values for these parameters, the following procedure is recommended:

1) Go to Experiment Properties > Advanced > Word Extraction and click on Reset to Defaults.

2) Reprocess the trial from which you want to extract the words. HWR files containing the individual extracted words will populate the tree.

3) Right click on the base trial from which the words were extracted > View Numerical Data > View Word Extraction Data. The Word Extraction Data gives information about what test and parameter the algorithm used in extracting a particular word.

4) Right click on the first extracted file > Chart Data > Chart Raw Data.

5) Visually inspect each extracted word for accuracy. Click the -> button to traverse through the trials.

6) If you find a word that is incorrectly extracted (the word is split between two trials), then look at the Word Extraction Data file and determine the test and parameter that were used to extract that particular word.

Note: If a words are grouped together when they should have been split into individual words, then decrease the values of all the Word Extraction parameters by half of their original default values and continue from there.

eg: In the Word Extraction Data file

Word 54: Samples(42821-42962) | Horizontal distance of pendown between words: PendownLeftx(11.295 cm) - PreviousPendownRightx(10.8685 cm) = 0.4265 cm >= MinLeftPendown(0.3 cm)

7) Go to Experiment Properties > Advanced > Word Extraction and change the Min. leftward distance between words from 0.3 cm to 0.5 cm

8) Reprocess the base trial and follow these steps until you are satisfied with the results of the Word Extraction algorithm.

 

EXAMPLE:

o Define Condition SEN which consists of writing a sentence. Set the instruction to write a sentence. You may need to set a longer trial time. Set this condition Recording-only.

 o Define Condition WD1 which consists of first word (set word = 1). Define another condition WD3 which consists of the third word (set word = 3).

o Set these conditions Processing-only by checking 'Trials will be processed' and use SEN as the parent condition from where this word will be extracted. Use consistency checking to verify that the extracted word is the correct one (optional).

o You can import the experiment WOR which implements word extraction for the above example. Here are the two files for import:

~ WOR.exp (for experiment with groups, subject and conditions).

~ WOR.zip (for the trials..this is optional)

o See the section on importing/exporting an experiment to see how you can import this experiment.

NSHelp: Condition Properties GeneralCondition StimuliCondition Consistency CheckingCondition Visual Feedback SettingsCondition Knowledge of Results SettingsCondition Sound SettingsCondition Gripper Settings

 

 


© NeuroScript LLC. All Rights Reserved.