Re: [R] selectively altering variable value

2009-08-03 Thread jim holtman
This should set the first two ia==4 entries to 1 in saccade column: > x <- read.table('/tempxx.txt.r', header=TRUE) > x vp trial ia saccade 1 1 1 5 0 2 1 1 5 0 3 1 1 5 0 4 1 1 5 1 5 1 1 5 1 6 1 1 9 1 7 1 1 9

[R] selectively altering variable value

2009-08-03 Thread Jens Bölte
Hello, I have run an eye-tracking experiment for which I now like to analyse the saccades. Participants looked from a fixation cross (ia = 5) to the target area (ia = 4) in following example of a data frame. ia = 9 stands for everything else. A saccade is indicated by saccade = 1. Sometimes the s