Dear R-Users,
I'd like to have your help on this problem:
I have two vectors:x<- c(0,1,0,0,0,0,0,0,0,0,0,1,0)y<- 
c(0,0,-10,0,0,-10,0,-10,0,0,0,0,0)
And I want to know where the value -500 in y have a correspondence value 1 in 
x.Considering a buffer of one position before and after in x.i.e. in this 
example only the -10 in position y[3] satisfies the criteria, because x has in 
position x[2]the figure 1.
Thank in advance for you help,Francesco





                                          
        [[alternative HTML version deleted]]

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to